How do I return to original form calling page from the Thank You page?

  • Profile Image
    Asked on March 28, 2015 at 11:12 AM

     I am linking to my form from within an eBay listing using:

    <p><a target="_blank" href="*****" >Click here to enter your personalisation details</a></p>

    (Specific form details above obscured *****). The "_self" parameter keeping the form within the same window/tab.

    After I have filled the form and Submitted it the Thank You page opens as expected.

    To manually get back to the calling eBay listing I click the browser Back button twice. I would like to be able to put a "Return to eBay" button under my custom text on the Thank You page that programatically goes back 2 pages to the eBay listing - how can I do this?

    Note - I can't use a direct URL link as this form is used in a template for multiple eBay listings and hence the URL is variable.

    Thanks in anticipation


  • Profile Image
    Answered on March 28, 2015 at 01:32 PM

    Thank you for contacting us.

    Since you cannot use the normal thank you page URL redirection, you would need to create your own custom PHP page that will serve as the thank you page and use JavaScript to make the "Return to ebay" link work correctly.

    For example, on this page: I've embedded a cloned version of your form. If you submit it the custom thank you page will be displayed and when you click on the "Return to ebay" link you'll be redirected back to the page where the form is embedded.

    To accomplish this as mentioned, I used a custom PHP thank you page and also enabled the POST data in the form to retrieve the name and the id values.

    Give it a try and let us know if this works for you.

    I've posted here: the source code of the thank you page and you can also view the source code of the index.html if you want to.

    If you have further questions, please let us know.
    Thank you.

  • Profile Image
    Answered on March 30, 2015 at 10:34 AM

    Hi Raul,

    Thanks for your assistance. To test I have l embedded a link to your version of my test form ( into my test eBay listing ( if you scroll down to the Description section you will see a link to your form ("Click here to enter your personalisation details”). If you then click that link, complete the form & Submit it, you arrive at your new version of the Thank You page.
    So far so good - however the “Return to eBay” link still does not work!
    What is going wrong? and how can this be fixed?
    Thanks in anticipation.
  • Profile Image
    Answered on March 30, 2015 at 12:29 PM

    Hello Paul,

    Upon checking the source code of the thank you page, it seem to have the following code:

    <a target="_blank" href="" onclick="javascript:history.back(-2);">Return to eBay</a></div>

    I would suggest you to use the following code and see if that solves your problem:

    <a target="_blank" href="javascript:history.back(-2);">Return to eBay</a></div>


    Please test the following form and see if this works as expected. The thank URL I have changed to the following URL: 

    Hope this helps.

    Do get back to us if the issue persists.

    Thank you!