Community Forums 

Main Content

Problem with anchors in html buttons

    Aug 10 2017 11:15:16

    #1

    SteveBS

    Join date : 2012-01-24      Posts : 5

    I am using html buy buttons with a return page set up.
    My pages uses anchors such as <a name="section2">...</a> and I am trying to configure the button to have a return attribute that incorporates the anchor so that customers can return to the relevant section of the page.

    my code includes the following:

    rtnpage = pagename+"%23"+section

    <a href="http://ww9.aitsafe.com/cf/add.cfm?......&return=www.mywebsite.com/',rtnpage,....



    The intention is to submit:
    www.mywebsite.com/mypage.htm#section2

    However, the return address from the basket is:
    www.mywebsite.com/mypage.htm?tp=CONTINUE+SHOPPING#section2
    which obviously doesnt work as the #section2 is appearing in the wrong place.

    Any ideas how to get the #section2 anchor to appear with the return page so that it can be interpreted properly by the browser?
    ..or can I stop the ?tp=CONTINUE+SHOPPING from appearing?



    Aug 10 2017 16:54:44

    #2

    GT

    Join date : 2008-09-18      Posts : 3202

    Having trouble with a form or need one building?
    Fast turnaround, but I do charge :)

    Mal's Forms / Scripts and the syntax are here.




    Aug 15 2017 10:05:20

    #3

    SteveBS

    Join date : 2012-01-24      Posts : 5

    Thanks. Sorted and working now.
    Incidently, it doesnt work with older versions of Chrome, such as Version 49.0.2623.112 m