I never explicitly installed Wayfinder and I also don't think it comes with the bootstrap theme or the login plugin.
-
☆ A M B ☆
- 24,524 Posts
Then what BobRay wrote applies. MODx itself does not do any checking when making links. It's the snippets (Wayfinder, getResources etc.) that do the permission checks, not core MODx.
Which of those snippets would you recommend to me if all I want at this point is to make the link disappear for anonymous? I don't really know what else those snippets are capable of doing and don't want to confuse myself by adding a huge amount of new functionality without using any of it.
//edit: I'm pretty sure that the bootstrap theme came with pdoTools, however I haven't been able to find a documentation for the latter. I think it includes something similar to getResource too. Is that correct? How could I use it in a way such that anonymous doesn't see the link anymore?
-
☆ A M B ☆
- 24,524 Posts
Personalize is the snippet to use for user-specific welcome, logout and profile links.
http://bobsguides.com/personalize-tutorial.html
You can also use
Output Modifiers to display things only to logged-in users.
[[[[+modx.user.id:isloggedin:is=`1`:then=`$loggedLinks`]]]]
This would load a chunk [[$loggedLinks]] only if the current user is logged in. MODx supplies a number of
user placeholders.
Is it correct that I have to "hard"-code the navigation if I want to use the personalize snippet? I.e. I check the box to hide the member-specific resource from the navigation and then edit the navigation's template and put the link there?
-
☆ A M B ☆
- 24,524 Posts
Unless you install Wayfinder and use it for your navigation. Then you can simply depend on its permission checks to show/hide the link.
-
☆ A M B ☆
- 24,524 Posts
That's the way it's usually done.