RE: [PHP-ES] Problemas con la funcion include()

From: Date: Thu, 13 Mar 2003 10:24:05 +0000
Subject: RE: [PHP-ES] Problemas con la funcion include()
References: 1  Groups: php.general.es 
Request: Send a blank email to general-es+get-33640@lists.php.net to get a copy of this message
Por lo que veo la instruccion include si te esta funcionando correctamente, el problema lo tienes al cargar el script hello.txt. Se sugiero que modifiques la extension de hello.txt a hello.php Espero que te sirva de algo... -----Mensaje original----- De: Andres Rubio [mailto:andesrubio@infoartnet.com] Enviado el: jueves, 13 de marzo de 2003 3:29 Para: lista@phpes.com Asunto: [PHP-ES] Problemas con la funcion include() Hola Listeros, Estoy cambiando de servidor (Caracteristicas del nuevo PHP Version 4.3.1 http://cpanel.vortechhosting.com/phpinfo.php) y al pasar el codigo que esta funcionando al nuevo encuentro que la funcion include() no funciona con un URL, Si funciona con direcciones relativas --locales--) Tengo este codigo: *************** index.php **** <html> <head> <title></title> </head> <body bgcolor="#FFFFFF"> <? include('http://cpanel.nocspeed.com/~expograf/hello.txt'); ?> </body> </html> *********************** ****************** hello.txt: ********* <? print('HELLO'); ?> *********************** Al ejecutarlo en (http://cpanel.nocspeed.com/~expograf/ ) saca este error: ********* Warning: main(http://cpanel.nocspeed.com/~expograf/hello.txt) [function.main]: failed to create stream: HTTP request failed!  in /usr/home/expograf/public_html/index.php on line 9 Warning: main() [function.main]: Failed opening 'http://cpanel.nocspeed.com/~expograf/hello.txt' for inclusion (include_path='') in /usr/home/expograf/public_html/index.php on line 9 ************** Alguna Idea de que puede estar pasando?? Muchas gracias por la ayuda. Andrés Rubio

« previous php.general.es (#33640) next »