
PHP files don't work in Windows network drive
Quote:
> Is there any chance you could post the script contents, both the relavent
> part of the calling script and the entire contents of the "helloworld.php"
> file. It would be easier to debug if you did that.
Sure. Also, now I'm in front of the computer and don't have to write
error messages by heart. I have a virtual host (for testing purposes)
defined this way in httpd.conf:
<VirtualHost *>
ServerName php
DocumentRoot "\\\\servidor\\webs\\fullhardware\\www"
ErrorLog logs/fullhardware-error.log
CustomLog logs/fullhardware-access.log common
Options All Multiviews
IndexOptions FancyIndexing VersionSort FoldersFirst
</VirtualHost>
I've placed these two files in the www folder:
*** hola.html:
<html>
<head><title></title>
<meta http-equiv="Content-Type" content="text/html;
charset=iso-8859-1">
</head>
<body>
<h1>Hola</h1>
<p>Prueba de Apache+PHP en unidad de red</p>
</body>
</html>
*** hola.php:
<html>
<h1>Hola</h1>
When I load http://php/hola.html I get the expected output:
Hola
Prueba de Apache+PHP en unidad de red
When I load http://php/hola.php I get an error message:
Warning: Failed opening '//servidor/webs/Fullhardware/www/hola.php'
for inclusion (include_path='.;c:\php4\pear') in Unknown on line 0
I have no problems at all with PHP in local drives like this:
<VirtualHost *>
ServerName fullhardware
DocumentRoot "D:\DOCUMENTOS\FullHardware\www"
ErrorLog logs/fullhardware-error.log
CustomLog logs/fullhardware-access.log common
Options All Multiviews
IndexOptions FancyIndexing VersionSort FoldersFirst
</VirtualHost>
This virtual host parses PHP perfectly.