Magento – How to keep billing info saved on checkout step if page refreshed

magento-1.7onepage-checkout

I wanted to find out if anyone knows of a way to keep billing info saved in Magento Onepage Checkout billing step if the page is refreshed. The reason is probably obvious but in the scenario that a customer choose to edit their cart having reached the end it would be painful to force them to re-enter their billing info all over again…

I have enabled persistent shopping cart but it isn't saving the data after page refresh so I would be grateful if anybody knew of another way that they could share with us please.

Best Answer

You won't be able to do it natively.

But you could be clever and use web sockets (if you need 2 way comms) to continuously save the form data (just like this website does!) - or just use a vanilla Ajax call onkeyup - then save it in the PHP session, to be echo'ed out later.

Or a more straightfoward pluggable approach would be to use a library like jQuery Save as you Type

In either situation, it would save the form contents and allow them to visit another page and come back. The only thing you might have to do is retain the accordion position - but I'm not sure many customers would mind hitting "next" a couple of times if their data was already saved.

Related Topic