Show or hide links on specific circumstances

For questions and problems with the CMS core. This board is NOT for any 3rd party modules, addons, PHP scripts or anything NOT distributed with the CMS made simple package itself.
Post Reply
korisnik
New Member
New Member
Posts: 4
Joined: Sun Aug 25, 2013 11:47 am

Show or hide links on specific circumstances

Post by korisnik »

I created few pages. I would like hide links that points to specific pages.
My site is in English, but sometimes I publish article in Croatian. I could use geo IP locator to locate where is visitor from. But how to hide links that points to Croatian pages if visitor is not from Croatia.
User avatar
Dr.CSS
Moderator
Moderator
Posts: 12711
Joined: Thu Mar 09, 2006 5:32 am

Re: Show or hide links on specific circumstances

Post by Dr.CSS »

Sounds like you don't want them in the menu, in the Options tab there is check box for this, also at the bottom right is a select with 'Hide from menu' that works with the check box at the right of each page in content > pages...
User avatar
velden
Dev Team Member
Dev Team Member
Posts: 3497
Joined: Mon Nov 28, 2011 9:29 am

Re: Show or hide links on specific circumstances

Post by velden »

Hiding specific items from the menu can be done via the parameter:
(optional) excludeprefix="" - Exclude all items (and their children) who's page alias matches one of the specified (comma separated) prefixes. This parameter must not be used in conjunction with the includeprefix parameter.
Maybe you can use that in conjunction with the {browser_lang} tag (Extensions -> tags)

However, that would be for the menu only, not for other links in your page. You could of course make all your other links conditional by putting them inside {if some_language_condition} {/if} tags.
korisnik
New Member
New Member
Posts: 4
Joined: Sun Aug 25, 2013 11:47 am

Re: Show or hide links on specific circumstances

Post by korisnik »

Thank you, that will be very useful to me
Post Reply

Return to “CMSMS Core”