RE: [PHP] loading classes and efficiency
| From: | daniel at electroteque dot org | Date: | Fri, 12 Sep 2003 00:06:10 +0000 |
| Subject: | RE: [PHP] loading classes and efficiency | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-162350@lists.php.net to get a copy of this message | ||
thats how i saw it includes it once so it prevents say functions being
reincluded
> Dan Anderson <mailto:dan@mathjunkies.com>
> on Wednesday, September 10, 2003 5:44 PM said:
>
>> require_once() or include_once()
>>
>> The files containing the class files before you need them. They will
>> only be loaded when needed that way.
>
> Not true. www.php.net/require_once
>
> The way I understand it (maybe you know something I don't?)
> require/include_once only prevent an included file from being included
> MORE than one time, hence the character string _once tacked onto the
> end of include() and require().
>
> It does NOT however include a file only when it's needed, it merely
> includes it once.
>
>
> Please correct me if I'm wrong.
>
> Chris.
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php