cmsms-mle-1.0.2: hiding empty content [solved]

Have a question or a suggestion about a 3rd party addon module or plugin?
Let us know here.
Post Reply
dennis05
Forum Members
Forum Members
Posts: 15
Joined: Tue Oct 24, 2006 4:26 pm

cmsms-mle-1.0.2: hiding empty content [solved]

Post by dennis05 »

Hey folks,

how can I get rid of a empty (non translated) content page? i.e. I have a page only available in one language (eg english) (while having 2 language support). If I choose German, a entry of the untranslated page appears in the menu and is clickable, however with an empty string. But you can still see that it's there. Is there a way to hide it completely?

However, hiding the page doesn't work. cmsms refuses to do so since page title, ... are empty. hiding the english page doesn't make sense.

take care
Added: [solved]
Last edited by Anonymous on Fri Mar 02, 2007 8:02 pm, edited 1 time in total.
cyberman

Re: cmsms-mle-1.0.2: hiding empty content

Post by cyberman »

Have you tried to modify template and hide {lan} tag if second language content is empty?
dennis05
Forum Members
Forum Members
Posts: 15
Joined: Tue Oct 24, 2006 4:26 pm

Re: cmsms-mle-1.0.2: hiding empty content

Post by dennis05 »

That doesn't help. It hides the buttons to chose the language, right?

Imagine, I have 3 pages (A, B, C) where all three are translated both to German and English. Page D is ONLY available in English. The German "translation" of D is empty.

Viewing the page in English gives the menu: A,B,C,D
viewing the page in German gives the menu: A,B,C, {empty link to D which has no text but is still visible and clickable}


In turn, is it possible to fall back to the default language if content is empty? With fallback, I mean not to change the language in general, but only for the missing page once.
dennis05
Forum Members
Forum Members
Posts: 15
Joined: Tue Oct 24, 2006 4:26 pm

Re: cmsms-mle-1.0.2: hiding empty content

Post by dennis05 »

re,

while browsing through the source, I got it working by adding ... after $lan is initialized in LoadFromData() in class.content.inc.php: (which was line 860 in cmsms-mle-1.0.2

if(strlen($data["menu_text$lan"]) == 0)
return false;
Post Reply

Return to “Modules/Add-Ons”