Re: [phplib] Oohforms and submit buttons From: Jesse Swensen (swensenj <email protected>)
Date: 06/14/01

You could use JavaScript to set the value for you.

First in you header define what setSubmit does like
<script>
    function setSubmit() {
        document.MyForm.Mysubmit.value = "Submitted";
    }
</script>

In your form declaration you would put something like

<form name="MyForm" onSubmit="setSubmit()">
. . .
    <input type="hidden" name="MySubmit" value="">
</form>

This is a very rough suggestion and you will need to flesh it out. YMMV...

-- 
Jesse Swensen
swensenj <email protected>

> From: Paul Smith <paul <email protected>> > Date: Tue, 12 Jun 2001 15:51:01 -0500 > To: phplib <email protected> > Subject: [phplib] Oohforms and submit buttons > > If you're using oohforms, one way to set things up is to have the form > action be $PHPSELF, then check for the existence of the submit button > to do error checking. However, if there is only one <input type="text"> > element in a form, and you hit return within that element to submit the > form, the submit button doesn't get passed to the action page. You have > to click it with the mouse. > > Is there a better way to do this? How can you check that a form has been > submitted without relying on the submit button? > > -- > Paul Smith <paul <email protected>> > InfoTech Designer > Center for Neighborhood Technology > Chicago, Illinois USA > > --------------------------------------------------------------------- > To unsubscribe, e-mail: phplib-unsubscribe <email protected> > For additional commands, e-mail: phplib-help <email protected> >

--------------------------------------------------------------------- To unsubscribe, e-mail: phplib-unsubscribe <email protected> For additional commands, e-mail: phplib-help <email protected>