Jump to content

LanguageLocalizeUrl - current class


wishbone
 Share

Recommended Posts

I managed to get the LLU to work, to change the linktext - but I'm lost how to assign the current language the class "current"...

<li class="current"><a$class href='$page->url'>$gateway->LangLinkName</a></li> of course, outputs all links with class="current"...

Link to comment
Share on other sites

ah thx you updated it ? Got it! I actually did use it sry I was not clear. Only I didn't understand the part with the current class - now works! Great thnks, as always!

Yeah a couple days ago. Glad you got it working.

  • Like 1
Link to comment
Share on other sites

now, I want the headline to be the same on every page (Name of company).

No problem using $page->set("field", $value)

But how to put the other languages?

I'm not sure I understand completely. How is the headline (field?) the company name? This is usuall the alternative title on a page.

The languages are set/taken automaticly depending what url you you access the user langauge will be set and if entered it will take that language if it is a language field. If language value is empty it will get default language.

Link to comment
Share on other sites

I'm not sure I understand completely. How is the headline (field?) the company name? This is usuall the alternative title on a page.

sry I wasn't clear. i created a new field, "company", which appears on every page and should have always the same value.

Without language fields this would be no problem by setting the company's name as the value $page->set("company", $value).

But how to set the value for the other languages?

New language problem. I want to link certain global menu items to specific pages like so:

<li><a href="<?php echo $pages->get(1051) ?>">Kontakt</a></li>

gives me 404 error... url shown is http://localhost/company/tr/1051

Link to comment
Share on other sites

It's got different name in different languages...

last suggestion works!!

Now Im still confused even more. You say it should always have the same value but still different for each language. My last suggestion works with what? :-)

  • Like 1
Link to comment
Share on other sites

Now Im still confused even more. You say it should always have the same value but still different for each language. My last suggestion works with what? :-)

one same value across pages for each language.

As "company" is a textLanguage field, I filled in the values on the home page, and your suggestion works... sry ;-)))))))

This has nothing to do with languages anyway.. Your code is missing the ..->url at the end.

omg ... still a lot to learn... thx for private lessons!!!

But after one month, I have now almost everything together for a small site with nice gimmicks. When finished I'll write a short report, maybe encourages other users with little coding expirience to use this smart CMS!!!

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...