Re: [PHP] if (empty versus if (isset

2013-02-20 Thread ma...@behnke.biz
isset checks if something is defined or if an array has a key with a value other than null read: http://www.php.net/manual/en/function.isset.php#refsect1-function.isset-returnvalues empty check isset PLUS if the value is not null, false, 0 and wahtever php thinks is empty read: http://www.php.ne

Re: [PHP] phpinfo()

2013-02-20 Thread Design in Motion Webdesign
John Taylor-Johnston wrote: I cannot find button2 in phpinfo() when I click it. I was hoping to find a $_POST["button2"] value. What am I doing wrong? I really wanted to use a button to pass a different condition than a Use a different value or name on the button. Don't use JavaScri

[PHP] Re: if (empty versus if (isset

2013-02-20 Thread Jim Giner
Basically it tells a savvy programmer whether or not his logic has caused the var in question to "exist". Many times it is important simply to know that, not what the var contains, which can lead to an error in processing. The isset() will tell you that "yes, I have this variable", letting yo

Re: [PHP] Re: if (empty versus if (isset

2013-02-20 Thread ma...@behnke.biz
> Jim Giner hat am 20. Februar 2013 um 15:10 > geschrieben: > > > Basically it tells a savvy programmer whether or not his logic has > caused the var in question to "exist". Many times it is important > simply to know that, not what the var contains, which can lead to an > error in processing.

Re: [PHP] if (empty versus if (isset

2013-02-20 Thread Tedd Sperling
On Feb 20, 2013, at 9:10 AM, Jim Giner wrote: > Basically it tells a savvy programmer whether or not his logic has caused the > var in question to "exist". Many times it is important simply to know that, > not what the var contains, which can lead to an error in processing. > > The isset() wi

Re: [PHP] phpinfo()

2013-02-20 Thread Tedd Sperling
On Feb 19, 2013, at 7:57 PM, John Taylor-Johnston wrote: > I cannot find button2 in phpinfo() when I click it. I was hoping to find a > $_POST["button2"] value. > What am I doing wrong? > > onclick="formSubmit()"> > > I really wanted to use a button to pass a different condition than a type

Re: [PHP] parsing select multiple="multiple"

2013-02-20 Thread Tedd Sperling
On Feb 18, 2013, at 7:54 PM, John Taylor-Johnston wrote: > I am capable with . (I suppose I did it correctly? > :p ) > But I haven't the first clue how to parse a and multiply > select name="DPRtype". > Would anyone give me a couple of clues please? :) > Thanks, > John John: A clue? How abo

Re: [PHP] parsing select multiple="multiple"

2013-02-20 Thread Jim Giner
On 2/20/2013 11:41 AM, Tedd Sperling wrote: On Feb 18, 2013, at 7:54 PM, John Taylor-Johnston wrote: I am capable with . (I suppose I did it correctly? :p ) But I haven't the first clue how to parse a and multiply select name="DPRtype". Would anyone give me a couple of clues please? :) Tha

[PHP] stripped \n

2013-02-20 Thread John Taylor-Johnston
Hi, I have a when submitted creates a new form with the textarea data in a hidden field: But when this new form gets resubmitted, the \n get stripped? I don't get it. There is nothing in my code that is stripping the \n? value=""> Do I need to put it in another textarea and declare it

[PHP] Re: stripped \n

2013-02-20 Thread Jim Giner
On 2/20/2013 1:16 PM, John Taylor-Johnston wrote: Hi, I have a when submitted creates a new form with the textarea data in a hidden field: But when this new form gets resubmitted, the \n get stripped? I don't get it. There is nothing in my code that is stripping the \n? "> Do I need to

Re: [PHP] stripped \n

2013-02-20 Thread Matijn Woudt
On Wed, Feb 20, 2013 at 7:16 PM, John Taylor-Johnston < john.taylor-johns...@cegepsherbrooke.qc.ca> wrote: > Hi, > I have a when submitted creates a new form with the textarea > data in a hidden field: > > > > But when this new form gets resubmitted, the \n get stripped? > > > > I don't get it.

Re: [PHP] stripped \n

2013-02-20 Thread Daniel Brown
On Wed, Feb 20, 2013 at 1:32 PM, Matijn Woudt wrote: > > An input with type=text is used for single lines, so yes, newlines get > stripped. > Either use a textarea with style="display: none", or store the data in a > session instead. Or at least . -- Network Infrastructure Manager http://w

Re: [PHP] stripped \n

2013-02-20 Thread Jim Giner
On 2/20/2013 1:32 PM, Matijn Woudt wrote: On Wed, Feb 20, 2013 at 7:16 PM, John Taylor-Johnston < john.taylor-johns...@cegepsherbrooke.qc.ca> wrote: Hi, I have a when submitted creates a new form with the textarea data in a hidden field: But when this new form gets resubmitted, the \n get s

Re: [PHP] stripped \n

2013-02-20 Thread Ashley Sheridan
On Wed, 2013-02-20 at 13:47 -0500, Jim Giner wrote: > On 2/20/2013 1:32 PM, Matijn Woudt wrote: > > On Wed, Feb 20, 2013 at 7:16 PM, John Taylor-Johnston < > > john.taylor-johns...@cegepsherbrooke.qc.ca> wrote: > > > >> Hi, > >> I have a when submitted creates a new form with the textarea > >> da

Re: [PHP] phpinfo()

2013-02-20 Thread John Taylor-Johnston
Design in Motion Webdesign wrote: John Taylor-Johnston wrote: I cannot find button2 in phpinfo() when I click it. I was hoping to find a $_POST["button2"] value. What am I doing wrong? I really wanted to use a button to pass a different condition than a Use a different value or nam

Re: [PHP] phpinfo()

2013-02-20 Thread Ashley Sheridan
On Wed, 2013-02-20 at 14:23 -0500, John Taylor-Johnston wrote: > > Design in Motion Webdesign wrote: > > > >> > >> > >> John Taylor-Johnston wrote: > >> > >>> I cannot find button2 in phpinfo() when I click it. I was hoping to > >>> find > >>> a $_POST["button2"] value. > >>> What am I doing wro

Re: [PHP] phpinfo()

2013-02-20 Thread Stuart Dallas
On 20 Feb 2013, at 19:23, John Taylor-Johnston wrote: > > > Design in Motion Webdesign wrote: >> >>> >>> >>> John Taylor-Johnston wrote: >>> I cannot find button2 in phpinfo() when I click it. I was hoping to find a $_POST["button2"] value. What am I doing wrong?

Re: [PHP] stripped \n

2013-02-20 Thread Jim Lucas
On 02/20/2013 10:16 AM, John Taylor-Johnston wrote: Hi, I have a when submitted creates a new form with the textarea data in a hidden field: But when this new form gets resubmitted, the \n get stripped? I don't get it. There is nothing in my code that is stripping the \n? "> Do I need t

Re: [PHP] phpinfo()

2013-02-20 Thread Tedd Sperling
On Feb 20, 2013, at 2:31 PM, Stuart Dallas wrote: > You were given the answer, did you not try it? > > Starting with the code in your original post: > > 1) Change the type to submit. > 2) Remove the onclick. > 3) Job done! > > -Stuart Sometimes you just can't help. > Sent from my leaf blowe

Re: [PHP] phpinfo()

2013-02-20 Thread tamouse mailing lists
On Wed, Feb 20, 2013 at 1:31 PM, Stuart Dallas wrote: > -Stuart > > -- > Sent from my leaf blower > -- Did you get the 4G model, or is this just the WiFi version? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] parsing select multiple="multiple"

2013-02-20 Thread tamouse mailing lists
On Tue, Feb 19, 2013 at 1:02 PM, John Taylor-Johnston wrote: > > tamouse mailing lists wrote: >>> >>> >I hate arrays. :D >> >> Here's a small snippet showing how it works, I hope: >> >> foreach ($DPRpriority as $item => $value) { >>echo " ".$item.": ".$value['name']." selected: >> ".$value['se