About function Include

From: Date: Wed, 31 Jan 2001 10:16:47 +0000
Subject: About function Include
Groups: php.general 
Request: Send a blank email to php-general+get-37454@lists.php.net to get a copy of this message
Hi, list, I've been using the funcion INCLUDE like this: <?include"("/header.htm");?> because file header.htm has to be included in a lot of files. I want to use "/" because file header.htm is in main directory (like E:) and there are files in very directories above E:. But when I have a file in a directory above, like E:folder1/index.html and I use the include function in the file index.html, there's next error massage: Warning: Failed opening '/header.htm' for inclusion (include_path='') in /home2/httpd/htdocs/www/index.html on line 21 . Line 21 is the line I had put include function. We don't want to use <?include("../header");?> because we have files in other directories, and like that, we had to use <?include("../header");?> in one file, <?include("../../header");?> in another one, etc.What can we do? -- ================ Éder Henrique Vieira Ribeiro Estagiário/Informática Embrapa Agropecuária Oeste Dourados - MS ================

« previous php.general (#37454) next »