Multiple Submit buttons

Results 1 to 2 of 2

Thread: Multiple Submit buttons

  1. #1
    Join Date
    Dec 1969

    Default Multiple Submit buttons

    I have three submit buttons on my page. Submit1 and Submit2 are for navigating through a oRs. When you click on Submit3, I want the form to validate before submitting the data to the server. I originally had used the onsubmit handler but anytime that I would click submit1 or submit2, the form would still validate and then goto the next page !! I only want this to happen when you click on the Submit3.... <BR><BR>Can anyone please help me out? <BR><BR>I tried this: <BR><BR>&#060;form id=FORM1 name=FORM1 method="post"&#062; <BR><BR>&#060;INPUT id=txtName name=txtName&#062; <BR><BR>&#060;INPUT id=Submit type=Submit size=40 value=Previous name=Submit&#062; <BR>&#060;INPUT id=Submit type=Submit value=Next name=Submit&#062; <BR>&#060;INPUT id=cmdSubmit name=cmdSubmit type=button value="Submit"&#062; <BR><BR><BR>Sub cmdSubmit_OnClick <BR><BR>&#039; Check to see if the user entered anything. <BR><BR> If FORM1.txtName.value = empty Then <BR><BR> MsgBox "Name field is empty." <BR><BR>else <BR>FORM1.submit() <BR>end if <BR><BR><BR>End Sub <BR><BR>but I keep getting an error on FORM1.submit() <BR><BR><BR>Any ideas or possible work arounds?

  2. #2
    Join Date
    Dec 1969

    Default RE: Multiple Submit buttons

    Make the first 2 submit buttons to be just button<BR><BR>&#060;INPUT id=previous type=button size=40 value=Previous name=Submit&#062; <BR>&#060;INPUT id=next type=button value=Next name=Submit&#062; <BR><BR><BR>

Posting Permissions

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