Link to eCommerce Shop Pages
When linking to internal pages, you'll want to make sure to include an associate's webalias in the URL to keep everything under their shop context; however, because a webalias is dynamic, you'll have to write your URLs in a specific way. Dynamically pulling in an associate's {webalias}
into Custom Content Editor is supported through invoking the User Data model via Razor syntax.
So, if you want to include the following URL in your custom page:
{client_ID}.shop.directscale.com/samspace/Application/
You would structure your <a>
element like this:
<a href="{client_ID}.shop.directscale.com/@User.AssociateWebAlias/Application">Linked Text</a>
You can reference the webalias with the @User.AssociateWebAlias
expression.
An exception to the preceding method is on the Site Navigation page. When entering your URL in the Add Link modal, you use {webalias}
to represent the webalias; like so, /{webalias}/Application
.
📘Read more in the Help Center
For more information on the Site Navigation page, see: Adding eCommerce Shop Navigation Links
Updated almost 4 years ago