Problemas con la funcion include()
| From: | Andres Rubio | Date: | Thu, 13 Mar 2003 02:29:13 +0000 |
| Subject: | Problemas con la funcion include() | ||
| Groups: | php.general.es | ||
| Request: | Send a blank email to general-es+get-33628@lists.php.net to get a copy of this message | ||
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