PHP 5 Unable to Open HTTP Request Stream with fopen or fsockopen Functions PHP 5 Impossibile aprire Richiesta HTTP Stream con fopen o fsockopen Funzioni
With Apache/2.xx or Apache/2.2.x webserver, with PHP5 as the scripting module, a HTTP communication error may occur within the PHP scripts that are parsing and running via the web server. Con Apache/2.xx o Apache/2.2.x web, con PHP5 come il modulo di scripting, un errore di comunicazione HTTP possono verificarsi all'interno di script PHP che sono l'analisi e la gestione tramite il server web.
The errors that generated by PHP include: Gli errori che hanno generato dal PHP includono:
PHP Warning: fopen(http://www.example.com): failed to open stream: HTTP request failed! PHP Warning: fopen (http://www.example.com): non è riuscito ad aprire il flusso: richiesta HTTP non riuscita!
fsockopen(): unable to connect to … fsockopen (): Impossibile connettersi al ...
file_get_contents(): failed to open stream: HTTP request failed! file_get_contents (): non è riuscito ad aprire il flusso: richiesta HTTP non riuscita!
PHP Warning: main(): Failed opening ‘http://www.example.com/index.html’ for inclusion … PHP Warning: main (): Failed apertura 'http://www.example.com/index.html' per l'inclusione ...
PHP Warning: include(/usr/local/index.php): failed to open stream: No such file or directory in … PHP Warning: include (/ usr / local / index.php): non è riuscito ad aprire il flusso: No such file o la directory in ...
To resolve the problem, ensure that allow_url_fopen is enabled in PHP.INI configuration file. Per risolvere il problema, assicurarsi che allow_url_fopen è abilitato in php.ini file di configurazione. The line should look like this: La linea dovrebbe essere simile a questo:
allow_url_fopen = On Il allow_url_fopen =
Note: Depending on your system OS and configuration, the PHP.INI is located at various varied location, such as in Apache bin directory for Windows system or /usr/local/etc in FreeBSD Apache installation, if you don’t specify or point to PHP.INI in another directory. Nota: A seconda del vostro sistema OS e configurazione, php.ini si trova a vari varie località, come in Apache directory bin di sistema di Windows o / usr / local / etc in FreeBSD Apache installazione, se non si specifica o il punto di php.ini in un'altra directory.
If the error still happen and the PHP scripts still unable to connect to remote external servers and thus unable to download updates or retrieve files, check the user_agent setting in PHP.ini. Se l'errore ancora succedere e la script PHP ancora in grado di connettersi al server remoto esterno e quindi in grado di scaricare gli aggiornamenti o recuperare i file, controllare l'impostazione user_agent in php.ini.
By default php.ini set the user_agent to “PHP” which signifies that it’s the script that try to access the web server. Per impostazione predefinita impostare il php.ini user_agent a "PHP", che significa che è lo script che tentano di accedere al server web. Some web servers will refuse and don’t allow script to access and receive the date from the server. Alcuni server web si rifiutano e non consentono di script di accesso e di ricevere la data dal server. So, by setting the user_agent to that of a web browser, PHP will let the web server know which kind of web browser will receive the date, and thus able to open the HTTP connection stream. Quindi, impostando la user_agent a quella di un browser web, PHP lasciare che il server web sapere che tipo di browser web riceverà la data, e quindi in grado di aprire il flusso di connessione HTTP.
The user_agent can be set to any kind of browser strings, for example of Internet Explorer: Il user_agent può essere impostato per ogni tipo di browser stringhe, ad esempio, di Internet Explorer:
user_agent=”Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.0)” user_agent = "Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.0)"
IMPORTANT : This is a machine translated page which is provided "as is" without warranty. IMPORTANTE: Questa è una macchina tradotto pagina che è fornito "così come sono" senza garanzia. Machine translation may be difficult to understand. La traduzione automatica può essere difficile da capire. Please refer to Si prega di fare riferimento a original English article articolo originale in inglese whenever possible. ogniqualvolta ciò sia possibile.
Share and contribute or get technical support and help at Condividere e contribuire o ottenere supporto tecnico e contribuire a My Digital Life Forums La mia vita digitale forum .
Related Articles Articoli correlati
- Request URL /server-status or 404 Page Not Found Apache Error Richiesta URL / server-status o 404 Impossibile trovare la pagina di errore di Apache
- FreeBSD Apache HTTP Accept Filter Error FreeBSD HTTP Apache accettare filtro errore
- Starting Apache HTTPD Failed Due to Cannot Open or No Such mod_bwlimited, mod_log_bytes or mod_bandwidth Files A partire Apache httpd non riuscita a causa di Impossibile aprire o n. Tali mod_bwlimited, mod_log_bytes o mod_bandwidth file
- Unable to Open Hard or USB Flash Drive with Windows Script Host Cannot Find Script File autorun.vbs Error Impossibile aprire il duro o USB flash drive con Windows Script Host non può trovare file di script autorun.vbs errore
- Tweak (Increase or Change) Maximum Simultaneous HTTP and Downloads Connections to Web Server Tweak (Aumento o Cambia) Massimo simultanea HTTP e download per le connessioni Web Server
- Unable to Retrieve Channels Listing from TVants Servers Impossibile recuperare l'elenco dei canali da server TVAnts
- Aerielle Launches New i2i Stream Wireless Music-Sharing Device Aerielle lancia un nuovo i2i Stream musica senza fili dispositivo di condivisione
- cPanel Unable or Cannot Start or Restart POP3 Mail Service Impossibile cPanel o non può avviare o riavviare Servizio posta POP3
- Unable to Connect to Internet in Virtual PC with NAT Shared Networking NAT on Windows XP Guest Impossibile connettersi a Internet in Virtual PC con connessione di rete condivisa NAT NAT in Windows XP Valutazione
- New WowPen Functions As Pen And Computer Mouse Nuova WowPen funzioni come penna e il mouse del computer

































October 6th, 2008 05:33 6a ottobre, 2008 05:33
thank you, I solved my problem. la ringrazio, ho risolto il mio problema.
by default, on openbsd allow_url_fopen = off Per impostazione predefinita, su OpenBSD allow_url_fopen = off