Shopify themes, liquid, logos, and UX
Hello! I'm looking to change the HREF of the "Create" button on the Account Registration page. It currently links to the home page, but I am not able to locate the script that sets the HREF. Any help is appreciated!
Solved! Go to the solution
This is an accepted solution.
For those wondering, I found a solution that works.
Open theme.liquid. Just above the </HEAD>, place this script:
<script>
document.addEventListener('DOMContentLoaded', function() {
var REDIRECT_PATH = '/pages/YOURPAGELINKHERE';
var selector = '#create_customer, #customer_login',
$signForm = document.querySelectorAll(selector)[0];
if ($signForm) {
$redirect = document.createElement('input');
$redirect.setAttribute('name', 'return_to');
$redirect.setAttribute('type', 'hidden');
$redirect.value = REDIRECT_PATH;
$signForm.appendChild($redirect);
}
},false);
</script>
@R_Reno - open registration page in customize settings and check if you have any option to change link
There is no option to change anything on the "registration section" except the padding.
@R_Reno - check theme code files for this account page and check if you have any link option there
There is not. It will be in the .js or .liquid. I need help locating it.
This is an accepted solution.
For those wondering, I found a solution that works.
Open theme.liquid. Just above the </HEAD>, place this script:
<script>
document.addEventListener('DOMContentLoaded', function() {
var REDIRECT_PATH = '/pages/YOURPAGELINKHERE';
var selector = '#create_customer, #customer_login',
$signForm = document.querySelectorAll(selector)[0];
if ($signForm) {
$redirect = document.createElement('input');
$redirect.setAttribute('name', 'return_to');
$redirect.setAttribute('type', 'hidden');
$redirect.value = REDIRECT_PATH;
$signForm.appendChild($redirect);
}
},false);
</script>
Shopify and our financial partners regularly review and update verification requiremen...
By Jacqui Mar 14, 2025Unlock the potential of marketing on your business growth with Shopify Academy's late...
By Shopify Mar 12, 2025Learn how to increase conversion rates in every stage of the customer journey by enroll...
By Shopify Mar 5, 2025