Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 5 of 5
  1. #1
    New Coder
    Join Date
    Jan 2003
    Posts
    13
    Thanks
    0
    Thanked 0 Times in 0 Posts

    two submit buttons, two locations?

    Hey,
    I'm making a script in ASP right now, but came to a spot where I need some java help... As I have NO experience in Java I figured I'd come here.

    I've got one form, 2 buttons, one button is a submit button that sends out the form, but the other button I want to use for a.. similar purpose, but I want it to go to a differant page.. here's what I've got

    Form action goes to "save.asp"
    input text box
    input text box | input button 2
    input submit button

    Now I want that button 2 to go back to the same page it's currently at, but I want to be able to have it drag the text box info along with it.. any way I can do that?
    Thanks,
    -Ben

  • #2
    Regular Coder
    Join Date
    Jun 2002
    Location
    Australia
    Posts
    197
    Thanks
    0
    Thanked 0 Times in 0 Posts
    huh?
    you want
    but the other button I want to use for a.. similar purpose, but I want it to go to a differant page..

    Now I want that button 2 to go back to the same page it's currently at, but I want to be able to have it drag the text box info along with it..

    You should read your post again its very confusing..
    how does a button 'drag text with it' ?
    how does anything go back to where its currently at?

    I cant make any sense of your question
    ez
    Animation Rule #64
    Poor quality images are often artistic,
    Poor quality sound is ALWAYS annoying.

  • #3
    New Coder
    Join Date
    Jan 2003
    Posts
    13
    Thanks
    0
    Thanked 0 Times in 0 Posts
    I guess I forgot this isn't an ASP masters class.. heh sorry

    Drag the text along, basically I mean when your working with ASP, PHP, CGI etc, you can put in a code (blah = Request.Form("blah")) that you can get the text from the previous form..
    To sum it up, I want the two buttons to be submit buttons, but one goes to a differant page

    I tried Onclick="window.lcation='blahblah'", but that doesn't do the same as the actual submit button

  • #4
    Regular Coder
    Join Date
    Jun 2002
    Location
    Australia
    Posts
    197
    Thanks
    0
    Thanked 0 Times in 0 Posts
    I have used something like
    <a href='blah' onClick='javascript:document.results.submit();'>
    before
    ez
    Animation Rule #64
    Poor quality images are often artistic,
    Poor quality sound is ALWAYS annoying.

  • #5
    Senior Coder
    Join Date
    Jun 2002
    Location
    41 8' 52" N -95 53' 31" W
    Posts
    3,660
    Thanks
    0
    Thanked 0 Times in 0 Posts
    <input type="button" value="Do something else!" onclick="document.formname.action='otherpage.asp';document.formname.submit()" />

    Former ASP Forum Moderator - I'm back!

    If you can teach yourself how to learn, you can learn anything. ;)


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •