8

I'm getting this strange issue. Everything was working fine last day. Now suddenly none of my ajax requests work. The problem is (i found that in firebug console):

failed to load resource : ....../wp-admin/admin-ajax.php

So somehow the request to the admin-ajax.php file isn't successful. I have cross checked these things:

  1. the url to admin-ajax.php is correct and no issues there

  2. its not just 'my own scripts' which doesn't work, i've buddypress installed and all ajax requests from buddypress also give the same error

  3. i directly typed in the url of admin-ajax.php into browser and instead of getting 0 (the expected output), google chrome says 'no data received'.

Is it some configuration on server end?? If yes then what do i say to the hosting support guys?

BTW, if it matters, the site is hosted on wpengine..

Any help is really appreciated

UPDATE : the browser dev tools screenshot : enter image description here

  • What does your error log say, and what error code is being returned? It's likely a 500 error not a 404 – Tom J Nowell Jul 12 '13 at 10:04
  • The hosting control panel interface at wpengine is different than cPanel, so i can't be sure, but when i go to the error logs, it says 'error log is empty'. No error code is returned, google chrome dev tools console says 'failed to load resource .... ' .And yes you are right, most likely it wont be a 404 issue, removed that tag. – webdwall Jul 12 '13 at 10:18
  • Open your browser’s dev tools, then the Network tab and look at the HTTP response headers. What exactly do you get there? – fuxia Jul 12 '13 at 10:24
  • Well, it simply says '(failed)', i've added the screenshot in the question, the image appears too small here, you will have to right click, copy image url and open that url to actually read the text in image. Sorry for the trouble, i dont know if there's a better way to attach images here.. – webdwall Jul 12 '13 at 10:34
  • UPDATE: any ajax requests wont work, not even the ones in wp-admin. e.g: adding a widget doesn't work !!! Trying to uninstall plugins one-by-one and check... – webdwall Jul 12 '13 at 12:25
5

Yes finally the problem was that the hosting provider had blocked the admin-ajax.php file saying that this file was receiving too many request, and requests to this file bypasses cache , hence it was causing problems on server :)

So now i'll have to 'convince' them to turn it back on.

Thank you all for helping..

protected by Community Oct 15 '18 at 14:04

Thank you for your interest in this question. Because it has attracted low-quality or spam answers that had to be removed, posting an answer now requires 10 reputation on this site (the association bonus does not count).

Would you like to answer one of these unanswered questions instead?

Not the answer you're looking for? Browse other questions tagged or ask your own question.