Do not show page in a language when DEFAULT_LANG checked

This is a FORK of the CMS Made Simple project and is not oficially supported in any way by the CMS Made Simple development team.
Locked
Dutch_guy
Forum Members
Forum Members
Posts: 64
Joined: Wed Apr 23, 2008 11:19 am

Do not show page in a language when DEFAULT_LANG checked

Post by Dutch_guy »

I have the following checked:

"Show from DEFAULT_LANG if current lang is not ready"

This works. But there is one page which I don't want to show in one language at all. However since the above setting is checked, it shows the content of the default language. Is there a way to override this for one page ?
Peciura

Re: Do not show page in a language when DEFAULT_LANG checked

Post by Peciura »

What do you want to display on that page ?
If you want to display empty page write

Code: Select all

{'&nbsp'};
in content text area.
Dutch_guy
Forum Members
Forum Members
Posts: 64
Joined: Wed Apr 23, 2008 11:19 am

Re: Do not show page in a language when DEFAULT_LANG checked

Post by Dutch_guy »

Well I also mean don't show it at all in the menu for that particular language.
Peciura

Re: Do not show page in a language when DEFAULT_LANG checked

Post by Peciura »

Post your menu template to forum.
Dutch_guy
Forum Members
Forum Members
Posts: 64
Joined: Wed Apr 23, 2008 11:19 am

Re: Do not show page in a language when DEFAULT_LANG checked

Post by Dutch_guy »

Hi,

Here my menu template: (it's based on cssmenu_ulshadow)

Code: Select all

{* CSS classes used in this template:
#menuwrapper - The id for the <div> that the menu is wrapped in. Sets the width, background etc. for the menu.
#primary-nav - The id for the <ul>
.menuparent - The class for each <li> that has children.
.menuactive - The class for each <li> that is active or is a parent (on any level) of a child that is active. *}
{if $count > 0}
<div id="menuwrapper">
<ul id="primary-nav">
{foreach from=$nodelist item=node}
{if $node->depth > $node->prevdepth}
{repeat string='<ul class="unli">' times=$node->depth-$node->prevdepth}
{elseif $node->depth < $node->prevdepth}
{repeat string='</li><li class="separator once" style="list-style-type: none;"> </li></ul>' times=$node->prevdepth-$node->depth}
</li>
{elseif $node->index > 0}</li>
{/if}
{if $node->parent == true or ($node->current == true and $node->haschildren == true)}
<li class="menuactive menuparent">
<a class="menuactive menuparent" {elseif $node->current == true}
<li class="menuactive">
<a class="menuactive" {elseif $node->haschildren == true}
<li class="menuparent">
<a class="menuparent" {elseif $node->type == 'sectionheader' and $node->haschildren == true}
<li class="sectionheader"><span class="sectionheader">{$node->menutext}</span> {elseif $node->type == 'separator'}
{* <li style="list-style-type: none;"> <hr class="menu_separator" /> *}{else}
<li>
<a {/if}
{if $node->type != 'sectionheader' and $node->type != 'separator'}
{if $node->target}target="{$node->target}" {/if}
href="{$node->url}"><span>{$node->menutext}</span></a>
{elseif $node->type == 'sectionheader'}
><span class="sectionheader">{$node->menutext}</span></a>
{/if}
{/foreach}
{repeat string='</li><li class="separator once" style="list-style-type: none;"> </li></ul>' times=$node->depth-1}
</li>
</ul>
<div class="clearb"></div>
</div>
{/if}
Peciura

Re: Do not show page in a language when DEFAULT_LANG checked

Post by Peciura »

Try this template. You have to specify what language and page id should be skipped.
{* CSS classes used in this template:
#menuwrapper - The id for the that the menu is wrapped in. Sets the width, background etc. for the menu.
#primary-nav - The id for the
.menuparent - The class for each that has children.
.menuactive - The class for each that is active or is a parent (on any level) of a child that is active. *}
{if $count > 0}


{foreach from=$nodelist item=node}
{if $lang != 'en_US' || $node->id != '66'}  {*exclude single page*}
{if $node->depth > $node->prevdepth}
{repeat string='' times=$node->depth-$node->prevdepth}
{elseif $node->depth prevdepth}
{repeat string=' ' times=$node->prevdepth-$node->depth}

{elseif $node->index > 0}
{/if}
{if $node->parent == true or ($node->current == true and $node->haschildren == true)}

current == true}

haschildren == true}

type == 'sectionheader' and $node->haschildren == true}
{$node->menutext} {elseif $node->type == 'separator'}
{* *}{else}

type != 'sectionheader' and $node->type != 'separator'}
{if $node->target}target="{$node->target}" {/if}
href="{$node->url}">{$node->menutext}
{elseif $node->type == 'sectionheader'}
>{$node->menutext}
{/if}
{/if} {*END exclude single page*}
{/foreach}
{repeat string=' ' times=$node->depth-1}




{/if}
Locked

Return to “[locked] CMSMS MLE fork”