Author Topic: Two shops in one forum  (Read 1884 times)

Offline polis

Two shops in one forum
« on: February 05, 2008, 05:58:33 pm »
Hey, im making a WWI rol game, and people use money and troops. I need it to be with SMFshop because it should be dynamic both money and troops.

I want the post profile to look like this:

Nickname
$3,000,000
20,000 troops

I was thinking in clonning some code, changing shop by shop2.

Code: [Select]
//Begin SMFShop
if ($context['current_action'] == 'shop')
$current_action = 'shop';
//END SMFShop MOD code

//Begin SMFShop
if ($context['current_action'] == 'shop2')
$current_action = 'shop2';
//END SMFShop MOD code

 And
Code: [Select]
//Begin SMFShop
//loadLanguage("shop");
echo ($current_action == 'shop' || $context['browser']['is_ie4']) ? '<td class="maintab_active_' . $first . '">&nbsp;</td>' : '' , '
<td valign="top" class="maintab_' , $current_action == 'shop' ? 'active_back' : 'back' , '">
<a href="', $scripturl, '?action=shop">Shop</a>
</td>' , $current_action == 'shop' ? '<td class="maintab_active_' . $last . '">&nbsp;</td>' : '';
//END SMFShop MOD code

//Begin SMFShop
//loadLanguage("shop2");
echo ($current_action == 'shop2' || $context['browser']['is_ie4']) ? '<td class="maintab_active_' . $first . '">&nbsp;</td>' : '' , '
<td valign="top" class="maintab_' , $current_action == 'shop2' ? 'active_back' : 'back' , '">
<a href="', $scripturl, '?action=shop2">Shop2</a>
</td>' , $current_action == 'shop2' ? '<td class="maintab_active_' . $last . '">&nbsp;</td>' : '';
//END SMFShop MOD code

I would like to know what else should I change.

Thanks.

P.S: Sorry, Don't know how to make the size of the code bigger.
« Last Edit: February 05, 2008, 06:06:07 pm by polis »