For Programmers: Free Programming Magazines  


Home > Archive > PHP DB > March 2007 > Re: [PHP-DB] Using multiple submits on a page and retaining $POST data









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author Re: [PHP-DB] Using multiple submits on a page and retaining $POST data
Gunawan Wibisono

2007-03-16, 8:03 am

solved

On 3/16/07, Onochie Anyanetu <ubernoch@gmail.com> wrote:
> Hello Gunawan
>
> On your first comment, im not sure what you were referring to when you said
> it is a js problem
>
> on your second comment, i am talking about the user entered data. data
> submitted by the first submit button will always be predefined by means of
> the user using a selection box, the data im concerned with checking is the
> input boxes he will be seeing. and this wont necessarily be username/pass.
> and im trying to do this in php if at all possible.
>
> on your next comment, (6) i am talking about after i vertified the validity
> of the user typed/entered data, i will enter that into my db
>
> next comment - i knew this would be hard to describe, but i'll try again.
> this is to be done all on one page. and ive tried using something like:
>
> value=\"$_POST['name']\"


> but i am having problems keeping the initial drop down at the selected
> choice, so whenever either submit button is pressed and the post goes to php
> self, the drop down is refreshed back to its starting value, which is NULL

hahaha..
that's simple.. drop down menu always return to the null because u
don't give selected on one of option.
i have a function (build in) that's answer your problem.. if you on
hurry.. i'm sory, i cant give it now.. my skrip in other comp..
<select>
<option value="base" selected>sale options</option>
<option value="base2" >Buy options</option>
</select>

try this on offline
i believe.. the first you enter the page.. the sale option will be selected

now add 2 option then try one of the option you add have selected..
what happen next you will see the default will be change, remember
erase selected

forgive me.. i think it matter of js but it matter of html.
fyi.. try using ajax .. i believe it make your life for comfort..
(since it don't need to refresh the page) and make your skill up.
>
>
> I hope that helps define my problem a little more
>
> Onochie
>
>
> On 3/16/07, Gunawan Wibisono <landavia81@gmail.com > wrote:
> I
> data
> is
> first
> the
> the
> isset)
> (step
> retrieve
> back
> drop
> work
> longer
> data on
> any,
> you.
>
>



--
akan ada dimana mulut terkunci dan suara tak ada lagi..
saat itu gunakanlah HP untuk melakukan SMS!!
-> ini aliran bedul.. bukan aliran aneh.
tertawa sebelum tertawa didepan RSJ..
Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com