B
B
bochkarev2015-04-03 23:25:57
PHP
bochkarev, 2015-04-03 23:25:57

file_get_contents Nginx error?

Hello!
When running the PDF print component in Cms MODX Revolution, I get an error:

[2015-04-04 01:56:07] (ERROR @ /var/www/clients/client1/web23/web/core/components/save2page/model/save2page/process.class.php : 209) PHP warning: file_get_contents(http://ainmoservices.es//assets/components/minifyx/cache/styles_e1e6fe204f.min.css): failed to open stream: HTTP request failed! HTTP/1.1 404 Not Found

[2015-04-04 01:56:07] (ERROR @ /var/www/clients/client1/web23/web/core/components/save2page/model/save2page/process.class.php : 209) PHP warning: file_get_contents(http://ainmoservices.es//assets/components/ajaxform/css/default.css): failed to open stream: HTTP request failed! HTTP/1.1 404 Not Found

[2015-04-04 01:56:07] (ERROR @ /var/www/clients/client1/web23/web/core/components/save2page/model/save2page/process.class.php : 78) PHP warning: file_get_contents(http://ainmoservices.es//assets/components/save2page/css/default.css): failed to open stream: HTTP request failed! HTTP/1.1 404 Not Found

For check:
<?php
echo file_get_contents('http://ainmoservices.es/assets/components/minishop2/css/web/default.css');

I get:
[2015-04-04 02:24:12] (ERROR @ /var/www/clients/client1/web23/web/core/components/console/processors/exec.class.php(21) : eval()'d code : 2)
PHP warning: file_get_contents(http://ainmoservices.es/assets/components/minishop2/css/web/default.css): failed to open stream: HTTP request failed! HTTP/1.1 404 Not Found

I do the same check from another site/server. All OK.
What could be wrong. Installed ISPConfig + Nginx + php-fpm.
Thanks in advance!

Answer the question

In order to leave comments, you need to log in

2 answer(s)
I
IceJOKER, 2015-04-03
@IceJOKER

stackoverflow.com/questions/697472/why-file-get-co...

N
Nazar Mokrinsky, 2015-04-04
@nazarpc

Maybe you have URL wrappers disabled?
It may well be on hosting, then ask the administrator, try cURL, if available, try directly through sockets.
You can check at runtime like this:
ini_get('allow_url_fopen')

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question