• twitter image
  • facebook image
  • youtube image
  • linkedin image
Language: CMS Made Simple Czech CMS Made Simple France CMS Made Simple Spain CMS Made Simple Hungary CMS Made Simple Russia CMS Made Simple Netherlands

All times are UTC




Post new topic Reply to topic  [ 131 posts ]  Go to page Previous  1, 2, 3, 4, 5, 6, 7 ... 9  Next
Author Message
 Post subject: Re: One more approach to build a multilingual site with the regular CMSMS
PostPosted: Thu May 22, 2008 7:36 pm 
Offline
Forum Members
Forum Members

Joined: Wed Apr 23, 2008 3:31 pm
Posts: 20
There is no difference with or without quotes.
always the same result :

other_languages=

other_language=

DEBUG:
language_codes=Array ( [0] => )
language_pages=Array ( [0] => )
language_versions=Array ( [] => )


Top
  Profile  
 
Share On:
Share on Facebook Share on Twitter Share on Google+
 Post subject: Re: One more approach to build a multilingual site with the regular CMSMS
PostPosted: Thu May 22, 2008 10:17 pm 
Offline
Forum Members
Forum Members
User avatar

Joined: Thu Jan 25, 2007 2:54 pm
Posts: 124
Location: España / Hispanujo / Spain
I thought something. I think the content block

\$1:
{content block='Other languages' oneline='true' assign='other_languages' wysiwyg='false'}


must be before {language_menu} in the template, because of the "assign" parameter. Check that.

_________________
Marcos Cruz


Top
  Profile  
 
Share On:
Share on Facebook Share on Twitter Share on Google+
 Post subject: Re: One more approach to build a multilingual site with the regular CMSMS
PostPosted: Fri May 23, 2008 6:44 am 
Offline
Forum Members
Forum Members

Joined: Wed Apr 23, 2008 3:31 pm
Posts: 20
YES !!!  ;D
it works well now!
thanks a lot of time dedicated to resolve my problem.
Just a last question:
I prefer using flags instead of the name of language, but how to have no flea located in front of the flag and so that it is not underlined?

I think i have found the solution alone  ;)
I just remove all line
        echo '
  • ';
            echo '
  • ';
          echo '
  • ';
          echo '
      ';
            echo '
    ';
    in language_menu
    for the underline I will modify my stylesheet...


  • Last edited by ZIGRIB on Fri May 23, 2008 8:24 am, edited 1 time in total.

    Top
      Profile  
     
    Share On:
    Share on Facebook Share on Twitter Share on Google+
     Post subject: Re: One more approach to build a multilingual site with the regular CMSMS
    PostPosted: Fri May 23, 2008 8:23 am 
    Offline
    Forum Members
    Forum Members
    User avatar

    Joined: Thu Jan 25, 2007 2:54 pm
    Posts: 124
    Location: España / Hispanujo / Spain
    ZIGRIB \ZIGRIB:
    it works well now!


    Good! Don't forget to comment out again all the interesting debug lines  ;)

    I changed the implementation guide to clearly explain this point.

    ZIGRIB \ZIGRIB:
    how to have no flea located in front of the flag and so that it is not underlined?


    That depends on the CSS (cascade style sheets). You said you use this code for the menu:

    \$1:
    <div id='langmenu'>{language_menu}</div>


    So just add the needed style commands to the stylesheet you associated with your template, e.g.:

    \$1:
    #langmenu ul {
        padding: 0;
        margin: 0;
        list-style: none; /* no fleas */
    }
    #langmenu ul li {
        margin:0.1em; /* gap between menu options */
    }
    #langmenu ul li a {
        text-decoration:none; /* no underline */
    }


    Some commands in that example are optional in your case. I took them, simplified, from a site of mine. If you are not  acquainted with CSS, I recommend you two sites: CSS Tutorial and Learning CSS.

    Good luck. Please post a link to your site when it's ready.

    _________________
    Marcos Cruz


    Last edited by alinome.net on Fri May 23, 2008 8:26 am, edited 1 time in total.

    Top
      Profile  
     
    Share On:
    Share on Facebook Share on Twitter Share on Google+
     Post subject: Re: One more approach to build a multilingual site with the regular CMSMS
    PostPosted: Fri May 23, 2008 8:29 am 
    Offline
    Forum Members
    Forum Members

    Joined: Wed Apr 23, 2008 3:31 pm
    Posts: 20
    Ok I think your solution is better
    Thanks for link I'll read it with attention.
    When the site will ready i'll post the link here.


    Top
      Profile  
     
    Share On:
    Share on Facebook Share on Twitter Share on Google+
     Post subject: Re: One more approach to build a multilingual site with the regular CMSMS
    PostPosted: Fri May 23, 2008 8:35 am 
    Offline
    Forum Members
    Forum Members
    User avatar

    Joined: Thu Jan 25, 2007 2:54 pm
    Posts: 124
    Location: España / Hispanujo / Spain
    ZIGRIB \ZIGRIB:
    I just remove all line
            echo '
  • ';
            echo '
  • ';
           echo '
  • ';
           echo '
      ';
             echo '
    ';
    in language_menu


  • Interesting solution :) Well, in your case it works fine because there's only two languages and the current one is not listed in the language menu... So in practice the "list" always has only one item, so you can delete all the list markup as you did. Nevertheless I prefer to use CSS for that kind of things and keep the XHTML untoched.

    _________________
    Marcos Cruz


    Top
      Profile  
     
    Share On:
    Share on Facebook Share on Twitter Share on Google+
     Post subject: Re: One more approach to build a multilingual site with the regular CMSMS
    PostPosted: Thu Aug 07, 2008 1:12 pm 
    Offline
    Forum Members
    Forum Members

    Joined: Thu Aug 07, 2008 1:07 pm
    Posts: 18
    Hi!

    I'm using your method for a bilingual site. I have two questions, though:

    1. I would like to put a delimiter between the language buttons in the menu. (I don't use the titles, only buttons.) Where in the code do I put it, so it only goes between the buttons, and not before the first item, or behind the last?

    2. What do I do when I add a photo album? There is no content block to add other languages there? Is this simply not supported, or something someone is working on?

    Thanks in advance!


    Top
      Profile  
     
    Share On:
    Share on Facebook Share on Twitter Share on Google+
     Post subject: Re: One more approach to build a multilingual site with the regular CMSMS
    PostPosted: Thu Aug 07, 2008 4:58 pm 
    Offline
    Forum Members
    Forum Members
    User avatar

    Joined: Thu Jan 25, 2007 2:54 pm
    Posts: 124
    Location: España / Hispanujo / Spain
    sirphuzz \sirphuzz:
    1. I would like to put a delimiter between the language buttons in the menu. (I don't use the titles, only buttons.) Where in the code do I put it, so it only goes between the buttons, and not before the first item, or behind the last?


    The solution by Karolis is good. But I always prefer to avoid "hard" delimiters in lists, because of usability. I suggest you to use CSS instead:

    \$1:
    #langmenu ul {
      margin: 0;
      padding: 0;
      display: inline;
      }
    #langmenu ul li {
      margin: 0;
      padding: 0 .5em 0 0;
      display: inline;
      list-style: none;
      }
    #langmenu ul li+li {
      padding-left: .5em;
      border-left: 1px solid grey; /* vertical line to separate buttons */
      }


    That's an example. The delimiter will be a vertical line you can configure. It will appear at the left of every button but the first. CSS provides ways to create any delimiter, text or image. This one is the simplest.

    sirphuzz \sirphuzz:
    2. What do I do when I add a photo album? There is no content block to add other languages there?


    I don't understand what you mean. I never used a photo album with CMSMS. I think you have to do the same: one album for every language, as regular pages. But if the photo descriptions are stored in the database then there's no easy way to make them bilingual. Is that your problem?

    Cheers,

    Marcos

    _________________
    Marcos Cruz


    Last edited by alinome.net on Thu Aug 07, 2008 5:00 pm, edited 1 time in total.

    Top
      Profile  
     
    Share On:
    Share on Facebook Share on Twitter Share on Google+
     Post subject: Re: One more approach to build a multilingual site with the regular CMSMS
    PostPosted: Thu Aug 07, 2008 10:27 pm 
    Offline
    Forum Members
    Forum Members

    Joined: Thu Aug 07, 2008 1:07 pm
    Posts: 18
    Hi!

    Thank you both for fast and good answers.

    Right now my site is in some kind of maintenence (thank you, one.com!) so I can't try your suggestions, but I'm pretty sure the delimiters will work, I also like to use css when possible.

    My second questions was how to make the other content types bilingual. Right now, I only get the content block to add other languages when I create a "Content" page.

    I worked around the photoalbum by creating a content page and then manually adding the cms_module tag for the album module. This worked fine, but now I wanted to add a catalog.

    So I created a category page, and a item page, and I can't make a content block for these types.

    I tried adding the content block tag to the category template, but it didn't work.

    What I want is to be able to create my category pages and item pages and use the same system to make them bilingual.

    Is there any way to add the correct code that assigns the "en=alias;sv=alias" string to the $other_languages variable, in these content types? Can it be placed in the metadata field?

    I would be really grateful if this could be made to work.


    Top
      Profile  
     
    Share On:
    Share on Facebook Share on Twitter Share on Google+
     Post subject: Re: One more approach to build a multilingual site with the regular CMSMS
    PostPosted: Fri Oct 10, 2008 3:14 pm 
    Offline
    Forum Members
    Forum Members

    Joined: Sun Oct 05, 2008 10:36 am
    Posts: 18
    HI, I just want to thank the developers that created this approach to multilingual sites. I started to implement it on my site and it works like charm. Thanks a lot guys!!!


    Top
      Profile  
     
    Share On:
    Share on Facebook Share on Twitter Share on Google+
     Post subject: Re: One more approach to build a multilingual site with the regular CMSMS
    PostPosted: Sat Oct 11, 2008 11:03 am 
    Offline
    Forum Members
    Forum Members
    User avatar

    Joined: Thu Jan 25, 2007 2:54 pm
    Posts: 124
    Location: España / Hispanujo / Spain
    danilski \danilski:
    HI, I just want to thank the developers that created this approach to multilingual sites. I started to implement it on my site and it works like charm. Thanks a lot guys!!!


    Happy that it's useful for you. Maybe you can post a link to your page after implementing it.

    Regards,

    Marcos

    _________________
    Marcos Cruz


    Top
      Profile  
     
    Share On:
    Share on Facebook Share on Twitter Share on Google+
     Post subject: Re: One more approach to build a multilingual site with the regular CMSMS
    PostPosted: Thu Oct 23, 2008 1:25 pm 
    Hi,

    thanks for nice little multilingual fix. Good job :-)
    I'm having one issue with an extra quote around my language links: LINK REMOVED

    How do i get rid of them?

    Cheers

    Jon


    Last edited by volcanoboy on Wed Nov 05, 2008 7:55 am, edited 1 time in total.

    Top
       
     
    Share On:
    Share on Facebook Share on Twitter Share on Google+
     Post subject: Re: One more approach to build a multilingual site with the regular CMSMS
    PostPosted: Thu Oct 23, 2008 8:56 pm 
    Offline
    Forum Members
    Forum Members
    User avatar

    Joined: Thu Jan 25, 2007 2:54 pm
    Posts: 124
    Location: España / Hispanujo / Spain
    volcanoboy \volcanoboy:
    I'm having one issue with an extra quote around my language links: [...]
    How do i get rid of them?


    It depends on why they appear [:-)]. This is your page's XHTML:

    \$1:
    <ul>
    <li><a href="http://www.handelshusetmartinsen.no/huvudsida-se" title="Huvudsida" hreflang='se'>'<img xml:lang='se' src='/uploads/images/sitePics/se.gif' alt='Svenska' />'</a></li>
    <li><a href="http://www.handelshusetmartinsen.no/home-en" title="Home" hreflang='en'>'<img xml:lang='en' src='/uploads/images/sitePics/gb.gif' alt='English' />'</a></li>
    </ul>


    The quotes are inside the links, outside the images. Please post the code you use to create your flag buttons (the $languages array definition) and I'll take a look. I suspect the quotes are there.

    Cheers,
    Marcos

    _________________
    Marcos Cruz


    Last edited by alinome.net on Wed Nov 05, 2008 8:55 am, edited 1 time in total.

    Top
      Profile  
     
    Share On:
    Share on Facebook Share on Twitter Share on Google+
     Post subject: Re: One more approach to build a multilingual site with the regular CMSMS
    PostPosted: Thu Oct 23, 2008 10:51 pm 
    Hi marcos,

    I copied the code from your example:


    \$1:
      $languages = array(
      "no" => array("Hovedside-no", "<img xml:lang='no' src='/uploads/images/sitePics/no.gif' alt='Norsk' />"),
      "se" => array("huvudsida-se", "<img xml:lang='se' src='/uploads/images/sitePics/se.gif' alt='Svenska' />"),
      "en" => array("home-en", "<img xml:lang='en' src='/uploads/images/sitePics/gb.gif' alt='English' />") );


    Top
       
     
    Share On:
    Share on Facebook Share on Twitter Share on Google+
     Post subject: Re: One more approach to build a multilingual site with the regular CMSMS
    PostPosted: Tue Oct 28, 2008 11:51 am 
    did you have a chance to look at my code?

    Cheers  :)


    Top
       
     
    Share On:
    Share on Facebook Share on Twitter Share on Google+
    Display posts from previous:  Sort by  
    Post new topic Reply to topic  [ 131 posts ]  Go to page Previous  1, 2, 3, 4, 5, 6, 7 ... 9  Next

    All times are UTC


    Who is online

    Users browsing this forum: No registered users


    You cannot post new topics in this forum
    You cannot reply to topics in this forum
    You cannot edit your posts in this forum
    You cannot delete your posts in this forum
    You cannot post attachments in this forum

    Search for:
    Jump to:  
    A2 Hosting