Main Menu
collapse

Simple Portal Archived Forum

This is an Archive Forum.

The content in this forum may be out-of-date or have been superseded by newer information, and links in forum pages to other sites may not work.
This forum contains archives for future reference.

Visit our thread at Simple Machines Forum for current support.

SMF 2.1 users: EhPortal is a ported version of Simple Portal specifically designed for the SMF 2.1 branch.
Please visit web-develop.ca to download EhPortal and for its support.

User Info

Welcome Guest.
Please log in.

Who's Online

  • Dot Guests: 1178
  • Dot Hidden: 0
  • Dot Users: 0

There aren't any users online.

Recent Posts

Adding Forums Button to Nav bar by jirapon
[August 01, 2019, 09:07:12 AM]


Re: Board Icons by ♦ Ninja ZX-10RR ♦
[July 30, 2019, 04:03:41 PM]


MOVED: Czech translation???? by ♦ Ninja ZX-10RR ♦
[July 30, 2019, 03:04:51 PM]


Board Icons by jirapon
[July 30, 2019, 07:28:44 AM]


Re: Thankyou Simpleportal, by ♦ Ninja ZX-10RR ♦
[July 29, 2019, 09:41:29 AM]


If you're interested in helping other members with support requests, consider joining the Community Support Helpers group.

SP Shop showing info in userinfo block.

Started by KahneFan, April 03, 2009, 03:37:44 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

KahneFan

I saw that. Pretty cool  ;D

A similar question; do you know what I would use to put a line in the user info block for "(shop $ name) in pocket:"?
I Post You Post - Forum Owners Helping Forum Owners

Nathaniel

Split from the other topic and moved to the Custom Coding board.

I'll do this in a second. ;)
SMF Friend (Former Support Specialist) | SimplePortal DeveloperMy SMF Mods | SimplePortal"Quis custodiet ipsos custodes?" - Who will Guard the Guards?Please don't send me ANY support related PMs. I will just delete them.

Nathaniel

Find this code in your 'SPortal1-1.php' file.
if (allowedTo('pm_read'))
{
echo '
<li>', sp_embed_image('dot'), ' <strong>', $txt['sp-usertmessage'], ':</strong> <a href="', $scripturl, '?action=pm">', $context['user']['messages'], '</a></li>
<li>', sp_embed_image('dot'), ' <strong>', $txt['sp-usernmessage'], ':</strong> ', $context['user']['unread_messages'], '</li>';
}


Add this code afterwards:
global $sourcedir;
static $mod;
if (!empty($mod) || file_exists($sourcedir . '/shop'))
{
echo '
<li>', sp_embed_image('dot'), ' <strong>In Pocket:</strong> ', $context['user']['money'], '</li>
<li>', sp_embed_image('dot'), ' <strong>In Bank:</strong> ', $context['user']['moneyBank'], '</li>';
}
SMF Friend (Former Support Specialist) | SimplePortal DeveloperMy SMF Mods | SimplePortal"Quis custodiet ipsos custodes?" - Who will Guard the Guards?Please don't send me ANY support related PMs. I will just delete them.

KahneFan

Where would/should I find SPortal1-1.php? I'm only seeing Sportal2.php

(This is for SP2.2 + SMF 2.0RC1 btw)
I Post You Post - Forum Owners Helping Forum Owners

Nathaniel

Ah sorry, the edit should be the same for your 'SPortal2.php' file if you are using SMF 2.

Notice that the code adds both 'In Pocket' and 'in Bank' values, you can remove the code for one if you only want the other. ;)
SMF Friend (Former Support Specialist) | SimplePortal DeveloperMy SMF Mods | SimplePortal"Quis custodiet ipsos custodes?" - Who will Guard the Guards?Please don't send me ANY support related PMs. I will just delete them.

KahneFan

Perfect, thanks!! I just added my sites denomination in front.
I Post You Post - Forum Owners Helping Forum Owners