[PHP] using custom button instead of standard submit form element

2003-01-29 Thread Durwood Gafford
I can't figure out how to tell which button was pressed by a user when i'm using a button instead of a standard submit form element. This works: input type=submit name=parent value=foo $parent will equal foo This doesn't work: button type=submit name=parent value=fooimg src=icon.gif/button

[PHP] Using custom button form element instead of standard submit?

2003-01-29 Thread Durwood Gafford
I can't figure out how to tell which button was pressed by a user when i'm using a button instead of a standard submit form element. This works: input type=submit name=parent value=foo $parent will equal foo This doesn't work: button type=submit name=parent value=fooimg src=icon.gif/button

Re: [PHP] Using custom button form element instead of standard submit?

2003-01-29 Thread Durwood Gafford
that's frustratingly difficult. -Durwood Don Read [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... On 27-Jan-2003 Durwood Gafford wrote: I can't figure out how to tell which button was pressed by a user when i'm using a button instead of a standard sub

Re: [PHP] Using custom button form element instead of standard submit?

2003-01-30 Thread Durwood Gafford
sure this would work but it'd be VERY inefficient in my application. It's a file browser application so i have hundreds of folder icons on a page .. the 'submit' element will pass back the name of the button clicked and it would be available immediately/directly, which is what i want. BUT an

Re: [PHP] Using custom button form element instead of standard submit?

2003-01-30 Thread Durwood Gafford
input type=submit name=sample_a input type=image name=sample_b src=myimg.gif With the first method, you'd need to test for a button named 'sample_a'. For the second method, you'd need to test for a button named 'sample_b_x'. no ... with the first example you can have numerous buttons on the

Re: [PHP] Using custom button form element instead of standard submit?

2003-01-30 Thread Durwood Gafford
1lt John W. Holmes [EMAIL PROTECTED] wrote in message If that's what you want, then just make each button a normal a href link and pass an variable to the next page in the link (like someone has already suggested). You'd get the same end result. a href=page.php?sample=aimg/a a

Re: [PHP] Using custom button form element instead of standard submit?

2003-02-01 Thread Durwood Gafford
Durwood Gafford [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... To make the issues more clear (assuming everyone's not totally burned out thinking about this one), I will submit links to working, example code in a followup post. I'm swamped with a prop

[PHP] reading file into a keyword-indexed array

2003-02-04 Thread Durwood Gafford
I would like to read and write user-settings to a keyword-value file and be able to extract it. The following code works fine but i wondered if there was a more elegant/direct way of doing this. -Durwood $file = user_settings.txt; // Read user settings from file if it exists, otherwise set to