Problem with using ajax on frontend
-
Hi,
the Codex describes ajax-handling on this page: https://codex.www.ads-software.com/AJAX_in_Plugins
I succeeded in using ajax in the backend but I have problems with using ajax in the frontend. The article describes that the “ajaxurl” javascript global does not get automatically defined in the frontend, so I have to to it. But how to do that?
The description of the codex-article is not very detailed there. The cited blog post “5 tips for using AJAX in WordPress” does not help me because it is very difficult to unterstand.
To get precise, all i want to do is the following: when the user klicks on a button in the frontend, get some html depending on form entries and database response and get this html shown dynamically with js.
I would appreciate some help here and would love to enlarge the codex-article in return.
Thanks
- The topic ‘Problem with using ajax on frontend’ is closed to new replies.