Three ways to test the value of Page Label on any Salesforce B2B Commerce Community Page are:
Execute CCRZ.pagevars.pageLabels[‘PAGE_LABEL_NAME’] in the JavaScript console. This will return the value of the page label with the given name from the pagevars object, which contains all the page labels that are used on the page.
ExecuteCCRZ.processPageLabelMap(‘PAGE_LABEL_NAME’) in the JavaScript console. This will return the value of the page label with the given name from the pageLabelMap object, which contains all the page labels that are defined in CCAdmin.
Enable the ‘display page label names’ in cc admin. This will display the name of each page label next to its value on the storefront pages, which can help identify and verify the page labels. Salesforce References: B2B Commerce and D2C Commerce Developer Guide, Page Labels
Contribute your Thoughts:
Chosen Answer:
This is a voting comment (?). You can switch to a simple comment. It is better to Upvote an existing comment if you don't have anything to add.
Submit