Problem with CMS ML

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
hypnootik
Forum Members
Forum Members
Posts: 16
Joined: Tue Oct 09, 2007 12:26 pm

Problem with CMS ML

Post by hypnootik »

Hi

I have just installed the cms multilingual version. I have two languages. Estonian and English

Everything seems fine but... the pull down menu (cssmenu) shows all the menu items in both languages. Even those that are set only in one language.

If I create new page and fill only the english content then its displayed also in Estonian leaving the link text empty but clickable(link directs to same page on english version).

As I understand. The menumanager loads all the pages to array(witch is looped in menu template) without checking respondence to active/selected language

Help needed solving this problem.

Sorry or my poor english.

Best regards,
hypnootik
Last edited by hypnootik on Thu Nov 22, 2007 12:27 pm, edited 1 time in total.
alby

Re: Mone problem with CMS ML

Post by alby »

hypnootik wrote: I have just installed the cms multilingual version. I have two languages. Estonian and English

Everything seems fine but... the pull down menu (cssmenu) shows all the menu items in both languages. Even those that are set only in one language.

If I create new page and fill only the english content then its displayed also in Estonian leaving the link text empty but clickable(link directs to same page on english version).

As I understand. The menumanager loads all the pages to array(witch is looped in menu template) without checking respondence to active/selected language
I suppose that you say MLE edition.
Yes, MenuManager loads all pages but, if true that you say, loads "double" all pages because the SELECT all pages load or one language only or none.

I think you have a wrong db or you have a problem with your MenuManager template.
Try with simple_navigation template if you have same problem.

I publish a video tutorial for MLE install very soon

Alby
hypnootik
Forum Members
Forum Members
Posts: 16
Joined: Tue Oct 09, 2007 12:26 pm

Re: Problem with CMS ML

Post by hypnootik »

Hi

have the same kind of proble with News module.

When News is selected as Content type it allows to add also news category.

But THE SAME CATEGORY VALUE is set for both languages.

So both, Estonian and English readers can see the same category(no matter what language is selected)  :(
hypnootik
Forum Members
Forum Members
Posts: 16
Joined: Tue Oct 09, 2007 12:26 pm

Re: Problem with CMS ML

Post by hypnootik »

This is the template I'm useing

Code: Select all

{foreach from=$nodelist item=node}
{if $node->depth > $node->prevdepth}

	{repeat string="<ul>" times=$node->depth-$node->prevdepth}
{elseif $node->depth < $node->prevdepth}

	{repeat string="</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'}
        <li class="sectionheader"><a class="sectionheader" 
{elseif $node->type == 'separator'}
        <li style="list-style-type: none;"> <hr class="separator" />
{else}
	<li><a 
{/if}
{if $node->type != 'sectionheader' and $node->type != 'separator'}
href="{$node->url}" {if $node->accesskey != ''}accesskey="{$node->accesskey}" {/if}{if $node->tabindex != ''}tabindex="{$node->tabindex}" {/if}{if $node->titleattribute != ''}title="{$node->titleattribute}"{/if}{if $node->target ne ""} target="{$node->target}"{/if}><dfn>{$node->hierarchy}: </dfn>{$node->menutext}</a>
{elseif $node->type == 'sectionheader'}
><dfn>{$node->hierarchy}: </dfn>{$node->menutext}</a>
{/if}
{/foreach}
	{repeat string="</li></ul>" times=$node->depth-1}		</li>
	</ul>
<div class="clearb"></div>
</div>
{/if}
alby

Re: Problem with CMS ML

Post by alby »

hypnootik wrote: have the same kind of proble with News module.

When News is selected as Content type it allows to add also news category.

But THE SAME CATEGORY VALUE is set for both languages.

So both, Estonian and English readers can see the same category(no matter what language is selected)  :(
Warning: News Content type is deprecated and removed in next CMSMS release
You have a broken db.
Follow this post

Alby
hypnootik
Forum Members
Forum Members
Posts: 16
Joined: Tue Oct 09, 2007 12:26 pm

Re: Problem with CMS ML

Post by hypnootik »

But is is a fresh CMS ML installation!!!
Followed the "Mini Howto MLE - Installation/Upgrade"

And there have appeared no database errors.!
alby

Re: Problem with CMS ML

Post by alby »

hypnootik wrote: But is is a fresh CMS ML installation!!!
Followed the "Mini Howto MLE - Installation/Upgrade"

And there have appeared no database errors.!
Follow this (#2) - is for 4 languages but reduce to en_US and et_EE (I think?)

Alby
alby

Re: Problem with CMS ML

Post by alby »

hypnootik wrote: If I create new page and fill only the english content then its displayed also in Estonian leaving the link text empty but clickable(link directs to same page on english version).
Ok, I understand now (late but arrive  ;D)
You must apply this for hide orphan menu items  ;)

Alby
hypnootik
Forum Members
Forum Members
Posts: 16
Joined: Tue Oct 09, 2007 12:26 pm

Re: Problem with CMS ML

Post by hypnootik »

Hi


Thank You very much for the visual tutorials. Great material.

I also tried the  "{if !empty($node->menutext)}" trick earlyer already but the menu just got messed up :(

Can You help me to place this in my template. (posted it earlyer)


Thaks again :)
alby

Re: Problem with CMS ML

Post by alby »

hypnootik wrote:

.........
THERE IS A MISSING PART HERE
.........

{foreach from=$nodelist item=node}
{if !empty($node->menutext)}
{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'}
        type == 'separator'}
       
{else}
type != 'sectionheader' and $node->type != 'separator'}
href="{$node->url}" {if $node->accesskey != ''}accesskey="{$node->accesskey}" {/if}{if $node->tabindex != ''}tabindex="{$node->tabindex}" {/if}{if $node->titleattribute != ''}title="{$node->titleattribute}"{/if}{if $node->target ne ""} target="{$node->target}"{/if}>{$node->hierarchy}: {$node->menutext}
{elseif $node->type == 'sectionheader'}
>{$node->hierarchy}: {$node->menutext}
{/if}
{/if}
{/foreach}
{repeat string="" times=$node->depth-1}



{/if}
Check your code because is missing a start part (minimum )
View this

Alby
Last edited by alby on Mon Nov 26, 2007 8:00 am, edited 1 time in total.
hypnootik
Forum Members
Forum Members
Posts: 16
Joined: Tue Oct 09, 2007 12:26 pm

Re: Problem with CMS ML

Post by hypnootik »

The code I left uncopyed

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">

My menu

pages              1                   2                  3                  4                     5

EN           menuitem 1     menuitem 2                        menuitem3       menuitem4     
EST         menuitem 1                        menuitem2      menuitem3       menuitem4     

All menuitems have submenus.
If I use example given above - the itmes on est are skipped after empty menu item.

So it displays menu only as:    "menuitem1"
Last edited by hypnootik on Tue Nov 27, 2007 12:51 pm, edited 1 time in total.
Post Reply

Return to “CMSMS Core”