is_admin() returns true when using admin-ajax.php from front end script
Had a situation today where I was using admin-ajax.php from a front end script. As I understand it this the wp way to make ajax calls (registering my function with the wp_ajax_nopriv_myfunction hook)
Seems to me that since admin-ajax.php is on the admin side is_admin() returns true whereas my script calls it from the front end side.
This causes an issue with a plugin I use that does things differently on front and admin side of things.
So I was wondering if I was doing something wrong
is there a way to use ajax in front end the wp way and have is_admin() to return false ?
hope I could make myself understand
Leave an answer