Solved

Default Buitton when Enter Key Pressed

Posted on 2014-03-07
4
196 Views
Last Modified: 2014-03-07
Hello,

I would like the form on the following page to be submitted when a user presses the enter key.  I know this should be simple (and hopefully will be!), but I simply don't seem to be able to get it to work...

The page can be seen here:

http://www.villasdirect.com

Thanks in advance.
0
Comment
Question by:Nico2011
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
4 Comments
 
LVL 8

Assisted Solution

by:jpgobert
jpgobert earned 500 total points
ID: 39911907
What have you tried?  

Have you tried setting the default button property in your form declaration line?

<form id="form1" class="refno" name="form1" method="post" defaultbutton="searchlocationrentals" action>
0
 
LVL 53

Expert Comment

by:Scott Fell, EE MVE
ID: 39912150
It seems to work in chrome. There are some warnings in the js console although I don't think that would cause an issue.
0
 
LVL 8

Accepted Solution

by:
jpgobert earned 500 total points
ID: 39912176
Your action attribute doesn't have a value... it was like that when I copied it earlier and forgot to mention it... can you update that and test again?
0
 

Author Closing Comment

by:Nico2011
ID: 39912212
Thank you both - it seems to work - not sure if all the time, but for now - fingers crossed!
0

Featured Post

[Webinar] Code, Load, and Grow

Managing multiple websites, servers, applications, and security on a daily basis? Join us for a webinar on May 25th to learn how to simplify administration and management of virtual hosts for IT admins, create a secure environment, and deploy code more effectively and frequently.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
JQuery on multiple lines 3 48
output in HTML in Powershell 5 60
Help with Classic ASP - Parameterizing Query 16 65
Expanding/Collapsing Tree on SharePoint List 29 64
This article describes how to create custom column layout styles for Bootstrap. The article uses 5 columns to illustrate the concept, but the principle can be extended to any number of columns.
Originally, this post was published on Monitis Blog, you can check it here . Websites are getting bigger and more complicated by the day. Video, images and custom fonts are all great for showcasing your product or service. But the price to pay in…
In this tutorial viewers will learn how to position items using CSS's three positioning types Create a new HTML document with an internal stylesheet.: Create another div in CSS and name it Absolute : Type "position:absolute;" and "top:10px; left:50p…
In this tutorial viewers will learn how to style transparent/translucent elements using alpha transparency in CSS Start with a normal styled element, such as a div.: Define its "background-color" property as "rgba (255, 255, 255, .5): The numbers in…

738 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question