Author Topic: [split] Re: How to get shop working in other themes  (Read 8537 times)

Offline leviyah

[split] Re: How to get shop working in other themes
« on: December 07, 2006, 02:41:10 am »
Need quick help!!!
I replaced that what you written above and i get this error when i visit any thread:

Offline Lady Ambrosia

[split] Re: How to get shop working in other themes
« Reply #1 on: December 07, 2006, 04:53:08 am »
I'm not sure what the problem is, exactly.  But I do know that this is dealing with your Display.template.php


This is what the code SHOULD look like:
Find this code in your theme's Display.template.php
Code: [Select]
// Show how many posts they have made.
echo '
', $txt[26], ': ', $message['member']['posts'], '<br />
<br />';


And then REPLACE IT, that means delete it and replace it with code:
Code: [Select]
// Show how many posts they have made.
// echo '
// ', $txt[26], ': ', $message['member']['posts'], '<br />
// <br />';

            //BEGIN Shop MOD 0.2 Code
echo '
', $txt[26], ': ', $message['member']['posts'], '<br />
';

            //I couldn't find where all these $message['member'][whatever] variables
            //are set, so I just send an extra database query to get the member's
            //money. Can someone tell me where (file and line) the $message variables
            //are set?
            global $ID_MEMBER, $db_prefix;

            $result_money = db_query("SELECT money
                                      FROM {$db_prefix}members
                                      WHERE ID_MEMBER = {$message['member']['id']}
                                      LIMIT 1", __FILE__, __LINE__);
            $row_money = mysql_fetch_array($result_money, MYSQL_ASSOC);

            echo $modSettings['shopCurrencyPrefix'].$row_money['money'].$modSettings['shopCurrencySuffix']."<br><br>";
            //END SHOP MOD
           

//BEGIN SMFShop MOD 1.31 (Build 7) CODE
echo "<a href='$scripturl?action=shop;do=invother2;member={$message['member']['username']}'>View Inventory</a><br>";
//END SMFShop MOD 1.31 code

//BEGIN SMFShop MOD 2.2 (Build 10) code
echo "<a href='$scripturl?action=shop;do=sendmoney;member={$message['member']['username']}'>Send Money to {$message['member']['name']}</a><br />";
//END SMFShop code


Make sure you replace it EXACTLY or you'll end up getting an error.
Ambrosia's Castle - My Personal Site
The Dark Castle - My Forum
Avatar by:  Me

Offline leviyah

[split] Re: How to get shop working in other themes
« Reply #2 on: December 07, 2006, 09:07:52 pm »
I replaced it exactly.

Offline leviyah

[split] Re: How to get shop working in other themes
« Reply #3 on: December 08, 2006, 08:39:56 pm »
Can't attach it, and its to long to post it here. Where should i send it to?

Edited by Daniel15: Very large segment of code moved to http://paste.uni.cc/12051
« Last Edit: December 09, 2006, 12:13:51 pm by Daniel15 »

Offline Daniel15

[split] Re: How to get shop working in other themes
« Reply #4 on: December 09, 2006, 12:16:02 pm »
Please try changing the highlighted code at http://paste.uni.cc/12052, and tell me if it works for you.

Offline leviyah

[split] Re: How to get shop working in other themes
« Reply #5 on: December 09, 2006, 06:21:25 pm »
Another Error, when I try to view a thread

Offline leviyah

[split] Re: How to get shop working in other themes
« Reply #6 on: December 10, 2006, 03:06:43 am »
Help pls...


*bump*

Offline Daniel15

[split] Re: How to get shop working in other themes
« Reply #7 on: December 10, 2006, 10:32:20 am »
Hmmm... Looks like an error with the copying and pasting.
Restore the file from a backup, and then do the change I highlighted (make sure it's in the right spot)

Offline leviyah

[split] Re: How to get shop working in other themes
« Reply #8 on: December 10, 2006, 09:12:19 pm »
Well...
I did that what u told me. Now there is no error message when i view a thread, but, how mny credits a user has, is not displayed.
Not in Posts, not in profile.

Offline leviyah

[split] Re: How to get shop working in other themes
« Reply #9 on: December 10, 2006, 09:14:51 pm »
« Last Edit: December 10, 2006, 10:00:32 pm by leviyah »

Offline Daniel15

[split] Re: How to get shop working in other themes
« Reply #10 on: December 11, 2006, 12:52:39 pm »
leviyah, there appears to be _two_ sections you need to modify. Go down to line 714, and there's a similar section you need to modify.

Offline leviyah

[split] Re: How to get shop working in other themes
« Reply #11 on: December 11, 2006, 07:40:33 pm »
I love you, it works now =)

But one thing more:
How turn up, getting credits in some forums?
« Last Edit: December 11, 2006, 07:47:52 pm by leviyah »

Offline leviyah

[split] Re: How to get shop working in other themes
« Reply #12 on: December 12, 2006, 09:14:01 pm »
bump

Offline Lady Ambrosia

[split] Re: How to get shop working in other themes
« Reply #13 on: December 13, 2006, 03:26:24 am »
I love you, it works now =)

But one thing more:
How turn up, getting credits in some forums?

You can adjust credits for the shop through Admin --> Shop Administration --> General Settings  from there you can set currency settings and several other things as well.  You will be able to set credits per new topic and per new post.  Hope this helps ;)
Ambrosia's Castle - My Personal Site
The Dark Castle - My Forum
Avatar by:  Me

Offline leviyah

[split] Re: How to get shop working in other themes
« Reply #14 on: December 13, 2006, 11:20:26 pm »
no thats no help i want to turn off getting credits in some forums, for example in spam forum