This article describes the process of adding “breadcrumbs” to your views for easier navigation on a website.
Breadcrumbs are URLs that can help track navigation through a website. For example:
Breadcrumbs will only show up if the current view has a correctly formatted “getBreadcrumbPages” function. In the example above, this function returns an array of three breadcrumbs. This is because there are three separate breadcrumbs after “My Account.”
The “getBreadcrumbPages” function is very easy to use. See this example:
getBreadcrumbPages: function getBreadcrumbPages() {
return [
{
text: 'My Subscriptions',
href: '/subscriptions-list'
},
{
text: this.subscriptionName,
href: '/pendingsubscriptions/' + this.subscriptionId
},
{
text: this.item.name,
href: '/pendingsubscriptionitems/' + this.subscriptionId + '-' + this.itemId
}
];
},
The function simply returns an array of objects that must have a text string and href defined.
Put this function anywhere in your view, and you should be good to go.
Related Article: Hiding Breadcrumbs on a SuiteCommerce Website
We like to update our blogs and articles to make sure they help resolve any troubleshooting difficulties you are having. Sometimes, there is a related feature to enable or a field to fill out that we miss during the instructions. If this article didn't help you, please use the chat and let us know so we can update it!
If you have general questions about SuiteCommerce or more specific questions about how our team can support your business as you implement NetSuite or SuiteCommerce, feel free to contact us anytime. Anchor Group is a certified Oracle NetSuite Alliance Partner and Commerce Partner equipped to handle all kinds of NetSuite and SuiteCommerce projects, large or small!
We are a premium SuiteCommerce agency that creates powerful customer portals. Unlike our competitors, we have already solved your problems.
Want a free paperback copy of this NetSuite e-commerce book? We even pay for shipping...Order the free SuiteCommerce book today!
Tagged with Training