Advertisement:
GCWebhosting

Author Topic: SMFShop - Shop MOD  (Read 1193788 times)

Offline KuraWeb

  • Semi-Newbie
  • *
  • Posts: 14
Re: SMFShop - Shop MOD
« Reply #40 on: January 01, 2005, 07:21:48 PM »
Quote
The Subs.php error is caused by Dreamweaver.  It mangles php files when you edit them.

-[Unknown]

I'm using Dreamweaver and this $·%$" program destroy all the file.


I'love the Subs.php~

Offline [Unknown]

  • SMF Friend
  • SMF Master
  • *
  • Posts: 36,102
  • Gender: Male
Re: SMFShop - Shop MOD
« Reply #41 on: January 01, 2005, 11:01:59 PM »
If you have problems with Wordpad, well, I don't know if Wordpad mangles files.... I've never used it for text file editing and never plan to.  I strongly suggest you use ConTEXT instead - www.context.cx.

Dreamweaver seems to be okay *usually*, but I've seen it mangle more complicated PHP files on many occasions.  I have no idea if there's a patch, the tenth or so time it happened to me was when I decided I'd never use the program again.  Luckily I was using it at school, so I didn't ever buy it.

-[Unknown]

Offline russ

  • Jr. Member
  • **
  • Posts: 104
Re: SMFShop - Shop MOD
« Reply #42 on: January 02, 2005, 04:26:02 AM »
I got this error. Now my site is froze up.

Fatal error: Call to undefined function: showbanner() in /home/xxxxxxx/xxxxxxx/forum/Sources/Load.php(1036) : eval()'d code on line 287

This happened after I tried to modify the SUB.PHP file again, then it spit out an error. When I put the original back, it gave me this.. error above.... Im stumped. :'(

Yeha i had that problem as well, remove temporarily from your files, the ssi command for showing the banner mod which i assume u have installed as well... then get rid of the banner mod from your package manager as whenever that is installed it seems to muck up version 1.0 - hope that helps

Offline Senkusha

  • Full Member
  • ***
  • Posts: 625
  • Gender: Male
  • Embrace Your Destiny!
    • Ayeka's Bliss
Re: SMFShop - Shop MOD
« Reply #43 on: January 04, 2005, 04:46:24 PM »
If you want to 'catch up' on the amount of money that each member should have (from the birth of the forum), you can use this little script that I created.  Just change the numbers to reflect your values:


Code: [Select]
<?php

$NewTopics 
10;
$NewPosts 8;

mysql_connect(&#39;localhost&#39;,&#39;root&#39;,&#39;&#39;);
mysql_select_db(&#39;smf&#39;);
$request mysql_query ("SELECT smf_members.realName, 
smf_members.ID_MEMBER AS ID_MEMBER, 
count(ID_TOPIC) AS var
FROM smf_members, 
smf_topics
WHERE smf_members.ID_MEMBER = smf_topics.ID_MEMBER_STARTED
GROUP BY smf_members.realName
ORDER BY smf_members.realName"
);

while (
$result mysql_fetch_assoc($request))
{
$variable $result[&#39;var&#39;] * $NewTopics;
$person $result[&#39;ID_MEMBER&#39;];
$request1 mysql_query ("UPDATE smf_members
SET money = &#39;
$variable&#39;
WHERE ID_MEMBER = &#39;
$person&#39;");
}

$request mysql_query ("SELECT smf_members.realName, 
smf_members.ID_MEMBER AS ID_MEMBER, 
count(ID_MSG) AS var, 
smf_members.money AS money
FROM smf_members, 
smf_messages
WHERE smf_members.ID_MEMBER = smf_messages.ID_MEMBER
GROUP BY smf_members.realName
ORDER BY smf_members.realName"
);

while (
$resultmysql_fetch_assoc($request))
{
$variable $result[&#39;var&#39;] * $NewPosts;
$person $result[&#39;ID_MEMBER&#39;];
$money $result[&#39;money&#39;] + $variable;
$request1 mysql_query ("UPDATE smf_members
SET money = &#39;
$money&#39;
WHERE ID_MEMBER = &#39;
$person&#39;");

}
?>


Offline Senkusha

  • Full Member
  • ***
  • Posts: 625
  • Gender: Male
  • Embrace Your Destiny!
    • Ayeka's Bliss
Re: SMFShop - Shop MOD
« Reply #44 on: January 04, 2005, 04:55:35 PM »
On another note:  In a future version, would it be possible to "use" items on other members?

Offline Daniel15

  • SMF Friend
  • SMF Hero
  • *
  • Posts: 4,222
  • Gender: Male
  • http://dan.cx/
    • daaniel on Facebook
    • Daniel15 on GitHub
    • daniel15 on LinkedIn
    • @Daniel15 on Twitter
    • Daniel15
Re: SMFShop - Shop MOD
« Reply #45 on: January 04, 2005, 10:54:14 PM »
If you want to 'catch up' on the amount of money that each member should have (from the birth of the forum), you can use this little script that I created.  Just change the numbers to reflect your values:

Code: [Select]
<?php

$NewTopics 
10;
$NewPosts 8;

mysql_connect(&#39;localhost&#39;,&#39;root&#39;,&#39;&#39;);
mysql_select_db(&#39;smf&#39;);
$request mysql_query ("SELECT smf_members.realName, 
smf_members.ID_MEMBER AS ID_MEMBER, 
count(ID_TOPIC) AS var
FROM smf_members, 
smf_topics
WHERE smf_members.ID_MEMBER = smf_topics.ID_MEMBER_STARTED
GROUP BY smf_members.realName
ORDER BY smf_members.realName"
);

while (
$result mysql_fetch_assoc($request))
{
$variable $result[&#39;var&#39;] * $NewTopics;
$person $result[&#39;ID_MEMBER&#39;];
$request1 mysql_query ("UPDATE smf_members
SET money = &#39;
$variable&#39;
WHERE ID_MEMBER = &#39;
$person&#39;");
}

$request mysql_query ("SELECT smf_members.realName, 
smf_members.ID_MEMBER AS ID_MEMBER, 
count(ID_MSG) AS var, 
smf_members.money AS money
FROM smf_members, 
smf_messages
WHERE smf_members.ID_MEMBER = smf_messages.ID_MEMBER
GROUP BY smf_members.realName
ORDER BY smf_members.realName"
);

while (
$resultmysql_fetch_assoc($request))
{
$variable $result[&#39;var&#39;] * $NewPosts;
$person $result[&#39;ID_MEMBER&#39;];
$money $result[&#39;money&#39;] + $variable;
$request1 mysql_query ("UPDATE smf_members
SET money = &#39;
$money&#39;
WHERE ID_MEMBER = &#39;
$person&#39;");

}
?>


hey, i might put that script in the next version of SMFShop (well in the installer amyway). thanks for that ;)


Quote
On another note:  In a future version, would it be possible to "use" items on other members?
I'm assuming you mean items such as Reduce someone else's post count, steal items, change other's signature, etc, etc, etc. In that case, most likely... those items are really cool :)
Daniel15, former Customisation team member, resigned due to lack of time. I still love everyone here :D.
Go to smfshop.com for SMFshop support, do NOT email or PM me!

Offline Senkusha

  • Full Member
  • ***
  • Posts: 625
  • Gender: Male
  • Embrace Your Destiny!
    • Ayeka's Bliss
Re: SMFShop - Shop MOD
« Reply #46 on: January 05, 2005, 02:56:47 AM »
Actually I had other things in mind.  I run an anime based website, and would have things that you could buy like a wooden mallot and do damage to other members (a new database field called Health or something, but yes, in general, have the ability to help or harm another member in some way.

Instead of just having a "use item" link you could have have a link like:  "Use Item on" (dropdown).  The dropdown would have a listing of all members, including yourself.  You could probably also make the selected member yourself.

Also, would it be possible to add more ways to earn money?  For instance each attachment a member posts could earn 15 credits and each poll that a member creates could earn 20.
« Last Edit: January 05, 2005, 09:07:32 AM by Senkusha »

Offline Squeakypants

  • Semi-Newbie
  • *
  • Posts: 19
Re: SMFShop - Shop MOD
« Reply #47 on: January 05, 2005, 07:57:03 PM »
I'm working on a simple replacement now (with basic php), but one item needed is a for real world things. The way I am making it is it will send an email to x email with the user name and verification number (random). Then they can print out the coupon, which will also have the verification number. I can't say why I need it, but I don't think I am the only one who needs it. At least the email part (for t-shirts and such)

btw, I have been waiting for this for awhile. i'll help as much as I can, and I thank you for making it so easy to make items.

Offline DoW Kid Rock

  • Jr. Member
  • **
  • Posts: 139
  • Gender: Male
    • Disciples of Wrestling
Re: SMFShop - Shop MOD
« Reply #48 on: January 05, 2005, 09:39:38 PM »
can't seem to find the download for the newest version.  all I get is .1 beta

also for those of you that have dreamweaver on the install disc is an install for homesite and that is what I use to edit php files and it works great.  especially for searching for the right code.  it also colour codes everything to make it easier to find things.

have been waiting for this...and so have my members as I had IBshop on my invision board and it was awesome in conjunction with an arcade.  meaning people had to build up money to play the games.  would love to see it integrated that way

Offline Elijah Bliss

  • Sophist Member
  • *****
  • Posts: 1,340
Re: SMFShop - Shop MOD
« Reply #49 on: January 05, 2005, 09:42:52 PM »
I'm working on a simple replacement now (with basic php), but one item needed is a for real world things. The way I am making it is it will send an email to x email with the user name and verification number (random). Then they can print out the coupon, which will also have the verification number. I can't say why I need it, but I don't think I am the only one who needs it. At least the email part (for t-shirts and such)

btw, I have been waiting for this for awhile. i'll help as much as I can, and I thank you for making it so easy to make items.

I haven't tried this mod out yet, but does it have paypal functionality? After working on a project recently, I have enough PHP/MySQL knowledge to make a customized paypal page for each respective retailer if needed.

Offline DoW Kid Rock

  • Jr. Member
  • **
  • Posts: 139
  • Gender: Male
    • Disciples of Wrestling
Re: SMFShop - Shop MOD
« Reply #50 on: January 06, 2005, 11:47:58 AM »

I haven't tried this mod out yet, but does it have paypal functionality? After working on a project recently, I have enough PHP/MySQL knowledge to make a customized paypal page for each respective retailer if needed.

this is a fun "shop" if I am not mistaken, where no real money is changing hands.  I think that if you wanted it to be used with real money  (i.e. selling merchandise) you could use this in conjunction with the donation mod and manually put money in people's accounts.

Offline Jesse Shaw

  • Semi-Newbie
  • *
  • Posts: 57
  • Gender: Male
  • "Our destiny is determined by the choices we make"
    • TechyHut
Re: SMFShop - Shop MOD
« Reply #51 on: January 06, 2005, 02:40:44 PM »
Quote
If you have problems with Wordpad, well, I don't know if Wordpad mangles files.... I've never used it for text file editing and never plan to.  I strongly suggest you use ConTEXT instead - www.context.cx.

Dreamweaver seems to be okay *usually*, but I've seen it mangle more complicated PHP files on many occasions.  I have no idea if there's a patch, the tenth or so time it happened to me was when I decided I'd never use the program again.  Luckily I was using it at school, so I didn't ever buy it.

-[Unknown]

Wordpad displays the files better than notepad. It wont mangle them if you just save as simple text. That way it removes all formating. Dreamweaver seems to only be good for html files. I never had any luck using it for anything other than html files.  I like wordpad better than notepad but thats a personal opinion.  :D
Jesse


Offline Squeakypants

  • Semi-Newbie
  • *
  • Posts: 19
Re: SMFShop - Shop MOD
« Reply #52 on: January 06, 2005, 07:42:59 PM »
I HATE wordpad. I use Word for anything formatted. For editing I use ConTEXT, unless it's just for a second then I use notepad.

The new ConTEXT looks great :-D

btw, to download .2 you have to go to daniel's site. He prolly uploaded the wrong file (it says .2 in title, but the file is .1)

Offline magicmule

  • Newbie
  • *
  • Posts: 8
Re: SMFShop - Shop MOD
« Reply #53 on: January 07, 2005, 06:38:30 AM »
i cant find the shop_install.php , wehre is this file ? sorry for my englisch 8)

Offline Tony Reid

  • SMF Friend
  • SMF Hero
  • *
  • Posts: 4,151
  • Gender: Male
    • @AbsoluteBreeze on Twitter
    • www.fertilityfriends.co.uk
Re: SMFShop - Shop MOD
« Reply #54 on: January 07, 2005, 06:50:36 AM »
I suppose you could also have a 'buy a bigger IM allowance' as well :)

Tony Reid


My Big Board
www.FertilityFriends.co.uk/forum - An SMF powered forum with over 5 million posts

Offline magicmule

  • Newbie
  • *
  • Posts: 8
Re: SMFShop - Shop MOD
« Reply #55 on: January 07, 2005, 01:05:05 PM »
how can i do this ?

Offline Daniel15

  • SMF Friend
  • SMF Hero
  • *
  • Posts: 4,222
  • Gender: Male
  • http://dan.cx/
    • daaniel on Facebook
    • Daniel15 on GitHub
    • daniel15 on LinkedIn
    • @Daniel15 on Twitter
    • Daniel15
Re: SMFShop - Shop MOD
« Reply #56 on: January 07, 2005, 09:56:08 PM »
the download for 0.2 appears to have dissappeared... it was there one day, and i look now and it is gone... I'm reuploading it now.

Quote
i cant find the shop_install.php , wehre is this file ? sorry for my englisch
The shop_install.php file is located in the ZIP file. Extract all files and you will see it. I think you downloaded version 0.1 by accident, because 0.1 didn't have a shop_install.php file...

Hopefully I will work on the new version soon, but with me being busy, and school starting soon, etc, etc,etc i might not get any time
Daniel15, former Customisation team member, resigned due to lack of time. I still love everyone here :D.
Go to smfshop.com for SMFshop support, do NOT email or PM me!

Offline LostProphecy

  • Jr. Member
  • **
  • Posts: 381
  • Gender: Female
    • The Lost Prophecy
Re: SMFShop - Shop MOD
« Reply #57 on: January 08, 2005, 02:10:15 AM »
just a few questions about this...

is there anyway of disabling the  "use" feature... i don't plan on using any of the items that you have for sale and i merely want to use it for adding my own "play" items for my site and i want them to always remain in the inventory list so that admins can view them and such (i'm adding features like - start your own board) these things will have to be actioned by an admin... so basicly i want to disable the "use" button... i'm sure i could find the code if i wanted but it would be so much easier to know where to find it ;)
Angelus Ex Quo Nox

Offline Daniel15

  • SMF Friend
  • SMF Hero
  • *
  • Posts: 4,222
  • Gender: Male
  • http://dan.cx/
    • daaniel on Facebook
    • Daniel15 on GitHub
    • daniel15 on LinkedIn
    • @Daniel15 on Twitter
    • Daniel15
Re: SMFShop - Shop MOD
« Reply #58 on: January 08, 2005, 11:52:50 PM »
If you want to create your own item, make a copy of the item_testitem2.php in the Sources/shop/items/ directory. Open it with your favourite editor, and if you can understand PHP, it should be easy to understand how to create an item.

If you want to make an item unusable, go to the onUse() function (it looks like this in the test item):
Code: [Select]
    function onUse() {
        return "Hello, I am a test!<br>This is all the test item does!!";
    }

Instead of returning something, do change that code to something like this:

Code: [Select]
    function onUse() {
        die("Sorry, you can't use this item");
    }

This will prevent the item from being used (the only text displayed will be "Sorry, you can't use this item"). And, the item will remain in the members inventory.

--daniel15
Daniel15, former Customisation team member, resigned due to lack of time. I still love everyone here :D.
Go to smfshop.com for SMFshop support, do NOT email or PM me!

Offline russ

  • Jr. Member
  • **
  • Posts: 104
Re: SMFShop - Shop MOD
« Reply #59 on: January 09, 2005, 11:54:38 AM »
How do you view other peoples inventories - ie one member seeing what sum1 else has bought?

for example add an extra variable to few a particular person?

Code: [Select]
http://www.myforum.com/smf/index.php?action=shop;do=inv;u=100 (100 being the member number for instance)
« Last Edit: January 09, 2005, 11:56:40 AM by russ »