Click here to Skip to main content
15,905,875 members
Please Sign up or sign in to vote.
1.00/5 (2 votes)
See more:
My problem is complex please reads carefully
i am using the online shopping cards Suppose i select the one product with $100 price .i put this values in session.but same time admin change the price $100 to $90.But i have $100 in session.but the price in $90.But i pass the session values ($100) to paypal. NA d the transaction is wrong because the price is 90.how it problems remove
Please help me
Thanks
Posted

Don't store the price in the session - store a product count and a product ID instead. Then when you get to a total page, calculate the price there.

It may be worth your storing both an ID and a price and comparing the two in the totals page. Certainly in the UK it is a criminal offence to charge more than the advertised price for an item, (and there are rules about which way and when you can raise / reduce prices). I have no idea if this kind of legislation affects you, but if I got to a totals page and was greeted by a message saying "Great news! While you were shopping, we have dropped the price of xxx from $100 to $90" I'd be a happy bunny, and I'd be more likely to come back.
 
Share this answer
 
Comments
bbirajdar 5-Jun-12 6:29am    
I agree +5
joti parkash 5-Jun-12 6:32am    
Thanks reply me but i am not satisfied with answer suppose admin will change the price when user on paypal.Then what will happen
OriginalGriff 5-Jun-12 6:40am    
Once you get to the totals page, it is the final chance for changes. You present him with the current prices, and a total to pay, and when he commits, that is that - you can't change the price up or down from that point, without either stealing from him by taking more money than he agreed to, or doing a later refund if he notices and asks. Up to that point, prices are flexible and subject to change (but it is a good idea to let him know so he can change his mind if you are going to put the price up).

Some companies do this by removing unsold items from stock for an hour or two, raising the price, and then re-allocating the stock, to ensure that no-one is expecting to pay $100 and suddenly find it is $200 - that can make a customer never trust or visit your site again.
suppose admin will change the price when user on paypal.Then what will happen
Nothing! Just post/quote that the total is based on the price at the time of adding the item to your cart.

Neither you can stop admin to change the price nor the customer to stop shopping at the time of upgrade. If you try any of these two, it would be a bad experience overall for both admin and user. So, best is to quote total based on the price at the time of adding the item to cart. This would resolve your issue and it would be customers luck if they miss out such a close call.
 
Share this answer
 
v2

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900