| | |
how can I track "post" varaible thru 3-rd party shopping-cart
Please support our PHP advertiser: PostgreSQL or MySQL? Compare and contrast the two most popular open source databases
![]() |
•
•
Join Date: Mar 2007
Posts: 63
Reputation:
Solved Threads: 0
Hello,
was wandering if anybody out there can help me with the following:
We use a third-party shopping cart, but they dont really make it easy to be able to buy "memberships". The way we have it now, is that they buy a "membership-card" (say item code: CLUBMEMBER", which when they buy it along with other products, it automatically discounts all items by 25%... it all works pretty good. EXCEPT that we want to, at the final confirmation page, to automatically show ONLY the people that bought this membership-card "item", a registration form. So my question is: how can I track this "CLUBMEMBER" POST variable along all checkout pages, so that if AND ONLY IF customer does buy it, it will then show "registration" form.
I thought about setting a SESSION like "if POST-variable item_code exists and item_code=MEMBERCLUB" then set SESSION "CLUB", and then on confirmation page add something like "if CLUB session is set, then show registration form"...
but then I realized that woudlnt work just right, cause if customer decides to delete that CLUBMEMBER item, but leaves other products in cart, then registration form would still show up, even though customer took it off cart...
Anyways, not sure if I am making sense. In the end, I am just trying to get around their whole cumbersome ways, and simply make my own script...
Any help much appreciated!
Adrian
was wandering if anybody out there can help me with the following:
We use a third-party shopping cart, but they dont really make it easy to be able to buy "memberships". The way we have it now, is that they buy a "membership-card" (say item code: CLUBMEMBER", which when they buy it along with other products, it automatically discounts all items by 25%... it all works pretty good. EXCEPT that we want to, at the final confirmation page, to automatically show ONLY the people that bought this membership-card "item", a registration form. So my question is: how can I track this "CLUBMEMBER" POST variable along all checkout pages, so that if AND ONLY IF customer does buy it, it will then show "registration" form.
I thought about setting a SESSION like "if POST-variable item_code exists and item_code=MEMBERCLUB" then set SESSION "CLUB", and then on confirmation page add something like "if CLUB session is set, then show registration form"...
but then I realized that woudlnt work just right, cause if customer decides to delete that CLUBMEMBER item, but leaves other products in cart, then registration form would still show up, even though customer took it off cart...
Anyways, not sure if I am making sense. In the end, I am just trying to get around their whole cumbersome ways, and simply make my own script...
Any help much appreciated!
Adrian
How much freedom do you have with this 3rd party shopping cart, cause I think that there is only one way of really knowing if the product was purchased and that is by querying the database after the purchase is made, which I think would need to be done on the thank you page.
Last edited by R0bb0b; Jun 20th, 2008 at 4:14 pm.
•
•
Join Date: Mar 2007
Posts: 63
Reputation:
Solved Threads: 0
Yeah, I figured on the confirmation page is where I would be able to "pull" or read the variable to test if exists... but the "tech-support" said there are no "variables" at that point... of course they are saying that they could "custom" develop the workings for me, but they would charge a pretty chunk of money to do it...
But there must be "something" in browser memory, cause a confirmation email is sent to customer after buying, and all corresponding info is sent in that email content, including item details.
Somebody mentioned I could just "unset" the session if item is removed from cart, which makes sense... I just need to figure out how to have script know that said item WAS removed...
But there must be "something" in browser memory, cause a confirmation email is sent to customer after buying, and all corresponding info is sent in that email content, including item details.
Somebody mentioned I could just "unset" the session if item is removed from cart, which makes sense... I just need to figure out how to have script know that said item WAS removed...
•
•
Join Date: Mar 2007
Posts: 63
Reputation:
Solved Threads: 0
I forgot to mention that I do have access to the "confirmation" page template; i can put php code there, but it just has basic html code, with other "cart" codes that get pulled but which I cant see or dont have access to. Perhaps I need to study that template again and can figure out some of this proprietary codes...
Last edited by websurfer; Jun 21st, 2008 at 12:38 am.
•
•
Join Date: Jun 2008
Posts: 8
Reputation:
Solved Threads: 0
can you specify the cart you use?
is the php encrypted?
is it on your server? (do you have access to the database it uses? )
if you have access to database then you just need to figure out where and how it stores details and just use that,
if its not encrypted, even if you do not have permission to change it you could go through the code to see what it does and have better idea.
is the php encrypted?
is it on your server? (do you have access to the database it uses? )
if you have access to database then you just need to figure out where and how it stores details and just use that,
if its not encrypted, even if you do not have permission to change it you could go through the code to see what it does and have better idea.
![]() |
Other Threads in the PHP Forum
- Previous Thread: Uploading with PHP error
- Next Thread: how to create a website builder
| Thread Tools | Search this Thread |
.htaccess ajax apache api array back basic beginner binary broken cakephp checkbox class cms code computing cron curl customizableitems database date delete display dynamic echo email error file files filter folder form forms function functions gc_maxlifetime google host href htaccess html image include insert integration ip java javascript joomla limit link login loop mail memmory memory menu mlm mod_rewrite multiple mysql navigation oop parsing paypal pdf php problem query radio random recursion regex remote script search server sessions sms snippet soap source space sql syntax system table thesishelp trouble tutorial update upload url validation validator variable video web xml youtube





