JudgementDay Posted January 31, 2012 Share Posted January 31, 2012 I have my own shopping cart system, where I add to my cart by clicking an INPUT element inside a form, which posts a hidden INPUT value to a processing page that PHP uses to add the item the PHP session, and then I click "OK" which just JavaScript backs 1 page. I find this flow a little cheap, and wondering if its possible to use another way to add an item to a PHP session with out having to leave the page? JavaScript maybe? Can anyone suggest a solution? Unfortunately this desire exceeds my engineering knowledge. Quote Link to comment https://forums.phpfreaks.com/topic/256091-suggestion-for-a-new-way-to-engineer-my-shopping-cart/ Share on other sites More sharing options...
scootstah Posted January 31, 2012 Share Posted January 31, 2012 You can either have the form submit to the current page so that you don't actually leave (although there will still be a page re-load) or you can use AJAX to eliminate a page re-load all together. Quote Link to comment https://forums.phpfreaks.com/topic/256091-suggestion-for-a-new-way-to-engineer-my-shopping-cart/#findComment-1312850 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.