struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Shilpa Vaidya" <>
Subject RE: [OT] form default submit button
Date Fri, 13 Aug 2004 09:44:20 GMT
try use 

onsubmit(); instead of onclick()


-----Original Message-----
From: Erez Efrati []
Sent: Friday, August 13, 2004 4:12 PM
To: 'Struts Users Mailing List'
Subject: [OT] form default submit button

This not a struts issue though my project is well attached down to the
bones to struts.
I am a bit rusty in HTML and I need your advice.
I have a login form with username and password fields. The button is
built with a table consisting of the graphical edges and the text 
(retrieved from the resource bundle) in the middle.
What do I have to do so when the user is in the username field or
password and hits <ENTER> the form will submit. Currently it does not do
it and I have to click on the "table" button, whereas with buttons made
of <html:submit>.</html:submit> it worked automatically even with more
forms on the page where each works the same way autonomously. 
Here is the fragment of the button in my login form.
<-- Start Button -->
<div class="btn" onclick="LoginForm.submit();" style="margin-top:10px;">
      <table border="0" cellpadding="0" cellspacing="0">
                        <td class="btnRight">&nbsp;
                        <td class="btnText">
                        <td class="btnLeft">&nbsp;
<!-- End Button -->
Thanks in advance,


"This e-mail message may contain confidential, proprietary or legally privileged information.
should not be used by anyone who is not the original intended recipient. If you have erroneously

received this message, please delete it immediately and notify the sender. The recipient 
acknowledges that ICICI Bank or its subsidiaries and associated companies,  (collectively
Group"), are unable to exercise control or ensure or guarantee the integrity of/over the contents
of the information contained in e-mail transmissions and further acknowledges that any views

expressed in this message are those of the individual sender and no binding nature of the
message shall be implied or assumed unless the sender does so expressly with due authority
of ICICI Group.Before opening any attachments please check them for viruses and defects."

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message