Note: This guide only applies if you're below version 4 of Locksmith.
If you're on version 4 or above, you can find the "Hide links to navigation" option when editing locks individually. :)
Locksmith can automatically do this based on the locks you put in place. For example, if you create a collection called "Wholesale" and lock this with Locksmith, then put a link to the collection in your shop's main navigation, Locksmith can automatically hide this link from anyone who can't open the lock on your wholesale collection.
Enabling this feature is simple - here are the steps:
- Log in at uselocksmith.com.
- Head to the "Settings" tab.
- Enable "Hide links to locked content", and hit the save button.
That's it! Locksmith will now automatically hide links to locked content - this includes links in your navigation menus, and links that might appear in your shop's search results or collection lists.
If you'd like to enable this setting while leaving a certain link still visible, edit that link in your Shopify admin so that its type is set to "Web address", then type out the web address to your content in the box next to it.
For example, if the link is to your wholesale collection, your menu link might end up looking like this:
Spelling out the address in this fashion prevents Locksmith from seeing the connection to your locked content, thus sidestepping Locksmith's automatic hiding.
Swapping out links
Sometimes you may want to show a link to one set of customers, and show a different link in its place to others. This might be the case if you're a wholesaler - you might want your public to see a collection link labeled "Shirts", pointing to your retail collection of shirts, while showing your wholesalers a link to your wholesale collection instead with exactly the same title.
To do this, follow these steps:
- Enable the "Hide links to locked content" setting, as described above.
- Add both versions of your link to your navigation menu, right next to each other. (Order doesn't matter, since your customers will ultimately only see one at a time.)
- Head over to Locksmith, and - if you haven't already - lock the content that your public customers shouldn't see (in our example, this would be the wholesale collection of shirts), and add keys as appropriate.
- Next, lock the content that your public customers should see (in our example, this is the retail collection of shirts). Then, add a key that permits access in the opposite scenario as for your other lock. (If your other lock has a key that allows customers tagged "wholesale", then this lock should have a key that allows customers who are not tagged "wholesale".)
That's it! You can expand on this technique for other cases as well - the idea is to lock any content that needs to have its links conditionally present (even the public content!), and make sure its keys are set up properly.