Re: [PHP] Using variables from includes

2003-06-25 Thread Chris Shiflett
> > include ("http://www.site.com/home.php";); > > } > > else{ > > include ("http://www.site.com/"; . "$page" . ".php"); > > } > > ?> > > This code is in the index.php file. When home.php is included, I > > want to echo a variable like $title on the index.php page. But > > $title is defined on hom

Re: [PHP] Using variables from includes

2003-06-25 Thread chris sherwood
use globals to pass the information to other pages.. http://www.php.net/manual/en/language.variables.php "Ben" <[EMAIL PROTECTED]> wrote in message news:<[EMAIL PROTECTED]>... > Ok, I'm sort of a beginner at this, so cut me some slack. :-) Ok, I have an > if then statement that after you click a

Re: [PHP] Using variables from includes

2003-06-24 Thread Leif K-Brooks
Ben wrote: But how would I go about using the IF THEN statement but allowing the page to see the variables. Not sure if I know what you mean, but: if($foo == 'bar'){ include('foo.php'); } -- The above message is encrypted with double rot13 encoding. Any unauthorized attempt to decrypt it will

Re: [PHP] Using variables from includes

2003-06-24 Thread Ben
But how would I go about using the IF THEN statement but allowing the page to see the variables. "Leif K-Brooks" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Ben wrote: > > >How would I do this then? > > > > include('foo.php'); > > -- > The above message is encrypted with double

Re: [PHP] Using variables from includes

2003-06-24 Thread Ben
thanks a bunch "Leif K-Brooks" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Ben wrote: > > >How would I do this then? > > > > include('foo.php'); > > -- > The above message is encrypted with double rot13 encoding. Any unauthorized attempt to decrypt it will be prosecuted to the

Re: [PHP] Using variables from includes

2003-06-24 Thread Leif K-Brooks
Ben wrote: How would I do this then? include('foo.php'); -- The above message is encrypted with double rot13 encoding. Any unauthorized attempt to decrypt it will be prosecuted to the full extent of the law. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.

Re: [PHP] Using variables from includes

2003-06-24 Thread Ben
How would I do this then? "Leif K-Brooks" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Ben wrote: > > >Ok, I'm sort of a beginner at this, so cut me some slack. :-) Ok, I have an > >if then statement that after you click a link it looks like this: > >blah?page=pagename It looks s

Re: [PHP] Using variables from includes

2003-06-24 Thread Leif K-Brooks
Ben wrote: Ok, I'm sort of a beginner at this, so cut me some slack. :-) Ok, I have an if then statement that after you click a link it looks like this: blah?page=pagename It looks something like this: http://www.site.com/home.php";); } else{ include ("http://www.site.com/"; . "$page" . ".php");

[PHP] Using variables from includes

2003-06-24 Thread Ben
Ok, I'm sort of a beginner at this, so cut me some slack. :-) Ok, I have an if then statement that after you click a link it looks like this: blah?page=pagename It looks something like this: http://www.site.com/home.php";); } else{ include ("http://www.site.com/"; . "$page" . ".php"); } ?> This co

RE: [PHP] using variables in a function within a fuction

2002-06-25 Thread John Holmes
> function test1() > {$hello="hello";} > > function test2() > {test1(); > print $hello;} > > test2(); > > ?> > This should print hello. But it does'nt work. Any idea? Read here to find out why: http://www.php.net/manual/en/language.variables.scope.php ---John Holmes... -- PHP General Mai

Re: [PHP] using variables in a function within a fuction

2002-06-24 Thread Michael P. Carel
OTECTED]] > Sent: Tuesday, June 25, 2002 3:14 PM > To: php > Subject: [PHP] using variables in a function within a fuction > > > Hi to all, > Have problem with this. Im want to use a variable in a function into another > function. such as: > > function test1() > {$hello=&q

RE: [PHP] using variables in a function within a fuction

2002-06-24 Thread Martin Towell
or make it (argh) global -Original Message- From: Michael P. Carel [mailto:[EMAIL PROTECTED]] Sent: Tuesday, June 25, 2002 3:14 PM To: php Subject: [PHP] using variables in a function within a fuction Hi to all, Have problem with this. Im want to use a variable in a function into

[PHP] using variables in a function within a fuction

2002-06-24 Thread Michael P. Carel
Hi to all, Have problem with this. Im want to use a variable in a function into another function. such as: This should print hello. But it does'nt work. Any idea? Regards mike -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

RE: [PHP] using variables

2001-12-16 Thread Gerard Onorato
David, Your code should read: -Original Message- From: David Killingsworth [mailto:[EMAIL PROTECTED]] Sent: Sunday, December 16, 2001 2:39 AM To: [EMAIL PROTECTED] Subject: [PHP] using variables I'm trying to determing why this won't work. I wish to assign graphics to

Re: [PHP] using variables

2001-12-16 Thread Tom Rogers
Hi you need: or Tom At 05:39 PM 16/12/01, David Killingsworth wrote: >I'm trying to determing why this won't work. >I wish to assign graphics to variables then call them >within the HTML on my .php pages. >--test.php-- >$ulo = "/images/ulo.gif"; >?> > >b8126e.jpg >---end test.p

[PHP] using variables

2001-12-15 Thread David Killingsworth
I'm trying to determing why this won't work. I wish to assign graphics to variables then call them within the HTML on my .php pages. --test.php-- ---end test.php- The resulting output viewing the html source from the browser is: html output-- --