?
Solved

Submit problem ?

Posted on 2000-04-04
4
Medium Priority
?
236 Views
Last Modified: 2010-04-09
I got a situation. There is one form but there are a few submit button but else submit button would like to open separate page.. and all data in the form is avaiable to all page that is created by a submit button in the form... how can i do?
0
Comment
Question by:mrvithan
  • 2
4 Comments
 

Accepted Solution

by:
chteril earned 40 total points
ID: 2683351
try this:

<script>
function submitForm(s){
  document.theForm.action=s;
  document.theForm.submit();
}
</script>

<form name='theform'>

<input type='button' value='submit1' onclick='submitForm("page1.html");'>

<input type='button' value='submit2' onclick='submitForm("page2.html");'>



</form>
0
 

Expert Comment

by:qiang8
ID: 2683378
First create the main.html form.

<form name="btn" Action="choose.asp" method="post">

<input type="submit" name="btnSelect" value="a">
<input type="submit" name="btnSelect" value="b">
<input type="submit" name="btnSelect" value="c">

There make the decision where to go at choose.asp

<%
dim toPage

select case request("btnSelect")
case "a"
  toPage = "page1.asp"
case "b"
  toPage = "page2.asp"
case "c"
  toPage = "page3.asp"
end select

response.redirect toPage

%>

I believe this will work well.
0
 

Expert Comment

by:qiang8
ID: 2683398
Opps..., the one I post is a server side scripting.
0
 

Author Comment

by:mrvithan
ID: 2683422
I didn't try it yet? but i quite believe it work
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

This article discusses four methods for overlaying images in a container on a web page
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 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…
In this tutorial viewers will learn how to embed videos in a webpage using HTML5. Ensure your DOCTYPE declaration is set to HTML5: "<!DOCTYPE html>": Use the <video> tag to insert a video. Define the src as the URL of your video; this is similar to …
Suggested Courses

850 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