JavaScript Development
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
 
User Name:
Password:
Remember me
 
Go Back   Dev Articles Community ForumsProgrammingJavaScript Development

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Display Modes
 
Unread Dev Articles Community Forums Sponsor:
  #1  
Old October 21st, 2004, 09:27 PM
guy99 guy99 is offline
Registered User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Oct 2004
Posts: 2 guy99 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Problem with Form Submission with Enter

I'm having some problems with my form. IE refuses to allow the use of the Enter key to submit the form, returning with 5 beeps everytime I try to submit the form with the Enter key. As far as I can tell, the onsubmit() call is not triggered at all when the Enter key is pressed.

However, if the focus was to go to the Submit button and return back to any of the textboxes without submitting the form, the Enter key would work. The interesting thing is, Mozilla 1.7.2 works like a charm. Pressing Enter submits the form instantly. The Javascript Console didn't display any errors at all. (Unfortunately, due to reasons, I'm catering strictly to IE.)

I'm guessing it has something to do with the way my form is made up of. So a brief description of my page is in order.

The page comprises of top portions. The top portion contains links which shows one div and hides the remaining divs in the bottom portion. Each div contains one form. The form is made up of 3 tables. The middle table is contained in a div, which will be hidden if a certain condition is met. Some data are given via a MySQL database. Form action is posted back to the same page, which is processed via ASP.

Below is a rough way in which the page works. (I hope that makes sense)

Code:
  <a href=# onclick="showhidediv('ref')">blah</a>
  <a href=# onclick="showhidediv('ref2')">blah2</a>
  .
  <div id='ref'>
  <form>
  <table>
  .
  </table>
  <div id='table2>
  <table>
  .
  </table>
  </div>
  <table>
  .
  </table>
  </form>
  </div>
  <div id='ref2'>
  .
  .
  .
  </div>
  

Reply With Quote
  #2  
Old October 24th, 2004, 10:10 AM
mouse85 mouse85 is offline
Registered User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Oct 2004
Posts: 2 mouse85 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
maybe change onclick to onsubmit?

Last edited by mouse85 : October 24th, 2004 at 10:13 AM. Reason: typed wrong stuff

Reply With Quote
  #3  
Old October 24th, 2004, 11:56 PM
guy99 guy99 is offline
Registered User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Oct 2004
Posts: 2 guy99 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Quote:
Originally Posted by mouse85
maybe change onclick to onsubmit?

Wouldn't work. The onclick calls the code which shows and hide the divs.

Reply With Quote
Reply

Viewing: Dev Articles Community ForumsProgrammingJavaScript Development > Problem with Form Submission with Enter


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump




 Free IT White Papers!
 
Create the Optimal Architecture for your Critical Applications
Warburton's the largest independently owned bakery in the UK faced a number of difficult challenges in providing the most robust yet efficient IT infrastructure for their organization's success. IBM's services combined with their xSeries servers created the perfect platform for their SAP environment with sufficient flexibility, and did so in very time effective fashion.

Request Your Free Technology Downloads!
 
Five Best Practices for Deploying a Successful Service-Oriented Architecture
This white paper describes the benefits you can expect with SOA, and how IBM can help take your business there.

Request Your Free Technology Downloads!
 
Gartner Magic Quadrant for Application Delivery Controllers
Gartner summarizes its view on Application Delivery Controllers, evaluates strengths and weaknesses of solutions, and provides Magic Quadrant reporting for a quick comparison across all vendors. Learn from Gartner how you can benefit from an all-in-one device like Citrix NetScaler that delivers the highest levels of availability, performance and security.

Request Your Free Technology Downloads!
 
Knowledge is Power
What you don't know can hurt you, and is likely costing you money and increasing your security risks during an era of scarce resources. This white paper proposes six key strategies that enterprise security managers can use to improve their network defense posture.

Request Your Free Technology Downloads!
 
Rationalizing the Multi-Tool Environment
The rationalized multi-tool approach is flexible, scalable and cost effective. It provides the necessary input to the IT service management business processes. It preserves prior investments in monitoring tools, empowers technologists to select the best tools with which to do their jobs, and enhances effective response to incidents.

Request Your Free Technology Downloads!
 

Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 




© 2003-2010 by Developer Shed. All rights reserved. DS Cluster 2 Hosted by Hostway
For more Enterprise Application Development news, visit eWeek