Re: [PHP] include_once changed behavior?

2004-06-07 Thread Mattias Thorslund
Jason Wong wrote: Possibly: manual > Using PHP from the command line > -c switch From the manual: "The CLI SAPI does not change the current directory to the directory of the executed script!" "Note: The CGI SAPI supports the CLI SAPI behaviour by means of the -C switch when run from the command

Re: [PHP] include_once changed behavior?

2004-06-07 Thread Jason Wong
On Tuesday 08 June 2004 04:14, Mattias Thorslund wrote: > >>What could be the difference that caused this? As Marek had pointed out the behaviour was changed ... > >Possibly: > > > > manual > Using PHP from the command line > -c switch > > ...except I don't use the -c switch? ... IIRC just af

Re: [PHP] include_once changed behavior?

2004-06-07 Thread Mattias Thorslund
Marek Kilimajer wrote: cli php uses path relative to your current directory, cgi php uses path relative to the executing script. That IS interesting. That would explain why: php /var/www/myproject/util/my-cli-script.php ... will break unless I execute it from that same directory. I used to be abl

Re: [PHP] include_once changed behavior?

2004-06-07 Thread Marek Kilimajer
Marek Kilimajer wrote: Mattias Thorslund wrote: Hi, In order to keep configuration files outside the web root I use: include_once('../config.php'); This used to work also when running php scripts from the command line. Now I have a new server and I get "no such file or directory" when using this

Re: [PHP] include_once changed behavior?

2004-06-07 Thread Marek Kilimajer
Mattias Thorslund wrote: Hi, In order to keep configuration files outside the web root I use: include_once('../config.php'); This used to work also when running php scripts from the command line. Now I have a new server and I get "no such file or directory" when using this construct from the comm

Re: [PHP] include_once changed behavior?

2004-06-07 Thread Mattias Thorslund
Jason Wong wrote: On Tuesday 08 June 2004 03:21, Mattias Thorslund wrote: In order to keep configuration files outside the web root I use: include_once('../config.php'); This used to work also when running php scripts from the command line. Now I have a new server and I get "no such file or dir

Re: [PHP] include_once changed behavior?

2004-06-07 Thread Jason Wong
On Tuesday 08 June 2004 03:21, Mattias Thorslund wrote: > In order to keep configuration files outside the web root I use: > > include_once('../config.php'); > > This used to work also when running php scripts from the command line. > Now I have a new server and I get "no such file or directory" w

Re: [PHP] include_once() isnt!

2004-02-07 Thread Adam Bregenzer
On Tue, 2004-02-03 at 17:04, Rob wrote: > Ive programmed with C/C++ for years and have recently started to dabble in > PHP. Ive written a multi-part script for a friend and Ive run into a > problem. > Heres where the problem lies. Each component is in a separate file, and when > I run the script,

Re: [PHP] include_once("blah"); vs $blah="blah"; include($blah);

2002-06-11 Thread Jim lucas
blah... Jim Lucas - Original Message - From: "Martin Towell" <[EMAIL PROTECTED]> To: "'Henry'" <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]> Sent: Tuesday, June 11, 2002 4:31 PM Subject: RE: [PHP] include_once("blah"); vs $blah=&qu

RE: [PHP] include_once("blah"); vs $blah="blah"; include($blah);

2002-06-11 Thread Martin Towell
02 11:11 PM To: [EMAIL PROTECTED] Subject: Re: [PHP] include_once("blah"); vs $blah="blah"; include($blah); I did as you suggest with an interesting result: include_once "blah.php"; worked var $blah="blah.php"; include_once $blah; gave the following erro

RE: [PHP] include_once("blah"); vs $blah="blah"; include($blah);

2002-06-11 Thread Jonathan Rosenberg
comment. > -Original Message- > From: Henry [mailto:[EMAIL PROTECTED]] > Sent: Tuesday, June 11, 2002 9:45 AM > To: [EMAIL PROTECTED] > Subject: Re: [PHP] include_once("blah"); vs $blah="blah"; > include($blah); > > > No, the line number is

Re: [PHP] include_once("blah"); vs $blah="blah"; include($blah);

2002-06-11 Thread Henry
file you are including? > > > -Original Message- > > From: Henry [mailto:[EMAIL PROTECTED]] > > Sent: Tuesday, June 11, 2002 9:11 AM > > To: [EMAIL PROTECTED] > > Subject: Re: [PHP] include_once("blah"); vs $blah="blah"; > > include($b

RE: [PHP] include_once("blah"); vs $blah="blah"; include($blah);

2002-06-11 Thread Jonathan Rosenberg
IL PROTECTED] > Subject: Re: [PHP] include_once("blah"); vs $blah="blah"; > include($blah); > > > I did as you suggest with an interesting result: > > include_once "blah.php"; > > worked > > var $blah="blah.php"; > include_once $bla

Re: [PHP] include_once("blah"); vs $blah="blah"; include($blah);

2002-06-11 Thread Henry
I did as you suggest with an interesting result: include_once "blah.php"; worked var $blah="blah.php"; include_once $blah; gave the following error: Parse error: parse error in on line Where the is the file that was doing the include! Previously include_once($blah) just messed up the

RE: [PHP] include_once("blah"); vs $blah="blah"; include($blah);

2002-06-11 Thread Jonathan Rosenberg
Out of curiosity, try & see if it behaves differently (i.e., no parens around the include file name). > -Original Message- > From: Henry [mailto:[EMAIL PROTECTED]] > Sent: Tuesday, June 11, 2002 8:15 AM > To: [EMAIL PROTECTED] > Subject: [PHP] include_once("blah"); vs $blah="bl

RE: [PHP] include_once()

2002-03-19 Thread Martin Towell
the "child" script has an error (dunno if this is a php setting or it's default behaviour???) -Original Message- From: Mauricio Cuenca [mailto:[EMAIL PROTECTED]] Sent: Wednesday, March 20, 2002 11:14 AM To: anders nawroth; [EMAIL PROTECTED] Subject: Re: [PHP] include_once() Yes,

Re: [PHP] include_once()

2002-03-19 Thread Mauricio Cuenca
nt: Tuesday, March 19, 2002 12:30 PM Subject: Re: [PHP] include_once() > Have you remembered to set up PHP's include_path to point to the area where > your scripts are located? > > Neil > > Mauricio Cuenca wrote: > > > Hello, > > > > I have a very long sc

Re: [PHP] include_once()

2002-03-19 Thread Mauricio Cuenca
Yes, I read the documentation and took close note to include the start and end tags... Thanks, __ Mauricio Cuenca - Original Message - From: "anders nawroth" <> To: "Mauricio Cuenca" ; <[EMAIL PROTECTED]> Sent: Tuesday, March 19

Re: [PHP] include_once()

2002-03-19 Thread anders nawroth
Have you put Till: <[EMAIL PROTECTED]> Skickat: den 19 mars 2002 17:43 Ämne: [PHP] include_once() > Hello, > > I have a very long script with several functions in it. I wanted to split > the script into several files, so I created two sub-scripts and one main > script. This is the code from th

Re: [PHP] include_once()

2002-03-19 Thread Neil Freeman
Have you remembered to set up PHP's include_path to point to the area where your scripts are located? Neil Mauricio Cuenca wrote: > Hello, > > I have a very long script with several functions in it. I wanted to split > the script into several files, so I created two sub-scripts and one main > s

Re: [PHP] include_once

2001-02-28 Thread Hardy Merrill
Solved - I was changing a copy of the code that the webserver was NOT looking at. "include_once" works fine. Appologies. -- Hardy Merrill Mission Critical Linux, Inc. http://www.missioncriticallinux.com Hardy Merrill [[EMAIL PROTECTED]] wrote: > Redhat 6.1 Linux > PHP 4.0.4pl1 > Apache 1.3.14