We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 17895
    • 209 Posts
    Hi all,
    I am "yet-another-multi-language-content guy", and I am developing my own solution for this issue.

    I want the website to have a default language and the visitor to choose a preferred language. He will browse the site in the preferred language, if some page has not the translation in that preferred language, the site shows the page in the default language (without "switching" to that default language!)

    I added two fields in the site_content db table: contentLang (for example "it", "en", etc.) and refId (that refers to the id of the same page in the default language... that page has refId NULL)

    I made some change in the manager, because I want the translation pages to be showed in the website tree (next to the page title). I also show the language field in the document/folder details.

    Is all clear and ok until here? smiley

    I have a snippet to show all languages available FOR THE CURRENT PAGE.

    I have a plug-in that redirect the browser to the default-language page if the one in the preferred language is not available (the same plug-in parses and redirect if the user changes the preferred language)

    Now I need:
    1) to have something to decide which one is the default language of the content (maybe in the general settings?)
    2) to add and remove languages (where?)
    3) to have a button in the edit content page that duplicates the page to be translated in another language (I would like to use the duplicate processor, but it duplicates also the children, and I do not want this... I also need to set the contentLang field)... I think to get the processor code and modify it to fit my needs
    4) to have another plug-in that, for each add/delete of a page, rebuilds the tree accordingly (each page in language A have to have a page of the same language A, as parent, if available)... which plug-in event should I have to use?

    what else?
      Daniele "MadMage" Calisi
      • 32241
      • 1,495 Posts
      Nice,

      It seems that you came up with a pretty daring idea. Sorry, I’m not a core coder, but I just want to wish you all the best for implementing your idea.

      Keep it up...
        Wendy Novianto
        [font=Verdana]PT DJAMOER Technology Media
        [font=Verdana]Xituz Media
        • 32241
        • 1,495 Posts
        Hey, I found this on the new features of MODx in v 0.9.1


        * QuickEdit: Added multi-lingual support

        You might wanna check that out.
        I’m testing it right now.

          Wendy Novianto
          [font=Verdana]PT DJAMOER Technology Media
          [font=Verdana]Xituz Media