[PHP] variable substitution

2008-01-01 Thread jekillen
Hello again; I have two variables declared in the global scope of a script. $string_a = 'stuff $string_b and more stuff'; $string_b = ''; One is a string with a reference for substitution to the other string which is empty. In the processing body of the script are if/if else blocks. In these

Re: [PHP] variable substitution

2008-01-01 Thread Casey
On Jan 1, 2008 2:17 PM, jekillen [EMAIL PROTECTED] wrote: Hello again; I have two variables declared in the global scope of a script. $string_a = 'stuff $string_b and more stuff'; $string_b = ''; One is a string with a reference for substitution to the other string which is empty. In the

Re: [PHP] variable substitution

2008-01-01 Thread Richard Lynch
On Tue, January 1, 2008 4:17 pm, jekillen wrote: Hello again; I have two variables declared in the global scope of a script. $string_a = 'stuff $string_b and more stuff'; $string_b = ''; One is a string with a reference for substitution to the other string which is empty. In the processing

Re: [PHP] variable substitution

2008-01-01 Thread James Ausmus
On Jan 1, 2008 2:17 PM, jekillen [EMAIL PROTECTED] wrote: Hello again; I have two variables declared in the global scope of a script. $string_a = 'stuff $string_b and more stuff'; $string_b = ''; One is a string with a reference for substitution to the other string which is empty. In the

Re: [PHP] variable substitution

2008-01-01 Thread jekillen
On Jan 1, 2008, at 3:31 PM, Richard Lynch wrote: On Tue, January 1, 2008 4:17 pm, jekillen wrote: Hello again; I have two variables declared in the global scope of a script. $string_a = 'stuff $string_b and more stuff'; $string_b = ''; One is a string with a reference for substitution to the

Re: [PHP] variable substitution

2008-01-01 Thread jekillen
On Jan 1, 2008, at 3:48 PM, James Ausmus wrote: On Jan 1, 2008 2:17 PM, jekillen [EMAIL PROTECTED] wrote: Hello again; I have two variables declared in the global scope of a script. $string_a = 'stuff $string_b and more stuff'; $string_b = ''; One is a string with a reference for substitution

[PHP] variable array name

2007-11-29 Thread Mark Head
I seem to be having a problem in assigning a value to an array where the array is called dynamically. e.g. the physical name for the array is my_array, so: my_array[1] = test; works fine. $array_name = my_array; $array_name[1] = test; does not work. I have tried $$array_name[1] = test; but to

[PHP] Variable Names

2007-11-29 Thread Shaun
Hi, I seem to be having a problem in assigning a value to an array where the array is called dynamically. e.g. the physical name for the array is my_array, so: my_array[1] = test; works fine. $array_name = my_array; $array_name[1] = test; does not work. I have tried $$array_name[1] = test; but

AW: [PHP] Variable Names

2007-11-29 Thread Frank Ruske
?php $foo = my_array; $$foo = array(0 = bar); var_dump($my_array); ? array(1) { [0]= string(3) bar } Regards Frank -Ursprüngliche Nachricht- Von: Shaun [mailto:[EMAIL PROTECTED] Gesendet: Donnerstag, 29. November 2007 13:57 An: php-general@lists.php.net Betreff: [PHP] Variable Names

AW: [PHP] Variable Names

2007-11-29 Thread Frank Ruske
?php $foo = my_array; $$foo = array(0 = bar); var_dump($my_array); ? array(1) { [0]= string(3) bar } Regards Frank -Ursprüngliche Nachricht- Von: Shaun [mailto:[EMAIL PROTECTED] Gesendet: Donnerstag, 29. November 2007 13:57 An: php-general@lists.php.net Betreff: [PHP] Variable Names

Re: [PHP] variable array name

2007-11-29 Thread Daniel Brown
On Nov 29, 2007 7:47 AM, Mark Head [EMAIL PROTECTED] wrote: I seem to be having a problem in assigning a value to an array where the array is called dynamically. e.g. the physical name for the array is my_array, so: my_array[1] = test; works fine. $array_name = my_array; $array_name[1] =

Re[2]: [PHP] Variable problem?

2007-07-25 Thread Luc
Hello Richard, Wednesday, July 25, 2007, 12:05:22 AM, you wrote: I think you're just missing $contato_name = $_POST['contato_name'] in here somewhere... That was what was missing indeed :-) That said, if you are using striplashes, you have magic_quotes_gpc on, and that's something you may

[PHP] Variable problem?

2007-07-24 Thread Luc
Good afternoon list, Probably a no-brainer for the most of you but i'm in a pickle: i've set up a variable to receive in the body of the notification mail upon sending a form. The body of the mail should read like this: Obrigado por nos contatar, $contato_name. Recebemos sua mensagem

Re: [PHP] Variable problem?

2007-07-24 Thread Daniel Brown
[ For those of you who are going to get pissed for top-posting, find something better to bitch about. I'm in a rush, but trying to help. ;-P ] Luc, You're not defining $contato_name. Do this: $contato_name = $_POST['contato_name']; On 7/24/07, Luc [EMAIL PROTECTED] wrote:

Re: [PHP] Variable problem?

2007-07-24 Thread Luc
Good evening Daniel, It was foretold that on 24/7/2007 @ 17:47:46 GMT-0400 (which was 18:47:46 where I live) Daniel Brown would write: snipped a bit You're not defining $contato_name. Do this: $contato_name = $_POST['contato_name']; Yes!! Oh so simple for a

Re: [PHP] Variable problem?

2007-07-24 Thread Richard Lynch
On Tue, July 24, 2007 3:33 pm, Luc wrote: if (empty($_POST['altura'])){ $contacter_form_error[] = 'favor preencher altura'; } if (empty($_POST['largura'])){ $contacter_form_error[] = 'favor preencher largura'; } else {

Re: [PHP] Variable variables and references

2007-03-14 Thread Robert Cummings
On Wed, 2007-03-14 at 12:39 +0100, Jochem Maas wrote: Richard Lynch wrote: On Sat, March 10, 2007 6:28 am, Dave Goodchild wrote: Hi guys, I have just read 'Programming PHP' (O'Reilly) and although I think it's a great book, I am confused about variable variables and references - not

Re: [PHP] Variable variables and references

2007-03-12 Thread Richard Lynch
On Sat, March 10, 2007 6:28 am, Dave Goodchild wrote: Hi guys, I have just read 'Programming PHP' (O'Reilly) and although I think it's a great book, I am confused about variable variables and references - not the mechanics, just where you would use them. The subject of variable variables is

Re: [PHP] Variable variables and references

2007-03-11 Thread Martin Alterisio
2007/3/10, Dave Goodchild [EMAIL PROTECTED]: Hi guys, I have just read 'Programming PHP' (O'Reilly) and although I think it's a great book, I am confused about variable variables and references - not the mechanics, just where you would use them. The subject of variable variables is explained

[PHP] Variable variables and references

2007-03-10 Thread Dave Goodchild
Hi guys, I have just read 'Programming PHP' (O'Reilly) and although I think it's a great book, I am confused about variable variables and references - not the mechanics, just where you would use them. The subject of variable variables is explained but no examples are given as to why and where

Re: [PHP] Variable variables and references

2007-03-10 Thread Tijnema !
I must say, in all the years i am programming with PHP (about 5-6 years) i NEVER used references. So i don't find it useful, but well, if you want to give your variable content more than one name, you can :) I think you just need to start programming now, keeping in mind they are available, but

Re: [PHP] Variable variables and references

2007-03-10 Thread Matt Carlson
: [PHP] Variable variables and references Hi guys, I have just read 'Programming PHP' (O'Reilly) and although I think it's a great book, I am confused about variable variables and references - not the mechanics, just where you would use them. The subject of variable variables is explained

Re: [PHP] Variable variables and references

2007-03-10 Thread Tijnema !
sometimes you might (think you) need it. Tijnema - Original Message From: Dave Goodchild [EMAIL PROTECTED] To: PHP-General php-general@lists.php.net Sent: Saturday, March 10, 2007 5:28:57 AM Subject: [PHP] Variable variables and references Hi guys, I have just read 'Programming PHP

Re: [PHP] Variable variables and references

2007-03-10 Thread M.Sokolewicz
] To: PHP-General php-general@lists.php.net Sent: Saturday, March 10, 2007 5:28:57 AM Subject: [PHP] Variable variables and references Hi guys, I have just read 'Programming PHP' (O'Reilly) and although I think it's a great book, I am confused about variable variables and references

RE: [PHP] insert html into php variable

2007-02-12 Thread Edward Kay
I am using phpmailer for a rich html mailer and I have been using lines like this to build up the mailbody $mail_body .= div align=\center\img src=\http://www.myurl.org/mylogo.gif\;; Is there a build in function to assign html code to a php variable and then output them? Or can I read

RE: [PHP] insert html into php variable

2007-02-12 Thread Robert Cummings
code to a php variable and then output them? Or can I read an external php file into a variable? Have a look at the heredoc syntax for declaring strings: http://uk.php.net/manual/en/language.types.string.php#language.types.string. syntax.heredoc I find it really useful

Re: [PHP] insert html into php variable

2007-02-12 Thread clive
?php ob_start(); include( 'someFile.php' ); $content = ob_get_contents(); ob_end_clean(); ? no I think he needs file_get_contents(); -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] insert html into php variable

2007-02-12 Thread Robert Cummings
On Mon, 2007-02-12 at 14:52 +0200, clive wrote: ?php ob_start(); include( 'someFile.php' ); $content = ob_get_contents(); ob_end_clean(); ? no I think he needs file_get_contents(); While that will certainly read PHP into a variable, it won't evaluate the

RE: [PHP] insert html into php variable

2007-02-12 Thread Edward Kay
I am using phpmailer for a rich html mailer and I have been using lines like this to build up the mailbody $mail_body .= div align=\center\img src=\http://www.myurl.org/mylogo.gif\;; Is there a build in function to assign html code to a php variable and then output

Re: [PHP] insert html into php variable

2007-02-12 Thread clive
Robert Cummings wrote: On Mon, 2007-02-12 at 14:52 +0200, clive wrote: ?php ob_start(); include( 'someFile.php' ); $content = ob_get_contents(); ob_end_clean(); ? no I think he needs file_get_contents(); While that will certainly read PHP into a variable, it won't evaluate

RE: [PHP] insert html into php variable

2007-02-12 Thread Robert Cummings
to assign html code to a php variable and then output them? Or can I read an external php file into a variable? Have a look at the heredoc syntax for declaring strings: http://uk.php.net/manual/en/language.types.string.php#language.typ es.string. syntax.heredoc I

Re: [PHP] insert html into php variable

2007-02-12 Thread Robert Cummings
On Mon, 2007-02-12 at 15:20 +0200, clive wrote: Robert Cummings wrote: On Mon, 2007-02-12 at 14:52 +0200, clive wrote: ?php ob_start(); include( 'someFile.php' ); $content = ob_get_contents(); ob_end_clean(); ? no I think he needs file_get_contents();

[PHP] Re: insert html into php variable

2007-02-12 Thread Ross
Nice work Rob! You were totally correct as I needed to write the header, mail body and footer before I dumped the whole thing using OB contents. Ross -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] insert html into php variable

2007-02-12 Thread Sancar Saran
align=\center\img src=\http://www.myurl.org/mylogo.gif\;; Is there a build in function to assign html code to a php variable and then output them? Or can I read an external php file into a variable? div id=container div id=content-topthsi is some content/div div id=content-middle div id

[PHP] Variable of current function call?

2006-09-08 Thread Brent Meshier
While I'm inside a function call, is it possible to know what function is currently being called? Brent

Re: [PHP] Variable of current function call?

2006-09-08 Thread Robert Cummings
On Fri, 2006-09-08 at 14:54 -0400, Brent Meshier wrote: While I'm inside a function call, is it possible to know what function is currently being called? RTFM: http://www.php.net/manual/en/language.constants.predefined.php Cheers, Rob. --

RE: [PHP] Variable of current function call?

2006-09-08 Thread KermodeBear
While I'm inside a function call, is it possible to know what function is currently being called? Yes. http://us2.php.net/debug_backtrace -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Variable within a Variable

2006-04-09 Thread bob pilly
Hi All Im trying to store a document template in mysql that has php var names within it and then find it in the datebase and print it out with the var names replaced with the var values. e.g i have this stored Dear $title $name we would like to.. I declare the vars

Re: [PHP] Variable within a Variable

2006-04-09 Thread Chris
bob pilly wrote: Hi All Im trying to store a document template in mysql that has php var names within it and then find it in the datebase and print it out with the var names replaced with the var values. e.g i have this stored Dear $title $name we would like to.. I

Re: [PHP] Variable within a Variable

2006-04-09 Thread Paul Novitski
. This is equivalent to scripting: echo $foo; I'm using eval() to execute the echo command and interpret the PHP variable $foo. ___ eval(\$dog = \$bar;); echo dog = . $dog; RESULT: dog = cat Here I'm using eval() to set one PHP variable equal to another

[PHP] Variable variables

2006-01-24 Thread Mark Steudel
I was wondering if you could create variable variables for objects, please see examples below, Im having problems getting it to work. $data['fieldname'] = foo; // without variable variables $res = $db-query( SELECT foo FROM table ); while( $res-fetchInto( $db_data ) )

Re: [PHP] Variable $_POST vars?

2005-12-11 Thread The.Rock
Rob, I thought I had tried everything, except...the following: $item = $_POST[item$i]; //Where $i increments and loops thru my POST vars...WOHOO! This actually works. Why it works, I'll never know. but it does! Robert Cummings [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] On Sun,

Re: [PHP] Variable $_POST vars?

2005-12-11 Thread The.Rock
But when I tried your idea, it errors out with a PHP parse error. I agree with you about it being semantically the same, however it doesn't work. go figure Robert Cummings [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] On Sun, 2005-12-11 at 02:03, The.Rock wrote: Rob, I thought I

Re: [PHP] Variable $_POST vars?

2005-12-11 Thread Curt Zirzow
On Sun, Dec 11, 2005 at 12:10:22AM -0600, The.Rock wrote: Stephen, I'm using a template and so: input name=item{number} size=60 class=formdata value={item} becomes: input name=item1 size=60 class=formdata value={item} and so on. You seemed to miss the point Stephen was

[PHP] Variable $_POST vars?

2005-12-10 Thread The.Rock
Is there a way to do this? $var = $_POST[$var]; I have a form that submits data, except the name of each input field is incrementing. So I need to increment the $_POST var. Any ideas? I can't seem to get anything to work Chris -- PHP General Mailing List (http://www.php.net/) To unsubscribe,

Re: [PHP] Variable $_POST vars?

2005-12-10 Thread Stephen Johnson
On 12/10/05 9:06 PM, The.Rock [EMAIL PROTECTED] wrote: Is there a way to do this? $var = $_POST[$var]; I have a form that submits data, except the name of each input field is incrementing. So I need to increment the $_POST var. Any ideas? I can't seem to get anything to work Chris

Re: [PHP] Variable $_POST vars?

2005-12-10 Thread The.Rock
Here is an example of one of the fields: input name=item{number} size=60 class=formdata value={item} I'm looping thru this form several times, so each time the name gets incremented. Do you have an example of what your talking about? Stephen Johnson [EMAIL PROTECTED] wrote in message

Re: [PHP] Variable $_POST vars?

2005-12-10 Thread The.Rock
Here is an example of one of the fields: input name=item{number} size=60 class=formdata value={item} I'm looping thru this form several times, so each time the name gets incremented. Do you have an example of what your talking about? Stephen Johnson [EMAIL PROTECTED] wrote in message

Re: [PHP] Variable $_POST vars?

2005-12-10 Thread The.Rock
Here is an example of one of the fields: input name=item{number} size=60 class=formdata value={item} I'm looping thru this form several times, so each time the name gets incremented. Do you have an example of what your talking about? Stephen Johnson [EMAIL PROTECTED] wrote in message

Re: [PHP] Variable $_POST vars?

2005-12-10 Thread Stephen Johnson
I would do this instead input name=item[$var] size =60 class=formdata value=item Increment the $var with the {number} that you are using. In the following PHP page You would do $var = $_POST['item']; $var would then be an array accessed the same way you would access it normally. Does that

Re: [PHP] Variable $_POST vars?

2005-12-10 Thread The.Rock
Here is an example of one of the fields: input name=item{number} size=60 class=formdata value={item} I'm looping thru this form several times, so each time the name gets incremented. Do you have an example of what your talking about? Stephen Johnson [EMAIL PROTECTED] wrote in message

Re: [PHP] Variable $_POST vars?

2005-12-10 Thread Robert Cummings
On Sun, 2005-12-11 at 00:27, The.Rock wrote: Here is an example of one of the fields: input name=item{number} size=60 class=formdata value={item} I'm looping thru this form several times, so each time the name gets incremented. Do you have an example of what your talking about? ?php $i =

Re: [PHP] Variable $_POST vars?

2005-12-10 Thread The.Rock
Stephen, I'm using a template and so: input name=item{number} size=60 class=formdata value={item} becomes: input name=item1 size=60 class=formdata value={item} and so on. But when I need to get the post data, I cannot access in the way I'm used to like: $var1 = $_POST['item1'];

Re: [PHP] Variable $_POST vars?

2005-12-10 Thread The.Rock
I tried that, and every combination thereafter. All I get is the following: PHP Parse error: parse error, unexpected I tried! Robert Cummings [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] On Sun, 2005-12-11 at 00:27, The.Rock wrote: Here is an example of one of the fields: input

Re: [PHP] Variable $_POST vars?

2005-12-10 Thread Robert Cummings
On Sun, 2005-12-11 at 00:41, Robert Cummings wrote: On Sun, 2005-12-11 at 00:27, The.Rock wrote: Here is an example of one of the fields: input name=item{number} size=60 class=formdata value={item} I'm looping thru this form several times, so each time the name gets incremented. Do you

Re: [PHP] Variable $_POST vars?

2005-12-10 Thread Robert Cummings
On Sun, 2005-12-11 at 01:15, The.Rock wrote: I tried that, and every combination thereafter. All I get is the following: PHP Parse error: parse error, unexpected I tried! Hmmm, the following works for me verbatim in a shell script... make sure you don't include the opening and closing PHP

Re: [PHP] Variable $_POST vars?

2005-12-10 Thread The.Rock
Rob, I thought I had tried everything, except...the following: $item = $_POST[item$i]; //Where $i increments and loops thru my POST vars...WOHOO! This actually works. Why it works, I'll never know. but it does! Robert Cummings [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] On

Re: [PHP] Variable $_POST vars?

2005-12-10 Thread The.Rock
Rob, I thought I had tried everything, except...the following: $item = $_POST[item$i]; //Where $i increments and loops thru my POST vars...WOHOO! This actually works. Why it works, I'll never know. but it does! Robert Cummings [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] On Sun,

Re: [PHP] Variable $_POST vars?

2005-12-10 Thread The.Rock
Rob, I thought I had tried everything, except...the following: $item = $_POST[item$i]; //Where $i increments and loops thru my POST vars...WOHOO! This actually works. Why it works, I'll never know. but it does! Robert Cummings [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] On Sun,

Re: [PHP] Variable $_POST vars?

2005-12-10 Thread Robert Cummings
On Sun, 2005-12-11 at 02:03, The.Rock wrote: Rob, I thought I had tried everything, except...the following: $item = $_POST[item$i]; //Where $i increments and loops thru my POST vars...WOHOO! This actually works. Why it works, I'll never know. but it does! *lol* It's semantically the same

[PHP] variable instant value

2005-09-27 Thread FSA
Hi all, i have a question :), i need to display the instant value of a variable (think at a variable that stores the interface trafic at one moment) in browser, without having to refresh browser. I was wondering if i can do that with php (not perl, cgi, etc). If i missed something in my

Re: [PHP] variable instant value

2005-09-27 Thread Silvio Porcellana
FSA wrote: Hi all, i have a question :), i need to display the instant value of a variable (think at a variable that stores the interface trafic at one moment) in browser, without having to refresh browser. I was wondering if i can do that with php (not perl, cgi, etc). If i missed something

Re: [PHP] variable object creating

2005-06-22 Thread olivier
Hi, Try something like: $classname = MyClass; $construct_params = array(param1,param2,param3); $return =null; if(class_exists($classname)){ $param=explode( ',' , $construct_param); # You must add here some security checks eval($retrun = new $className($param)); var_dump($return); }

Re: [PHP] variable object creating

2005-06-22 Thread Jochem Maas
olivier wrote: Hi, I answered this also, but apparently I only replied to the OP... (reproduced here - minus the typos in my first post on this topic :-/) if (class_exists($className, false)) { $obj = new $className($construct_params); } else { die(Hack off mate.); } Try something

Re: [PHP] variable object creating

2005-06-22 Thread olivier
Sorry for typo error, just need my cup of cofee... Here is a good post for: http://fr.php.net/manual/fr/function.call-user-func-array.php from taylor 08-May-2005 12:04 ?php /** * Create an object of a specified type using

Re: [PHP] variable object creating

2005-06-22 Thread olivier
-- Message transmis -- Subject: Re: [PHP] variable object creating Date: Mercredi 22 Juin 2005 14:19 From: olivier [EMAIL PROTECTED] To: php-general@lists.php.net Sorry for typo error, just need my cup of cofee... Here is a good post for: http://fr.php.net/manual/fr

Re: [PHP] variable object creating

2005-06-22 Thread olivier
Sorry for typo error, just need my cup of cofee... Here is a good post for: http://fr.php.net/manual/fr/function.call-user-func-array.php - see: from taylor 08-May-2005 12:04 - using eval. I dont like eval too but i think that is depending on the pb we want to solve... if you can change contrutor

Re: [PHP] variable object creating

2005-06-22 Thread Jochem Maas
olivier wrote: Sorry for typo error, just need my cup of cofee... :-) no probs ... I think we gave the OP plenty to think about! liked you 'Register' idea - seems like it could work well. also nice one for pointing out my php5isms - I forget that alot of stuff I use is php5 only (e.g. second

Re: [PHP] variable object creating

2005-06-22 Thread Richard Lynch
On Tue, June 21, 2005 8:33 pm, Eli said: Hi, I want to create an object in a form that I get the class name and its parameters, and I need to create that object... How can this been done? i.e: $classname = MyClass; $construct_params = array(param1,param2,param3); /* Now create the

[PHP] variable object creating

2005-06-21 Thread Eli
Hi, I want to create an object in a form that I get the class name and its parameters, and I need to create that object... How can this been done? i.e: $classname = MyClass; $construct_params = array(param1,param2,param3); /* Now create the object with the given classname and params... how?

Re: [PHP] Variable Passing

2005-04-09 Thread Matthew Weier O'Phinney
* Brad Brevet [EMAIL PROTECTED]: This seems to be what I was looking for, but I am curious, will the / be included in the variable? Will I have to do a stripslashes() command on it? If you echo out $_SERVER['PATH_INFO'] for the URL shown below, it will give you: /321 Usually what you do

Re: [PHP] Variable Passing

2005-04-09 Thread Jordi Canals
What I do to control it only by PHP without using the mod_rewrite for apache is to use URL with this format: http://sample.com/script.php/param1/param2/param3 Then, work in the script looking at the variable $_SERVER['REQUEST_URI'] wich will contain, in this sample:

Re: [PHP] Variable Passing

2005-04-09 Thread Matthew Weier O'Phinney
* Jordi Canals [EMAIL PROTECTED]: What I do to control it only by PHP without using the mod_rewrite for apache is to use URL with this format: http://sample.com/script.php/param1/param2/param3 Then, work in the script looking at the variable $_SERVER['REQUEST_URI'] wich will contain, in

[PHP] Variable Passing

2005-04-08 Thread Brad Brevet
Hi, I am curious how to pass a variable without using something like id=321. I have seen sites that have something like http://www.website.com/something/321 and the variable is passed how exactly is that done? And is it called something specific so I know how to refer to it in the future?

Re: [PHP] Variable Passing

2005-04-08 Thread Ken
On Apr 8, 2005 4:11 PM, Brad Brevet [EMAIL PROTECTED] wrote: Hi, I am curious how to pass a variable without using something like id=321. I have seen sites that have something like http://www.website.com/something/321 and the variable is passed how exactly is that done? And is it called

Re: [PHP] Variable Passing

2005-04-08 Thread Hans Juergen von Lengerke
Brad Brevet: Hi, I am curious how to pass a variable without using something like id=321. I have seen sites that have something like http://www.website.com/something/321 and the variable is passed how exactly is that done? And is it called something specific so I know how to refer to it

Re: [PHP] Variable Passing

2005-04-08 Thread Josip Dzolonga
Brad Brevet wrote: Hi, I am curious how to pass a variable without using something like id=321. I have seen sites that have something like http://www.website.com/something/321 and the variable is passed how exactly is that done? And is it called something specific so I know how to refer to it in

Re: [PHP] Variable Passing

2005-04-08 Thread Brad Brevet
This seems to be what I was looking for, but I am curious, will the / be included in the variable? Will I have to do a stripslashes() command on it? Brad Hans Juergen von Lengerke [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] Brad Brevet: Hi, I am curious how to pass a variable

Re: [PHP] Variable Replacement

2005-03-03 Thread Jochem Maas
James Williams wrote: Hey guys, I'm coding a forum right now and I just decided that I needed James, I'll assume that you're coding a forum because you feel like it. :-) (i.e. there are lots of forum 'packages' out there) to code some variable replacement to create a simple template system.

[PHP] Variable Replacement

2005-03-02 Thread James Williams
Hey guys, I'm coding a forum right now and I just decided that I needed to code some variable replacement to create a simple template system. This is the code I have but it doesn't work |?php $tpl = file

[PHP] variable hell

2005-01-04 Thread mario
Hi all I have few variables in this format: $isproductssorttext = 150; $isofferssorttext = 250; $isnewproductssorttext = 350; $isproductscount = 50; $isofferscount = 30; $isnewproductscount = 20; etc What I want to do is have a variable e.g. $x = products; and create from that, the

RE: [PHP] variable hell

2005-01-04 Thread Mike Johnson
From: mario [mailto:[EMAIL PROTECTED] Hi all I have few variables in this format: $isproductssorttext = 150; $isofferssorttext = 250; $isnewproductssorttext = 350; $isproductscount = 50; $isofferscount = 30; $isnewproductscount = 20; etc What I want to do is have a

Re: [PHP] variable hell

2005-01-04 Thread Jyry Kuukkanen
On Tue, 4 Jan 2005, mario wrote: Hi all I have few variables in this format: $isproductssorttext = 150; $isofferssorttext = 250; $isnewproductssorttext = 350; $isproductscount = 50; $isofferscount = 30; $isnewproductscount = 20; etc What I want to do is have a variable

Re: [PHP] variable hell

2005-01-04 Thread John Nichel
mario wrote: Hi all I have few variables in this format: $isproductssorttext = 150; $isofferssorttext = 250; $isnewproductssorttext = 350; $isproductscount = 50; $isofferscount = 30; $isnewproductscount = 20; etc What I want to do is have a variable e.g. $x = products; and create from that,

Re: [PHP] variable hell

2005-01-04 Thread Robby Russell
On Tue, 2005-01-04 at 16:54 +0200, mario wrote: Hi all I have few variables in this format: $isproductssorttext = 150; $isofferssorttext = 250; $isnewproductssorttext = 350; $isproductscount = 50; $isofferscount = 30; $isnewproductscount = 20; etc What I want to do is have

[PHP] variable not being rendered

2004-12-03 Thread Dustin Krysak
Hi there, I have some code where I am using the $_SERVER['PHP_SELF'] array to reference my script for a form action... now for some reason the file name is not being rendered out. I am including only small snippets of my code to see where my error is... ?php $editFormAction =

Re: [PHP] variable not being rendered

2004-12-03 Thread Jason Wong
On Saturday 04 December 2004 15:36, Dustin Krysak wrote: Hi there, I have some code where I am using the $_SERVER['PHP_SELF'] array to reference my script for a form action... now for some reason the file name is not being rendered out. I am including only small snippets of my code to see

[PHP] Variable for search results

2004-11-08 Thread Stuart Felenstein
I have a form element which allows a user to go back x number of days in the records. $sql.=sprintf(SELECT * FROM records WHERE Date_Sub(Curdate(), interval day) $%s = PostStart) This formula works when I actually hardcode the number of days in where this mess -- $%s is right now. I'm not

RE: [PHP] Novice PHP Variable/Link Question

2004-09-17 Thread Gryffyn, Trevor
, September 16, 2004 6:02 PM To: revDAVE Cc: PHP Subject: Re: [PHP] Novice PHP Variable/Link Question On Thu, 16 Sep 2004 14:54:34 -0700, revDAVE [EMAIL PROTECTED] wrote: How can I use a PHP variable as the destination for a link? ? $mylink = 'thispage.htm' a href=thispage.htmgo

Re: [PHP] Novice PHP Variable/Link Question

2004-09-17 Thread Jason Wong
On Friday 17 September 2004 21:49, Gryffyn, Trevor wrote: Alternately, you can do it the lazy way like me: a href=?=$url??=$url?/a ? Echo $url; ? Is the same as... ?=$url? I also think that's a little easier to read. But that's my preference in style. The use of this syntax is

[PHP] Novice PHP Variable/Link Question

2004-09-16 Thread revDAVE
How can I use a PHP variable as the destination for a link? ? $mylink = 'thispage.htm' a href=thispage.htmgo here/a With var...? How do I write this? a href=??? $mylink ???go here/a ? -- Thanks - RevDave [EMAIL PROTECTED] [db-lists] Check out some great Domain Names at: http

Re: [PHP] Novice PHP Variable/Link Question

2004-09-16 Thread Greg Donald
On Thu, 16 Sep 2004 14:54:34 -0700, revDAVE [EMAIL PROTECTED] wrote: How can I use a PHP variable as the destination for a link? ? $mylink = 'thispage.htm' a href=thispage.htmgo here/a With var...? How do I write this? a href=??? $mylink ???go here/a a href=?php echo $url;??php

Re: [PHP] Novice PHP Variable/Link Question

2004-09-16 Thread revDAVE
On 9/16/04 3:01 PM, Greg Donald [EMAIL PROTECTED] wrote: a href=?php echo $url;??php echo $url;?/a It worked great - thanks a lot. -- Thanks - RevDave [EMAIL PROTECTED] [db-lists] Check out some great Domain Names at: http://www.domains4days.com -- PHP General Mailing List

[PHP] Variable variables

2004-08-28 Thread JanBro
Hi List, I'm using PHP5 with global variables off. I've got around 20 dynamically generated forms with a total of 300 different variables sent thru these forms. I'd like to use variable variables, but according to the manual this is not possible. Now comes my Questoin, how do I receive my

Re: [PHP] Variable variables

2004-08-28 Thread Marek Kilimajer
JanBro wrote: Hi List, I'm using PHP5 with global variables off. I've got around 20 dynamically generated forms with a total of 300 different variables sent thru these forms. I'd like to use variable variables, but according to the manual this is not possible. Now comes my Questoin, how do I

Re: [PHP] Variable variables

2004-08-28 Thread Justin Patrin
On Sat, 28 Aug 2004 11:43:13 +0200, JanBro [EMAIL PROTECTED] wrote: Hi List, I'm using PHP5 with global variables off. I've got around 20 dynamically generated forms with a total of 300 different variables sent thru these forms. I'd like to use variable variables, but according to the

[PHP] Variable just not Behaving Itself.

2004-08-10 Thread Harlequin
I have the following: [SNIP] ... $Emp_Status_Rqmt=$row[Emp_Status_Rqmt]; } if( $Emp_Status_Rqmt == 'Permanent' ) { $UserStatus = 'Permanent'; } if( $Emp_Status_Rqmt == 'Contractor' ) { $UserStatus = 'Contractor'; } else { $UserStatus == 'Flexible'; } [SNIP]

Re: [PHP] Variable just not Behaving Itself.

2004-08-10 Thread Justin Patrin
On Wed, 11 Aug 2004 00:36:05 +0100, Harlequin [EMAIL PROTECTED] wrote: I have the following: [SNIP] $Emp_Status_Rqmt=$row[Emp_Status_Rqmt]; } if( $Emp_Status_Rqmt == 'Permanent' ) { $UserStatus = 'Permanent'; } if( $Emp_Status_Rqmt == 'Contractor' ) {

RE: [PHP] Variable just not Behaving Itself.

2004-08-10 Thread Kevin
Hey, I was looking at your code and should that not be an If - ElseIf - Else structure? The way I read this is it first checks to see if the var is set to 'Permanent' and sets $UserStatus. Then regardless of the previous test it does another test on the $Emp_Status_Rqmt to see if it is

Re: [PHP] Variable just not Behaving Itself.

2004-08-10 Thread Robby Russell
On Tue, 2004-08-10 at 16:36, Harlequin wrote: I have the following: [SNIP] ... $Emp_Status_Rqmt=$row[Emp_Status_Rqmt]; } if( $Emp_Status_Rqmt == 'Permanent' ) { $UserStatus = 'Permanent'; } if( $Emp_Status_Rqmt == 'Contractor' ) { $UserStatus = 'Contractor';

<    1   2   3   4   5   6   7   8   9   >