SMFShop - Shop MOD

Started by SMFHacks.com Team, December 27, 2004, 06:46:17 AM

Previous topic - Next topic

chinaren

Howdy.  This is a great mod, I really desire it greatly!  ;)

I've installed it, but it doesn't show the images!! The images are there, in the file system if I look via FTP, but they just don't show up on the shop.   Everything else seems to work fine, though I haven't done extensive testing yet.

My board is un-modified 1.1.5 default theme with no mods exept this one.  I'm getting this in the error log:

Quote512: parseModification(): The filename 'Themes/default/Display.template.php' is not a full path!
File: /home/xxx/public_html/smf/Sources/Subs-Package.php
Line: 1339

      
http://xxx.com/smf/index.php?action=packages;sa=uninstall;package=ProfileImage_Item_0.1.zip

512: parseModification(): The filename 'Themes/default/Display.template.php' is not a full path!
File: /home/xxxpublic_html/smf/Sources/Subs-Package.php
Line: 1339

http://xxx.com/smf/index.php

Database Error: Table 'xxx_smf1.smf_shop_purchHis' doesn't exist
File: /home/tomecit/public_html/smf/Sources/SPortal.php
Line: 1343

Any ideas???    ???
The Opus Path - The Next Generation of the Written Word

LeBaux

Quote from: chinaren on August 21, 2008, 09:27:14 AM
Howdy.  This is a great mod, I really desire it greatly!  ;)

I've installed it, but it doesn't show the images!! The images are there, in the file system if I look via FTP, but they just don't show up on the shop.   Everything else seems to work fine, though I haven't done extensive testing yet.

My board is un-modified 1.1.5 default theme with no mods exept this one.  I'm getting this in the error log:

Quote512: parseModification(): The filename 'Themes/default/Display.template.php' is not a full path!
File: /home/xxx/public_html/smf/Sources/Subs-Package.php
Line: 1339

      
hxxp:xxx.com/smf/index.php?action=packages;sa=uninstall;package=ProfileImage_Item_0.1.zip [nonactive]

512: parseModification(): The filename 'Themes/default/Display.template.php' is not a full path!
File: /home/xxxpublic_html/smf/Sources/Subs-Package.php
Line: 1339

hxxp:xxx.com/smf/index.php [nonactive]

Database Error: Table 'xxx_smf1.smf_shop_purchHis' doesn't exist
File: /home/tomecit/public_html/smf/Sources/SPortal.php
Line: 1343

Any ideas???    ???

chmod themes folder to 777 or 755?

Adish - (F.L.A.M.E.R)

Should there be a separate Section in the admin panel ? I think i had seen it last time when i had this mod working on my test forum... but yet confirming it...

Riey

The bank has a bug, the credits never increase with the interest

chinaren

Quotechmod themes folder to 777 or 755?

Good point.  Okay, I did that, then uninstalled it, and re-installed it.  It got rid of the error messages, but I still can't see the shop images!!! 

I even changed the shop pictures directory to 777, just in case. 

Everything else in the shop works.  You can edit stuff, buy stuff and all that jazz, but it just doesn't show the images (in the admin panel or anywhere).  It's driving me mad!!!!  >:(

Again, this is SMF 1.1.5, on a new install, default theme with only this mod active. 

Any ideas?!?!   :'(
The Opus Path - The Next Generation of the Written Word

bfeo

#1625
I'd suggest 755, and did you recurse into sub?

Also, check the image size.  You may have set it to 0 or something.  It is on default at around 32 x 32 or something.  You cannot just set this to 0, because it will not then proceed to use the standard image size.  They all have to be the same.  Images smaller or larger will be resized.




I have a question about this mod.  In particular the steal item.  I wasn't very fond of using Karma, so I'm trying to change it from Karma to a reduction in the random number, which I set the variables of from 0-500, (mt_rand(0, 500)), or use

// Take this money away from stealee...
$result = db_query("
UPDATE {$db_prefix}members
SET money = money - {$steal_amount}
WHERE memberName = '{$user}'
LIMIT 1", __FILE__, __LINE__);
//...and give to stealer (robber)
$result = db_query("
UPDATE {$db_prefix}members
SET money = money + {$steal_amount}
WHERE ID_MEMBER = {$ID_MEMBER}
LIMIT 1", __FILE__, __LINE__);


And just switch either the + and -, or $user with $ID_MEMBER, but I'm not very good with PHP, and haven't been getting successful results.  How can I set it so that the person attempting to make the steal loses up to 500 credits, and gives that to the person they tried to steal from?

Here's the full bottom have of the file.  Assistance would be appreciated.

// We only want the first memberName found
$user = $userArray[0];

// Get a random number between 0 and 500
$try = mt_rand(0, 500);

// If successful
if ($try < $item_info[1])
{

// Get stealee's (person we're stealing from) money count
$result = db_query("
SELECT money
FROM {$db_prefix}members
WHERE memberName = '{$user}'", __FILE__, __LINE__);

// If user doesn't exist
if (mysql_num_rows($result) == 0)
die('ERROR: The specified user doesn\'t exist!');

$row = mysql_fetch_assoc($result);

// Get random amount between 0 and amount of money stealee has
$steal_amount = mt_rand(0, $row['money']);

// Take this money away from stealee...
$result = db_query("
UPDATE {$db_prefix}members
SET money = money - {$steal_amount}
WHERE memberName = '{$user}'
LIMIT 1", __FILE__, __LINE__);
//...and give to stealer (robber)
$result = db_query("
UPDATE {$db_prefix}members
SET money = money + {$steal_amount}
WHERE ID_MEMBER = {$ID_MEMBER}
LIMIT 1", __FILE__, __LINE__);

if ($steal_amount < 50)
return 'Steal successful, although you only stole ' . $steal_amount . '!';
else
return 'Successfully stole ' . $steal_amount . ' from ' . $user . '! It\'s their fault they don\'t have their money in the bank!';
}
else
{
// If reducing Karma doesn't work, replace
// 'karmaBad = karmaBad + 10' with 'karmaGood = karmaGood - 10'
$result = db_query("
UPDATE {$db_prefix}members
SET karmaBad = karmaBad + 10
WHERE ID_MEMBER = {$ID_MEMBER}", __FILE__, __LINE__);
   return 'Steal <b>unsuccessful!</b> Your Acclaim has been reduced by 10!  ...And you accidentally left some of your credits behind with the victim!';
}

}
}

?>

chinaren

QuoteI'd suggest 755, and did you recurse into sub?

Also, check the image size.  You may have set it to 0 or something.  It is on default at around 32 x 32 or something.  You cannot just set this to 0, because it will not then proceed to use the standard image size.  They all have to be the same.  Images smaller or larger will be resized.

I did recurse, and the image size is at the default 32x32.   :(
The Opus Path - The Next Generation of the Written Word

callteg4

Hi could somebody help my members credits dont seem to be showing in there profiles, it says credits but nothing next to it thanks in advance paul

souljaa

Hey guys, anyways, I just installed this mod for the shop here --
http://www.dansoftaustralia.net/smfshop_wiki/Items:Profile_Image
And I was just wondering, is there a way, where I would be able to add this item more than once, but with different images?
Like right now I added it, using one type of spefic image, is there a way where I would be able to add it again, but for other images?
Thanks
Souljaa

PM me for more information about staff. NOW HIRING.

Aaron

For those looking for a version of SMF Shop that works with SMF 2.0 Beta 4: have a look here.

Marcus Forsberg

Will this work whit 2.x?

And if not, will it do in the future?

[SiNaN]

Quote from: Aäron on August 28, 2008, 06:16:29 PM
For those looking for a version of SMF Shop that works with SMF 2.0 Beta 4: have a look here.
Former SMF Core Developer | My Mods | SimplePortal

Marcus Forsberg

Oh, stupid me.. didn't notice :P

chinaren

I still can't see any images on the shop.  Other images work fine now, it's only the shop ones, or any I upload to the shop directory. 

Anyone?  Anyone at all?   :-[
The Opus Path - The Next Generation of the Written Word

Mother Goose

Would it be acceptable to offer a zip file of shop icons in this thread? 
   

Adish - (F.L.A.M.E.R)

Quote from: F.L.A.M.E.R on August 21, 2008, 04:05:32 PM
Should there be a separate Section in the admin panel ? I think i had seen it last time when i had this mod working on my test forum... but yet confirming it...

tuguex

I have a litle problem whit my bank  ::)
I put 7% of interest in the bank,  but the "Money" after a day is still the same.
Anyone have a ideia what i should to dO?

thnks

bfeo

Quote from: Mother Goose on August 30, 2008, 12:11:10 PM
Would it be acceptable to offer a zip file of shop icons in this thread? 

Probably.  :)

Celdric

Quote from: chinaren on August 30, 2008, 09:13:06 AM
I still can't see any images on the shop.  Other images work fine now, it's only the shop ones, or any I upload to the shop directory. 

Anyone?  Anyone at all?   :-[


Hi. :) What is it showing instead of the pictures? Broken links or just white space? Click the "buy stuff" link and then take a look at your sites source code, if the item picture links are mentioned at all.

Celdric

Quote from: tuguex on September 01, 2008, 09:58:21 AM
I have a litle problem whit my bank  ::)
I put 7% of interest in the bank,  but the "Money" after a day is still the same.
Anyone have a ideia what i should to dO?

thnks


Did you read the note at the shop download page? :)

QuoteNOTE: In order to get the bank interest working, you MUST set a cron job. If your web host uses cPanel, please see http://www.daniel15.com/smfshop_wiki/Bank_Interest for details on how to get this working

Advertisement: