Re: Trap CR or "Enter" possible?
| From: | Miguel Cruz | Date: | Sun, 24 Mar 2002 00:07:39 +0000 |
| Subject: | Re: Trap CR or "Enter" possible? | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-89864@lists.php.net to get a copy of this message | ||
On Fri, 22 Mar 2002, Erik Price wrote:
> I have noticed that pressing enter in IE does achieve the same effect as
> pressing the "submit" button for my forms. But I have also heard that
> it's not really "the same", especially if there are more than one
> "submit"-style inputs for the given form. What does Enter "really" do
> in IE?
To be safe, I usually include a hidden variable with a unique name in the
form (<input type="hidden" name="whichform" value="login">).
That way, no
matter what browsers do about the Enter key, I still know what's going on.
miguel