This post was last updated on June 4th, 2021 at 04:02 pm
In the WordPress backend, there is a global
ajaxurl variable defined by WordPress itself.
Whereas for the frontend, we have to define the variable by ourselves as it is not created by WP.
The function we use is called