vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   uCash & uShop (https://vborg.vbsupport.ru/forumdisplay.php?f=100)
-   -   uCash & uShop old support and thank you thread (https://vborg.vbsupport.ru/showthread.php?t=73736)

Zachery 06-24-2004 04:28 PM

Quote:

Originally Posted by 7thgenCivic.Com
is there an update on the status of the next release? I am waiting for al the bug fixes and what not. But my users are getting antsy.

WEre working on finishing the update to the shoutbox, and im fairly sure that uCS is next on our list :)

Mr. Brian 06-24-2004 04:55 PM

Quote:

Originally Posted by tjdrico
I have released vBookie, a 'bookmaking' or betting extension for vBulletin. I'm mentioning it here because there's an option to use uCash instead of its own built-in cash. This would give your forum members another way to make (or lose) money, and something else to do with the money they have.

So what should be placed in my postbit?

Code:

                                        $vbphrase[posts]: $post[posts] |        <if condition="$bbuserinfo['usergroupid'] == '6'"><a href="ushop.php?do=a&shortname=admindonate&userid=$post[userid]" target="_blank">Points</a><else />Points</if>: $points (<a href="ushop.php?do=a&shortname=donate&userid=$post[userid]" target="_blank">Donate</a>)
OR this?

Code:

<if condition="$vbookiesettings['cashon']">
                                        <br />vCash: $post[vbookie_cash]
                                        </if>


House_of_Crazed 06-24-2004 06:15 PM

Couple questions :)

1. I see in ushop.php the $points variable, however, it only takes in account for the money the users has out from the bank. What I want to do is to change it to take in account for the money that users also has in the bank. What should I change it to?

2. What is the variable that you are using for how much money the user has in the bank? I looked in the database and saw all those weird numbers in the bankdata row in the user table. I am assuming you are also using $bankdata as the variable for how much money is in the bank for the user.

3. You are aware that the database is showing more than 2 numbers after the decimal in the bank / money on hand.

4. For this, I will use A & B's. Assume those 2 are 2 different people. A has $50 on hand. If A tries to steal $100 from B, and FAILS. He will lose that amount of money, and his money on hand becomes a negative number and A will be denied access to the bank. However, A does have money in the bank, he should be able to go into the bank anyway.

HoC

Matt Bush 06-25-2004 08:51 PM

I've been looking for the vB 2.2.X version for this... can anyone point me in the right direction on where to find it. Like the name of it.

Zachery 06-25-2004 08:53 PM

The only vB2 hack that acted in any similar way, was leasnes, and he has asked it removed from the site, sorry.

House_of_Crazed 06-25-2004 11:16 PM

Can anyone help me with my 4 questions?? :)


HoC

Matt Bush 06-26-2004 03:01 AM

Alright, I'm a newbie at this vB Mod Stuff. Whenever I click donate or something it brings up the error

Code:

Database error in vBulletin 3.0.1:

Invalid SQL: SELECT actionid FROM utt_store_action WHERE shortname='admindonate'
mysql error: Table 'ssdatabase.utt_store_action' doesn't exist

mysql error number: 1146

Date: Friday 25th of June 2004 08:59:44 PM
Script: http://showdownshop.com/forum/ushop....nate&userid=36
Referer:
Username: Khalil Greene
IP Address: 68.101.189.178

Please help me.

Matt Bush 06-26-2004 04:54 AM

I think I figured it out. The install button didn't install the tables. Is there any way that I can get a copy of the tables and put them in manually?

Zachery 06-26-2004 05:13 AM

Quote:

Originally Posted by Matt Bush
I think I figured it out. The install button didn't install the tables. Is there any way that I can get a copy of the tables and put them in manually?

What do you mean the install button didnt install the tables?

Matt Bush 06-26-2004 05:17 AM

Quote:

Originally Posted by Zachery
What do you mean the install button didnt install the tables?

One of my buddies said that once you click the install button, the tables that are needed for the mod, get placed in your database... I wasn't sure if it is true or not.

But I do need the tables for this hack.

sabret00the 06-26-2004 11:30 AM

that information would be false matt, you need to run the installer

Matt Bush 06-26-2004 03:07 PM

Quote:

Originally Posted by sabret00the
that information would be false matt, you need to run the installer

If you couldn't already tell I'm new with this vB stuff. When I click install, what does it do?

rabbitdog 06-26-2004 03:11 PM

I don't think this has been addressed, because I still see the unfixed code in the zip file available for download, so I'd like to point out the fact that there is a critical bug in the uShop change username action.

This affects all current installations of the uStore with this item available for purchase.

The issue is as follows:

The "sanity" check which queries the database to see if a user already exists before accepting a changed username will never find any matches. This is because of the usage of an empty (incorrect) variable in the query.

The result is that any user can change his or her username to that of an existing user.

Note that this does NOT change permissions, so a user changing his name to that of a mod or an admin will not inherit access to those functions.

Here is the fix:

1. Open action.changeusername.php, which is stored in the /uttstore/ directory
2. Change line 5 from:

PHP Code:

$changed $DB_site->query_first("SELECT userid, username FROM ".TABLE_PREFIX."user WHERE username='".addslashes($data)."'"); 

to:

PHP Code:

$changed $DB_site->query_first("SELECT userid, username FROM ".TABLE_PREFIX."user WHERE username='".addslashes($username)."'"); 


Link14716 06-26-2004 09:41 PM

Quote:

Originally Posted by rabbitdog
I don't think this has been addressed, because I still see the unfixed code in the zip file available for download, so I'd like to point out the fact that there is a critical bug in the uShop change username action.

This affects all current installations of the uStore with this item available for purchase.

The issue is as follows:

The "sanity" check which queries the database to see if a user already exists before accepting a changed username will never find any matches. This is because of the usage of an empty (incorrect) variable in the query.

The result is that any user can change his or her username to that of an existing user.

Note that this does NOT change permissions, so a user changing his name to that of a mod or an admin will not inherit access to those functions.

Here is the fix:

1. Open action.changeusername.php, which is stored in the /uttstore/ directory
2. Change line 5 from:

PHP Code:

$changed $DB_site->query_first("SELECT userid, username FROM ".TABLE_PREFIX."user WHERE username='".addslashes($data)."'"); 

to:

PHP Code:

$changed $DB_site->query_first("SELECT userid, username FROM ".TABLE_PREFIX."user WHERE username='".addslashes($username)."'"); 


Nice catch. $data is used in several functions, but it looks like it shouldn't there. ;)

Fixed for 0.95.

GeekyDesigns 06-26-2004 10:01 PM

PHP Code:

6a9bb87ef571024592ec153b259803a0 

Post created by the GeekyDesigns vB License Verification Hash System.

Hash will be changed regularly.

GeekyDesigns 06-26-2004 10:06 PM

wootage, it worked

Zachery 06-26-2004 10:16 PM

teh woot

Taco John 06-27-2004 08:42 AM

Question: Can I make this hack so that only certain usergroups can use it?

hitmanuk2k 06-27-2004 10:37 AM

why is the cost showing up as 0.0 for everything on ushop.php? even though i have it set to larger numbers...

b4ne 06-27-2004 11:54 AM

Hi

I have this error that I have no links nowher in my Admin CP or anywhere else on the page, also when I check permission, there is no mention of this .

If I got to the ushop.php page : No Actions found.

Otherwise :
Installation : Manual (did a deinstall and reinstall)

Board vb 3.0.1

Also the very first time I try to connect to ushop.php I get some error in ushop.php on line 144 ?

But this error disapears.

And I wanted to also mention that I run the betting hack.

Any idea ?

hitmanuk2k 06-27-2004 01:09 PM

I need to know why items are appearing out of stock even though the quantity says there is some available???

SmasherMaster 06-27-2004 02:31 PM

Problem, I had installed the v3 arcade. And now when I tried to install the ushop on another board, here's the error it always says above the banner.

Warning: Invalid argument supplied for foreach() in
/home/****/public_html/ozone/forums/global.php on
line 628

Now here's line 628: foreach ($storeactions as $actionid => $theaction) {

Here's what happens when someoen tries to view a thread:

Warning: Cannot modify header information - headers already sent by (output started at /home/****/public_html/ozone/forums/global.php:628) in /home/****/public_html/ozone/forums/includes/functions.php on line 2836

Line 2836 of functions.php: header("Location: $url");

And finally, it says this when attempting to access the admincp:

Unable to add cookies, header already sent.
File: /home/****/public_html/ozone/forums/global.php
Line: 628

What has gone wrong! I can't install ushop and I can't rebuild the database, because these errrors pop up! What's going on!

Roxie 06-27-2004 03:25 PM

I get this error once I confirm that I want to steal:

Quote:

Invalid SQL: UPDATE user SET uttpoints=uttpoints+5, reputation=reputation- WHERE userid='1'
mysql error: You have an error in your SQL syntax. Check the manual that corresponds to your MySQL server version for the right syntax to use near 'WHERE userid='1'' at line 1

Link14716 06-27-2004 03:35 PM

Quote:

Originally Posted by SmasherMaster
Problem, I had installed the v3 arcade. And now when I tried to install the ushop on another board, here's the error it always says above the banner.

Warning: Invalid argument supplied for foreach() in
/home/****/public_html/ozone/forums/global.php on
line 628

Now here's line 628: foreach ($storeactions as $actionid => $theaction) {

Here's what happens when someoen tries to view a thread:

Warning: Cannot modify header information - headers already sent by (output started at /home/****/public_html/ozone/forums/global.php:628) in /home/****/public_html/ozone/forums/includes/functions.php on line 2836

Line 2836 of functions.php: header("Location: $url");

And finally, it says this when attempting to access the admincp:

Unable to add cookies, header already sent.
File: /home/****/public_html/ozone/forums/global.php
Line: 628


What has gone wrong! I can't install ushop and I can't rebuild the database, because these errrors pop up! What's going on!

Did you happen to edit includes/init.php?

Link14716 06-27-2004 03:37 PM

Quote:

Originally Posted by hitmanuk2k
I need to know why items are appearing out of stock even though the quantity says there is some available???

This is a confirmed bug. It says out of stock when you don't have enough points to buy it. It'll be fixed in the next release, or you can apply this fix:

Quote:

Originally Posted by dstruct2k
IN TEMPLATE "uttstore_main_actionbits":

Find:
Code:

    <td class="thead"><span style="float: right;"><if condition="$points >= $cost && $action['quantity'] != 0"><a style="text-decoration: none;" href="ushop.php?do=a&aid=$action[actionid]">[ Buy ]</a><else /> Out of Stock </if></span>Cost: $cost - <a href="ushop.php?do=actionhistory&aid=$action[actionid]">Recent Purchases?</a></td>
Replace with:
Code:

    <td class="thead"><span style="float: right;"><if condition="$points >= $cost && $action['quantity'] != 0"><a style="text-decoration: none;" href="ushop.php?do=a&aid=$action[actionid]">[ Buy ]</a><else /><if condition="$points >= $cost"> Out of Stock <else /> Insufficient Funds! </if></if></span>Cost: $cost - <a href="ushop.php?do=actionhistory&aid=$action[actionid]">Recent Purchases?</a></td>


Link14716 06-27-2004 03:39 PM

Quote:

Originally Posted by b4ne
Hi

I have this error that I have no links nowher in my Admin CP or anywhere else on the page, also when I check permission, there is no mention of this .

If I got to the ushop.php page : No Actions found.

Otherwise :
Installation : Manual (did a deinstall and reinstall)

Board vb 3.0.1

Also the very first time I try to connect to ushop.php I get some error in ushop.php on line 144 ?

But this error disapears.

And I wanted to also mention that I run the betting hack.

Any idea ?

For the first problem, you didn't edit admincp/index.php.

For the second error, are you sure you edited global.php and includes/init.php correctly? Do any actions show in the navbar drop-down?

Roxie 06-27-2004 04:04 PM

Quote:

Originally Posted by Roxie
I get this error once I confirm that I want to steal:

It looks like maybe there is an error when subtracting reputation??

Zachery 06-27-2004 04:12 PM

Quote:

Originally Posted by Matt Bush
If you couldn't already tell I'm new with this vB stuff. When I click install, what does it do?

:) it lets us keep a running count of how many sites youve installed, it also lets you know that youve installed the mod, come down the road you jneed to upgrade and forget what mods yo8ur running ;)

Link14716 06-27-2004 04:41 PM

Quote:

Originally Posted by Roxie
It looks like maybe there is an error when subtracting reputation??

Yes, it appears that way. The only thing I can think of is a bad action specific variable for the Thief action.

Edit the Thief action in the admincp and make sure these two options exist and have a (numerical) value entered into them:

Quote:

Reputation Lost On Successful Thievery?
Set this to the amount of reputation points that are lost when a member successfully steals money from another user. Make it negative you gice reputation.
Quote:

Reputation Lost On Failed Thievery?
Set this to the amount of reputation points that are lost when a member attempts and fails to steal money from another user. Make it negative you gice reputation.
EDIT: Hah, nothing like giving support to find typos in things. ;)

House_of_Crazed 06-27-2004 04:49 PM

Hm, I'm starting to wonder if I'm being ingored on purpose.

And FYI - Your license hash thingy on GeekyDesigns isn't working. I verified myself last night, then checked this morning, still don't have access. O_o

HoC

Link14716 06-27-2004 05:41 PM

Quote:

Originally Posted by House_of_Crazed
Hm, I'm starting to wonder if I'm being ingored on purpose.

And FYI - Your license hash thingy on GeekyDesigns isn't working. I verified myself last night, then checked this morning, still don't have access. O_o

HoC

You are not being ignored on purpose. And I checked in the admincp and you are marked as Licensed.

Quote:

Originally Posted by House_of_Crazed
Couple questions :)

1. I see in ushop.php the $points variable, however, it only takes in account for the money the users has out from the bank. What I want to do is to change it to take in account for the money that users also has in the bank. What should I change it to?

2. What is the variable that you are using for how much money the user has in the bank? I looked in the database and saw all those weird numbers in the bankdata row in the user table. I am assuming you are also using $bankdata as the variable for how much money is in the bank for the user.

3. You are aware that the database is showing more than 2 numbers after the decimal in the bank / money on hand.

4. For this, I will use A & B's. Assume those 2 are 2 different people. A has $50 on hand. If A tries to steal $100 from B, and FAILS. He will lose that amount of money, and his money on hand becomes a negative number and A will be denied access to the bank. However, A does have money in the bank, he should be able to go into the bank anyway.

HoC

1. It'd be a simple change to everywhere $points is defined, but the code below just makes a new variable - $bankmoney. $points shouldn't include what is in the bank, otherwise it'll cause weirdness all over the store. Feel free to store $points + $bankmoney in a new variable though.
PHP Code:

$bankdata unserialize($bbuserinfo['uttstore_bankdata']);
$bankmoney $bankdata['amount']; 

2. The above code should answer your question. uttstore_bankdata is a serialized array.

3. Yes, I am away of that. Not a bug in itself, but it can cause some. I'll probably round it off in future releases.

4. That shouldn't happen, as it should prevent users to steal more money then they have. But I am making 0 just mean to not check to see if they have enough money at all in the next release anyways, just incase someone does go into negatives (although they shouldn't, I've seen it happen).

House_of_Crazed 06-27-2004 05:58 PM

Quote:

Originally Posted by Link14716
You are not being ignored on purpose. And I checked in the admincp and you are marked as Licensed.

Oh, that's odd. Well, when I verified myself, I gave myself like 2 or 3 hours to give you guys time for whatever verification system you used, lol, to verify me. And I still could not post a thread or reply. *shrugs*

And reason why I said being ignored on purpose is because I posted this like a few days ago and I've seen you guys reply to other posts. *shrugs* I just don't like being ignored :) Don't take offense

Quote:

1. It'd be a simple change to everywhere $points is defined, but the code below just makes a new variable - $bankmoney. $points shouldn't include what is in the bank, otherwise it'll cause weirdness all over the store. Feel free to store $points + $bankmoney in a new variable though.
PHP Code:

$bankdata unserialize($bbuserinfo['uttstore_bankdata']);
$bankmoney $bankdata['amount']; 

2. The above code should answer your question. uttstore_bankdata is a serialized array.
Yea, it does, I'll give this a try.

Quote:

3. Yes, I am away of that. Not a bug in itself, but it can cause some. I'll probably round it off in future releases.
Excellent :) I'm asking because my users came to me complaining that they cannot deposit all their money (i.e., 140.30), it would tell them that they do not have enough money.

Quote:

4. That shouldn't happen, as it should prevent users to steal more money then they have. But I am making 0 just mean to not check to see if they have enough money at all in the next release anyways, just incase someone does go into negatives (although they shouldn't, I've seen it happen).
Yea, I've been sitting here trying to figure out the code, but I'll let you do it, LOL since you are more inimiate with the shop code, not I.

Thanks! :)

HoC

Zachery 06-27-2004 06:23 PM

Quote:

Originally Posted by House_of_Crazed
Oh, that's odd. Well, when I verified myself, I gave myself like 2 or 3 hours to give you guys time for whatever verification system you used, lol, to verify me. And I still could not post a thread or reply. *shrugs*

And reason why I said being ignored on purpose is because I posted this like a few days ago and I've seen you guys reply to other posts. *shrugs* I just don't like being ignored :) Don't take offense



Yea, it does, I'll give this a try.



Excellent :) I'm asking because my users came to me complaining that they cannot deposit all their money (i.e., 140.30), it would tell them that they do not have enough money.



Yea, I've been sitting here trying to figure out the code, but I'll let you do it, LOL since you are more inimiate with the shop code, not I.

Thanks! :)

HoC

Are you still having the problems? we both checked and my test licensed user is not having any problems.

If you have the time could you drop me a pm if your still having troubles

hichew 06-27-2004 06:53 PM

can i see the working hack on someone forums ?

b4ne 06-27-2004 07:05 PM

Just to let ya know works all fine, I was lucky and had a virgin forum so I just reinstalled forum completly and made a new install of the hack.

Its fecking sweeeet :)

Thanks to all of you who made this hack working

Zachery 06-27-2004 07:32 PM

Quote:

Originally Posted by hichew
can i see the working hack on someone forums ?

I dont think we have any offical demo sites.

However,
I wanted to announce toe veryone that the license system is now completly working :D i fixed that one little bug :d

Cold Steel 06-29-2004 01:28 AM

/me installs.

Awesome - thanks!

For anyone who's wondering, Lesane's Storehack used "storep" as the table for points.

y2krazy 06-29-2004 01:44 AM

Quote:

Originally Posted by Zachery
I dont think we have any offical demo sites.

However,
I wanted to announce toe veryone that the license system is now completly working :D i fixed that one little bug :d

Well, if you'd like a "demo", without the "demo", you can check out my forums:

http://forums.wickedart.org/

Also, what is this licensing that you speak of?

:confused:

-y2k-

Cold Steel 06-29-2004 02:01 AM

In my postbit, $points doesn't show anything.

I used the standalone installer on 3.0.1.

I'm using the storep table from Lesane's storehack, if that makes a difference.

Zachery 06-29-2004 02:04 AM

Quote:

Originally Posted by Cold Steel
In my postbit, $points doesn't show anything.

I used the standalone installer on 3.0.1.

I'm using the storep table from Lesane's storehack, if that makes a difference.

It shouldnt, did you do the edits to functions showthread and showthread (if there are any)


All times are GMT. The time now is 12:47 AM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.03438 seconds
  • Memory Usage 1,886KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (5)bbcode_code_printable
  • (7)bbcode_php_printable
  • (26)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (2)pagenav_pagelinkrel
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (40)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete