Page 1 of 1

Failed to include ?

Posted: Sun Mar 12, 2006 3:37 pm
by GeXus
I received this error when trying to include a file


Warning: Failed opening 'http://localhost/dvd/home.php' for inclusion (include_path='.;c:\apache\php\pear') in c:\apache\htdocs\dvd\file.php on line 1

Any idea what it would do this? What is pear?

Thanks!

Posted: Sun Mar 12, 2006 4:01 pm
by Burrito
it means it can't find the file. You'll need to use the physical path anyway, not the virtual one.

the mention of pear was only because that is part of your includes path in php.ini.

Posted: Sun Mar 12, 2006 4:40 pm
by nickman013
If you want me to convert that to baby language so its easy for you to understand here you go.

A BAD include:

Code: Select all

include("Location:/images/pictures.html");
A GOOD include:

Code: Select all

include("Location:/path/from/root/public_html/images/pictures.html");

Posted: Sun Mar 12, 2006 8:24 pm
by feyd
"Location:" will, I'd bet, make it fail. ;)