Solved

Submit problem ?

Posted on 2000-04-04
4
216 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
[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
 

Accepted Solution

by:
chteril earned 10 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

Why Off-Site Backups Are The Only Way To Go

You are probably backing up your data—but how and where? Ransomware is on the rise and there are variants that specifically target backups. Read on to discover why off-site is the way to go.

Question has a verified solution.

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

Not sure what the best email signature size is? Are you worried about email signature image size? Follow this best practice guide.
The article shows the basic steps of integrating an HTML theme template into an ASP.NET MVC project
The viewer will learn the benefit of using external CSS files and the relationship between class and ID selectors. Create your external css file by saving it as style.css then set up your style tags: (CODE) Reference the nav tag and set your prop…
Video by: Mark
This lesson goes over how to construct ordered and unordered lists and how to create hyperlinks.

695 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