[PHP] how include works?

2006-05-23 Thread Mindaugas L
Hi can anybody explain how require works, and what's the difference between _once and regular? What's going on when php file is processed? In manual is written just, that it's readed once if include_once. What does to mean "readed"? Thank You -- Mindaugas

Re: [PHP] how include works?

2006-05-29 Thread Richard Lynch
On Tue, May 23, 2006 6:19 pm, Mindaugas L wrote: > can anybody explain how require works, and what's the difference > between > _once and regular? What's going on when php file is processed? In > manual is > written just, that it's readed once if include_once. What does to mean > "readed"? Thank Yo

RE: [PHP] how include works?

2006-05-30 Thread Arno Kuhl
-Original Message- From: Richard Lynch [mailto:[EMAIL PROTECTED] Sent: 30 May 2006 06:11 To: Mindaugas L Cc: php-general@lists.php.net Subject: Re: [PHP] how include works? On Tue, May 23, 2006 6:19 pm, Mindaugas L wrote: > can anybody explain how require works, and what's the di

RE: [PHP] how include works?

2006-05-30 Thread Peter Lauri
Arno wrote: I understand the difference well enough, but I've never really understood the reason for having both. Is it to help find errors in sloppy coding, or is there a case where including a file more than once is desirable (and won't cause an error)? Arno -- There

Re: [PHP] how include works?

2006-05-30 Thread chris smith
On 5/30/06, Arno Kuhl <[EMAIL PROTECTED]> wrote: -Original Message- From: Richard Lynch [mailto:[EMAIL PROTECTED] Sent: 30 May 2006 06:11 To: Mindaugas L Cc: php-general@lists.php.net Subject: Re: [PHP] how include works? On Tue, May 23, 2006 6:19 pm, Mindaugas L wrote: > ca

Re: [PHP] how include works?

2006-05-30 Thread Stut
Richard Lynch wrote: On Tue, May 23, 2006 6:19 pm, Mindaugas L wrote: can anybody explain how require works, and what's the difference between _once and regular? What's going on when php file is processed? In manual is written just, that it's readed once if include_once. What does to mean "r

RE: [PHP] how include works?

2006-05-30 Thread Arno Kuhl
able (and > won't cause an error)? -Original Message- From: chris smith [mailto:[EMAIL PROTECTED] Sent: 30 May 2006 02:11 To: [EMAIL PROTECTED] Cc: php-general@lists.php.net Subject: Re: [PHP] how include works? There was more of a difference earlier on. On http://www.php.net/man

Re: [PHP] how include works?

2006-05-30 Thread Stut
Arno Kuhl wrote: I wasn't talking about the difference between require and include but rather the difference between require and require_once (or include and include_once). Why doesn't require just work the same way as require_once, because I can't see the need for require -ing the same file mor

Re: [PHP] how include works?

2006-05-30 Thread Stut
Arno Kuhl wrote: We really are talking across each other. If you read my post properly you would have noticed that I was asking why the include/require doesn't work like the _once by default, not why there is a _once (which is obviously the way you understood it). The application I work on has m

Re: [PHP] how include works?

2006-05-30 Thread Stut
Arno Kuhl wrote: Well I certainly don't come close to knowing all there is to know about PHP and I'm always keen to learn something new - can you show me an example of a file being included more than once, and why it's required more than once during the same request? I can obviously include stra

Re: [PHP] how include works?

2006-05-30 Thread Chris
(and won't cause an error)? -Original Message- From: chris smith [mailto:[EMAIL PROTECTED] Sent: 30 May 2006 02:11 To: [EMAIL PROTECTED] Cc: php-general@lists.php.net Subject: Re: [PHP] how include works? There was more of a difference earlier on. On http://www.php.net/manual/en/func

RE: [PHP] how include works?

2006-05-30 Thread Richard Lynch
On Tue, May 30, 2006 2:02 am, Peter Lauri wrote: > I understand the difference well enough, but I've never really > understood > the reason for having both. Is it to help find errors in sloppy > coding, or > is there a case where including a file more than once is desirable > (and > won't cause an