SMFShop - Shop MOD

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

Previous topic - Next topic

Bob Perry of Web Presence Consulting

Quote from: jack_1985 on June 27, 2014, 07:04:06 AM
Hi Bob,

It would be great if you could share some of your knowledge on this.  :D

The ChangeDisplay item works properly for me. I'm having trouble with an item that changes the style of a display name, for example to a different color. I used to have this item installed on 1.X, but after switching to 2.X, it no longer works. The problem is that when I use the item, it is giving me a blank screen.

This is the code of the item:
if (!defined('SMF'))
die('Hacking attempt...');

class item_ChangeDisplayNameCSS extends itemTemplate
{
function getItemDetails()
{
$this->authorName = 'Daniel15';
$this->authorWeb = 'http://www.dansoftaustralia.net/';
$this->authorEmail = '[email protected]';

$this->name = 'Change Display Name Style';
$this->desc = 'Change the style of your display name (style is admin-definable)';
$this->price = 75;

$this->require_input = false;
$this->can_use_item = true;
$this->addInput_editable = true;
}

function getAddInput()
{
global $item_info;
// If we're adding a new item, default to this.
if ($item_info[1] == '')
$item_info[1] = 'font-style:oblique';

return '
New Style: <input type="text" name="info1" value="' . $item_info[1] . '"><br />
NOTE: The "New Style" can be any CSS formatting property. <b>Do not</b> put a
semicolon (;) at the end as it is appended automatically.<br /><br />';
    }

function onUse()
{
global $db_prefix, $id_member, $item_info;

$result = db_query("
UPDATE {$db_prefix}members
SET shop_nameStyle = CONCAT(shop_nameStyle, '{$item_info[1]}; ')
WHERE id_member = {$id_member}", __FILE__, __LINE__);

return 'Successfully updated your display name style!';
}

}

?>


I have already made changes to the Source codes manually, so that styles that users have chosen in the past by using this item show up again. But the item itself can no longer be used.

Any ideas what the problem might be?

Although I've learned to create items relatively easily, I'm not good with style commands... i always have to tweak these dern things over and over again to get the results i want... if it dealt with the database directly I'd jump on it for ya, but this I will have to defer to the style sheet experts... my suggestion is to see if you can track down the person who originally created this item who may or may not be the one indicated in the internal document
Best Regards,
Bob Perry



"The world is moving so fast these days that the man who says it can't be done is generally interrupted by someone doing it." Elbert Hubbard

donrespeto

I installed the SopMod and i have got this problem:



Please tell me what should I do

vbgamer45

Looks like duplicate code added to your themes display.template file
Community Suite for SMF - Take your forum to the next level built for SMF, Gallery,Store,Classifieds,Downloads,more!

SMFHacks.com -  Paid Modifications for SMF

Mods:
EzPortal - Portal System for SMF
SMF Gallery Pro
SMF Store SMF Classifieds Ad Seller Pro

Neville

Hi everyone  :)
I posted in this topic, but it's not the right board. So I'm quoting my post here :)

QuoteI need some help about the SMFShop mod, but first please forgive me for my bad English.

Well, I've installed SMFShop on my forum, but i've noticed that the admin can't add item to member's inventories and it's a gap. For example: I organize a quiz on my forum, a user win it and i want to add an item to his inventory. How can i do? I could bought the item with an admin account and then give it to the user, but it's very boring and uncomfortable. Finally if i want to give to the member a special item which isn't in the shop, I can't.
Can someone help me? :(


Sorry for my bad English, again.

Thank in advance :)

jack_1985

Did anybody manage to get the buyAvatar item working in the Shop for SMF 2.X by any chance?

I can't seem to find a new version anywhere, unfortunately.

Ninja ZX-10RR

An user without being an "administrator" cannot access the admin/shop despite his permissions being set properly.
Quote from: BeastMode topic=525177.msg3720020#msg3720020
It's so powerful that on this post and even in the two PMs you sent me,you still answered my question very quickly and you're apologizing for the delay. You're the #1 support I've probably ever encountered man, so much respect for that. Thank you, and get better soon.

I'll keep this in my siggy for a while just to remind me that someone appreciated what I did while others didn't.

♥ Jess ♥

STOP EDITING MY PROFILE

Nisva

SQL logic error or missing database
unrecognized token: "`"
File: /home/a8987648/public_html/Sources/shop/Shop-Buy.php
Line: 157

I get this error when going to buy

vbgamer45

Community Suite for SMF - Take your forum to the next level built for SMF, Gallery,Store,Classifieds,Downloads,more!

SMFHacks.com -  Paid Modifications for SMF

Mods:
EzPortal - Portal System for SMF
SMF Gallery Pro
SMF Store SMF Classifieds Ad Seller Pro

Kindred

You have input something with a bad apostrophe character...   Possibly one of your items or descriptions pasted from word..
Слaва
Украинi

Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

"Loki is not evil, although he is certainly not a force for good. Loki is... complicated."

Kimmie

SAShop Mod, SMfShop. While looking at these, one of the main differences I see is that the SA one has a games area included which gives them a another option to make money. Can anyone tell me any other differences between these two mods. I am trying to decide which one would be better and I figured anyone who has used them will be able to help


Thanks :)

hcfwesker

Quote from: Kimmie on August 18, 2014, 08:15:19 PMCan anyone tell me any other differences between these two mods.

I used them both and tested which I preferred.  And personally, I prefer the SA Shop mod just for the convenience of being able to adjust shops points earned  in each individual board, and select boards which shop money is not earned.  Not sure if it's changed in the past few years, but once SMF Shop is installed, all boards earn the same amount of cash for topics and posts.  I've seen a few request this recently which leads me to believe its still the same.

Bob Perry of Web Presence Consulting

#2931
Quote from: Kimmie on August 18, 2014, 08:15:19 PM
SAShop Mod, SMfShop. While looking at these, one of the main differences I see is that the SA one has a games area included which gives them a another option to make money. Can anyone tell me any other differences between these two mods. I am trying to decide which one would be better and I figured anyone who has used them will be able to help


Thanks :)

I too have used them both, my current one is SMFShop, simply because I find creating items is much easier with this...
Best Regards,
Bob Perry



"The world is moving so fast these days that the man who says it can't be done is generally interrupted by someone doing it." Elbert Hubbard

Bob Perry of Web Presence Consulting

#2932
Speaking of creating items, I've attached one of mine here for anyone who's interested...

This one allows a member to steal, or attempt to steal, another member's Karma. If the robber is unsuccessful, he gets bad Karma, but whether the steal is successful or not, the victim is notified by PM that someone is messing with their Karma, but not informed exactly who did it, lol!!

Site admin definable probability factor for success or failure, and I can modify your site Statistics page to keep tabs on the top members for both good and bad karma...
Best Regards,
Bob Perry



"The world is moving so fast these days that the man who says it can't be done is generally interrupted by someone doing it." Elbert Hubbard

Clarey

I recently re-installed this mod on my forums, I did nothing to the mod other then remove the default images and add in a set of icons for our shop items, now when we go into admin and try to add an item or edit an item our webpage is just a blank page. This happens on all themes and the default theme as well. Any ideas as to what is causing this?

vbgamer45

Check your forum's error log for any related errors.
Community Suite for SMF - Take your forum to the next level built for SMF, Gallery,Store,Classifieds,Downloads,more!

SMFHacks.com -  Paid Modifications for SMF

Mods:
EzPortal - Portal System for SMF
SMF Gallery Pro
SMF Store SMF Classifieds Ad Seller Pro

Clarey

Quote from: vbgamer45 on August 20, 2014, 11:47:59 AM
Check your forum's error log for any related errors.

There are no errors in the logs relating to this

Mstcool

Any way I can remove the "use item" button for the "test" item? I don't wanna delete it for the other items, just the test item so that when people buy the test item, they don't use it.

The way it works at my forum is that they buy ad space using the credits they earned from posting, I renamed the test items to different things. I want them to purchase those and private message me informing me that they have bought it. After they have bought it, I will delete that item from their inventory and add their banner to the space that they have rented. So, I don't want them to be able to click on "use item".

Bob Perry of Web Presence Consulting

Quote from: Mstcool on August 23, 2014, 10:38:05 PM
Any way I can remove the "use item" button for the "test" item? I don't wanna delete it for the other items, just the test item so that when people buy the test item, they don't use it.

The way it works at my forum is that they buy ad space using the credits they earned from posting, I renamed the test items to different things. I want them to purchase those and private message me informing me that they have bought it. After they have bought it, I will delete that item from their inventory and add their banner to the space that they have rented. So, I don't want them to be able to click on "use item".

If you are familiar with editing source files it should be a snap for ya, find the follow line of code inside the source for the test item and change true to false...

      // Set this to 'false' if the item is unusable. This is good for display
      // items.
      $this->can_use_item = true;
Best Regards,
Bob Perry



"The world is moving so fast these days that the man who says it can't be done is generally interrupted by someone doing it." Elbert Hubbard

Mstcool

Quote from: Bob Perry on August 23, 2014, 11:16:13 PM
Quote from: Mstcool on August 23, 2014, 10:38:05 PM
Any way I can remove the "use item" button for the "test" item? I don't wanna delete it for the other items, just the test item so that when people buy the test item, they don't use it.

The way it works at my forum is that they buy ad space using the credits they earned from posting, I renamed the test items to different things. I want them to purchase those and private message me informing me that they have bought it. After they have bought it, I will delete that item from their inventory and add their banner to the space that they have rented. So, I don't want them to be able to click on "use item".

If you are familiar with editing source files it should be a snap for ya, find the follow line of code inside the source for the test item and change true to false...

      // Set this to 'false' if the item is unusable. This is good for display
      // items.
      $this->can_use_item = true;


I haven't learned php yet. What file would I edit? :P

Bob Perry of Web Presence Consulting

You'll want to edit either /Sources/shop/items/testitem.php OR same directory but file named testitem2.php

be sure to leave everything as is except the word true, change that to false and be sure you don't mistakenly delete the ending colon...

then just replace the live file with the edited one and you should not see a use button after its purchased...

Best Regards,
Bob Perry



"The world is moving so fast these days that the man who says it can't be done is generally interrupted by someone doing it." Elbert Hubbard

Advertisement: