by GlenH
6 replies
HI guys,

Here is part for an optin form code:

<input name="merchantid" type="hidden" id="merchantid" value="51293">
<input name="ARThankyouURL" type="hidden" id=" ARThankyouURL" value="http://www.desperatenichedominator.com/reporttyp.html">

What current happens is that when the person hits the 'Submit' button on the form, they are redirected to the ARThankyouURL listed ie (value=http://www.desperatenichedominator.com/reporttyp.html)

The problem is that the currently displayed web page closes so that the ARThankyouURL can open.

I don't want that to happen. because there is other info. on teh existing web page.

I need that ARThankyouURL to open in a new window.

I've tried adding the TARGET="_blank", but since it's not a link, that function doesn't work.

Does anyone have any ideas?
#code #form #question
  • Profile picture of the author jaimegm
    You can redirect the page to itself, and then using javascript pass the parameters to open it in a new window using window.open("http://www.desperatenichedominator.com/reporttyp.html?Param1=Sometthing&Param2=Somethinge lse","_blank") that is one solution
    {{ DiscussionBoard.errors[9809895].message }}
  • Profile picture of the author David Beroff
    Originally Posted by GlenH View Post

    I've tried adding the TARGET="_blank", but since it's not a link, that function doesn't work.
    Have you tried using that attribute in the actual <form ...> tag for the form? It should work.
    Signature
    Put MY voice on YOUR video: AwesomeAmericanAudio.com
    {{ DiscussionBoard.errors[9810096].message }}
    • Profile picture of the author GlenH
      Originally Posted by David Beroff View Post

      Have you tried using that attribute in the actual <form ...> tag for the form? It should work.
      Sorry, I'm a bit of a dunce as far as 'code' goes, so I'm not really sure how I'd go about doing that.
      {{ DiscussionBoard.errors[9810100].message }}
      • Profile picture of the author David Beroff
        Originally Posted by GlenH View Post

        Sorry, I'm a bit of a dunce as far as 'code' goes, so I'm not really sure how I'd go about doing that.
        You said you tried putting it in the input tag. Try instead putting that target="_blank" attribute in the <form> tag at the beginning of the form.
        Signature
        Put MY voice on YOUR video: AwesomeAmericanAudio.com
        {{ DiscussionBoard.errors[9810106].message }}
        • Originally Posted by David Beroff View Post

          You said you tried putting it in the input tag. Try instead putting that target="_blank" attribute in the <form> tag at the beginning of the form.
          ^^ What David said. Checked your website, and I think you are looking at the "Get this report now for free" form. In your code, replace the entire line which starts with

          Code:
          <form name="form2" method="post" action="https://www.mcssl.com/app/contactsave.asp">
          with the following:

          Code:
          <form name="form2" method="post" action="https://www.mcssl.com/app/contactsave.asp" target="_blank">
          That should do the trick.
          {{ DiscussionBoard.errors[9810472].message }}
          • Profile picture of the author GlenH
            Thanks for all for all the help guys.

            I'll try that Wordpressexperthelp
            {{ DiscussionBoard.errors[9810486].message }}

Trending Topics