This week's book giveaway is in the Servlets forum.
We're giving away four copies of Murach's Java Servlets and JSP and have Joel Murach on-line!
See this thread for details.
The moose likes HTML, CSS and JavaScript and the fly likes Add a link to submit button Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Engineering » HTML, CSS and JavaScript
Bookmark "Add a link to submit button " Watch "Add a link to submit button " New topic
Author

Add a link to submit button

shivang sarawagi
Ranch Hand

Joined: Jun 19, 2008
Posts: 147
I want to navigate to another page when i click the submit button. Can anyone help me in this, how do i do it ??

below is my code

Rajkamal Pillai
Ranch Hand

Joined: Mar 02, 2005
Posts: 443
    
    1


Use Document.href to load a different page.

Note: Not sure if this is deprecated.
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 60774
    
  65

Clicking the submit button will submit the form to the URL specified by the action. If that's not what you want, don't use a submit button in the first place.

Perhaps you can explain more about what you are really trying to accomplish?


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Add a link to submit button
 
Similar Threads
Very tricky question
Calling JNDI from JSP
Can't get RequestDispatcher forward() method or response.sendRedirect() to work
Login JSP page using mysql(DB)
JavaScript in JSP