0

I'm having a problem with one wordpress plugin which needs to access the admin-ajax.php. The tests I performed showed me that a call to this file returns a 0, which should not be the case for this plugin to work.

Is the admin-ajax-php blocked in any way on openshift? If it is, how do I unblock it?

  • What plugin are you using? – João Gonçalves Oct 22 '15 at 14:51
  • The Give plugin. I posted to their support and they pointed to this issue with admin-ajax. I also did some troubleshooting and the htaccess is OK and the other plugins aren't blocking anything. A call to the admin-ajax return me 0. is this normal? – Pedro Martins Oct 22 '15 at 14:54
  • What function call did you use? `file_get_contents()` ? If so, a 0 (or probably a `FALSE` is returned on failure (see: http://php.net/manual/en/function.file-get-contents.php) if you really need access to the file you can you the `chmod` command but this can be a security concern. – João Gonçalves Oct 22 '15 at 14:58
  • I just call it from the URL. https://domain.com/wp-admin/admin-ajax.php I'm not coding anything, just trying to use the plugin. – Pedro Martins Oct 22 '15 at 15:00
  • Openshift doesn't block any of your files, I'm not sure what is the problem here or how to help you; please try to update the question with more details and some code. – João Gonçalves Oct 22 '15 at 15:03
  • Please note that stackoverflow is for code related questions, not for questions related to any specific framework or plugin: http://stackoverflow.com/help/how-to-ask – João Gonçalves Oct 22 '15 at 15:05
  • Is there any log file I can inspect to further provide more info? – Pedro Martins Oct 22 '15 at 15:06
  • Run `rhc tail` on your app, see https://developers.openshift.com/en/managing-log-files.html – João Gonçalves Oct 22 '15 at 15:07
  • @PedroMartins, I don't think admin-ajax.php is meant to be accessed that way, if you check its code: `// Require an action parameter if ( empty( $_REQUEST['action'] ) ) die( '0' );` However, as mentioned above, server admin questions are meant to be asked elsewhere - you can try ServerFault. It may help if you post exact wording of what the Give support responded. – Jiri Fiala Oct 23 '15 at 08:44

0 Answers0