Jump to content

Archived

This topic is now archived and is closed to further replies.

baker_hsv

PrePaid Balances

Recommended Posts

hi, wondering if anyone can help me. I want to make a php/mysql script where each user who logs in has a pre-paid balance and once this user purchases an item it reduces this balance.
For example a user logs on to a deli site and has a prepaid balance of $30 and spends $25 the balance gets made $5. I want the balances for each user and the usernames and passwords of each user to be stored in MYSQL... any advice?

and when the balance gets to 0 a restriction so the user can't order anymore until topped up.

Thanks In Advance
:-)

Share this post


Link to post
Share on other sites
A user logs in and then you have a link for the user to credit there account using a form.

If your using paypal as the credt card handler use ipn to get a varable to update the database to insert a confirmation off credet.

Then echo out the members credit that they have.

As the user buys stuff show the user a deduation of the total from the money field.

Then if the user credit gets to 0 echo a message your credit is o please credit your account.

good luck.

Share this post


Link to post
Share on other sites
[!--quoteo(post=358001:date=Mar 24 2006, 06:43 PM:name=redarrow)--][div class=\'quotetop\']QUOTE(redarrow @ Mar 24 2006, 06:43 PM) [snapback]358001[/snapback][/div][div class=\'quotemain\'][!--quotec--]
A user logs in and then you have a link for the user to credit there account using a form.

If your using paypal as the credt card handler use ipn to get a varable to update the database to insert a confirmation off credet.

Then echo out the members credit that they have.

As the user buys stuff show the user a deduation of the total from the money field.

Then if the user credit gets to 0 echo a message your credit is o please credit your account.

good luck.
[/quote]

redarrow, you've almost typed his entire question out changing a few of his phrases for more complex ones.

baker_hsv youre pretty much asking in a forum designed to get specific tips how to construct an entire project. i'd suggest trying your best to implement what you can and coming back when you're stuck.
if you're really serious about doing it yourself, then have a look here first:

[a href=\"http://www.phpfreaks.com/tutorials/135/0.php\" target=\"_blank\"]http://www.phpfreaks.com/tutorials/135/0.php[/a]

it's a spot on tutorial to break down and plan how your site will fit together.

Share this post


Link to post
Share on other sites

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.