Forum for discussing general topics related to Couch.
2 posts Page 1 of 1
Hi, thanks to this thread
http://www.couchcms.com/forum/viewtopic.php?f=8&t=74
and documentation I've successfully set a multilingual site.
As mentioned in the post, a negative feature of the session variables method is that URL's are the same for both languages. I'm just curious if there's any way to have variable to go to language directories like "www.domain.com/en", "www.domain.com/fr" so to achieve better SEO results (guess Google will index only primary language). Probably somehow through .htacess? Any suggestions will be greatly appreciated.
Hi gali,

I perhaps can help you as I am working with multi lingual sites myself

here is something i use to switch languages

Code: Select all
<ul class="posabs ul" id="langselect">
               <li>
                  <a class="dispblock" <cms:if lang=='en'>id="langactive"<cms:else />href="<cms:show k_site_link />en/"</cms:if>>
                     <img class="dispiblock" src="<cms:show k_site_link />skin/image/thumbs/flag_en.png" alt="flag_en" />
                     English
                  </a>
               </li>
               <li>
                  <a class="dispblock" <cms:if lang=='nl'>id="langactive"<cms:else />href="<cms:show k_site_link />nl/"</cms:if>>
                     <img class="dispiblock" src="<cms:show k_site_link />skin/image/thumbs/flag_nl.png" alt="flag_nl" />
                     Nederlands
                  </a>
               </li>
            </ul>


And put this at the top of your template
Code: Select all
<cms:set lang='en' 'global' /> for english and <cms:set lang='fr' 'global' /> for french etc.


Hope its of help to you as it works for me the only downside is that it will always bring you to the root of the folder so you will always start at the homepage of the folder ergo the index.php or default.html . Make sure to go thru everyline of code and dont copy paste it just like this and expect it to work!


all the best!
2 posts Page 1 of 1