|
/ Knowledge Base / Change Customer Dashboard Permalinks

Change Customer Dashboard Permalinks

This document explains how to customize the links associated with the “Go Back” button and store logo in the SureCart customer dashboard.

Customer Dashboard Default Permalinks

By default, the “Go Back” button and store logo in the SureCart customer dashboard link back to the website’s homepage. However, you might prefer these elements to link to a different, more relevant page for your customers.

How to Change Permalinks in Customer Dashboard

The SureCart development team has recently introduced a solution for this specific need. Here’s how it works:

  • New Filters: Two new filters have been added, allowing you to modify the URLs for both the “Go Back” button and the store logo.
    • sc_customer_dashboard_back_home_url: This filter controls the URL for the “Go Back” button.
    • sc_customer_dashboard_store_logo_url: This filter controls the URL for the store logo.
  • Using the Filters: By adding custom code snippets utilizing these filters, you can redirect users to your preferred page when they click on the “Go Back” button or the store logo within the customer dashboard.

Here’s an example of how the code snippet might look (replace “https://example.com/” with your desired URL):

add_filter('sc_customer_dashboard_back_home_url', function( $url ) { return 'https://example.com/'; });
add_filter('sc_customer_dashboard_store_logo_url', function( $url ) { return 'https://example.com/'; });

How to Add the Code:

  • Child Theme’s functions.php: You can add the code snippet to the functions.php file within your child theme.
  • Code Snippet Plugin: Alternatively, you can use a code snippet plugin specifically designed for adding custom PHP code to your website.

Alternative Workaround

You can also check the below mentioned alternative workaround:

Change Default Template: You’ll need to modify the default template for your custom dashboard (refer to the provided screenshot.

Create New Template: Manually create a new template for your custom dashboard. This new template will allow you to define a custom link for the “Go Back” button.

We hope this document provides you with the information you need to customize the links in your SureCart customer dashboard. If you have any further questions or require additional assistance, please don’t hesitate to leave a comment below.

Was this doc helpful?
What went wrong?

We don't respond to the article feedback, we use it to improve our support content.

Need help? Contact Support
On this page

Download is Just A Click Away!

Enter your email address and be the first to learn about updates and new features.

E-Commerce Store Launch Checklist Download
Scroll to Top