note 22524 added to function.require-once

From: Date: Thu, 20 Jun 2002 21:43:16 +0000
Subject: note 22524 added to function.require-once
Groups: php.notes 
Request: Send a blank email to php-notes+get-32062@lists.php.net to get a copy of this message
require_once seems to check whether the file is to included by the string that you pass to the function, as opposed to the absolute path of the file. Thus, for example if you have a file at: /home/a.php And executed the following statements from a file in /home/ : require_once("a.php"); require_once("/home/a.php"); a.php would be included twice in that file, potentially causing problems in your code that depend on the file being only included once. -- http://www.php.net/manual/en/function.require-once.php http://master.php.net/manage/user-notes.php?action=edit+22524 http://master.php.net/manage/user-notes.php?action=delete+22524 http://master.php.net/manage/user-notes.php?action=reject+22524

« previous php.notes (#32062) next »