Terms and Conditions checkout page link opening page within the checkout page

Hi,

I am having an issue with the link on the Checkout page for Terms and Conditions.

After reading some tips to create the page using Classic elements I at least got it to stop showing source code and it is now showing the page, but it is loading within the Checkout page in a scroll box rather than opening it as a new page similar to how the Privacy Policy link above it works.

I did also find an article here about adding a JS code snippet to make the link open to a new page which it does, but the scroll box of the page is still showing on the Checkout page as well so I removed that as it isnt a total fix for the issue.

many thanks for your help,
Jenna

Hi Jenna,

To make the terms & conditions link open new tab, please add this code under Theme Options > JS:

jQuery( function($) {
	$("a.woocommerce-terms-and-conditions-link").off('click touchend');
	$( "a.woocommerce-terms-and-conditions-link" ).on('click touchend', function( event ) {
		event.preventDefault();
		$(this).attr("target", "_blank");
	    window.open( $(this).attr("href"));
	});
});

Hope it helps :slight_smile:

I added the JS, but while it worked briefly it still doesnt open the window and the window box is still present on the checkout page.

Hi There,

Would you mind providing us with login credentials(by clicking on the Secure Note button at the bottom) so we can take a closer look? To do this, you can make a post with the following info:

  • Link login to your site
  • WordPress Admin username / password

Thanks.

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.