Why Does WordPress not output admin-ajax.php path by default?
As you are probably aware admin-ajax.php has been around for a very long and it provides a unified file for making AJAX requests, whether they are from the back end or front end, however its responsbility is not to provide a unified way to access it’s URL as a JavaScript variable in the front end. … Read more