MENU

Marking protected pages in your navigation

  Previous article Next article  

When using Calguy1000's FrontEndUsers module in CMS Made Simple you can easily protect the content of your pages and hide the buttons in the navigation for visitors who are not logged in.
But when you are logged in, you can't see the difference in the menu between regular and protected page buttons. With a small addition to the menu template you can add that feature.

Because there are several menu templates, I will give a general explanation on adding it. You will need to see for yourself how it works in your template.

  How to use

For changing a navigation template, you have to go to the Design Manager and look for your (default) Navigator template.

Search in the template for the parameter {$node->menutext}. Depending on your template you can find it in multiple lines!

Some examples how to change it:

A. Add a marker

{$node->menutext}{if $node->type == 'feu_protected_page'} *{/if}

B. Change the button styling with a class

{if $node->type == 'feu_protected_page'}<span class="protected_page">{/if}
  {$node->menutext}
{if $node->type == 'feu_protected_page'}</span>{/if}

Stylesheet example

.protected_page {
  /* style declarations */
}

More information on Navigator template parameters.


Buy Me A Coffee


  Comment Form

ReviewManager

Click here to open the form

ReviewManager

  1 Comment

Buy Me A Coffee

CMS Made Simple - Tutorials, Tips and Tricks - CMSMS

Marking protected pages in your navigation

  Article optimized for CMSMS 2.x

  Author:
  Last tested in: CMSMS 2.2.19
  Last updated: 10-06-2019
  Comments: 1
  http://cms.ms/G0kb


Buy Me A Coffee




Advertisement


Ads help me to help you! Thanks!

Ads help me to help you! Buy products from these advertisers!