mardi 14 juin 2016

Load php script without refreshing a page using ajax


so I am currently making my own php basket. When Add to Cart link is pressed I would like a php script (separate file) to run. Each product is added to the cart using setcookie so this file will create new cookies..

The basket will be on the page and will echo the cookies in a loop until all products have been echo'ed.

I understand I need to use AJAX, I have tried but I just cannot get anything to work.

If someone could write me some code to point me in the right direction that would be amazing!!!! (Please write it out in full as I am very new to code)


Aucun commentaire:

Enregistrer un commentaire