We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 5727
    • 160 Posts
    This is an auto-generated support/comment thread for TransliterateAlias.

    Use this forum to post any comments about this addition or any questions you have regarding its use.

    Brief Description:
    TransliterateAlias is a plug-in that applies transliteration to your document’s alias. It uses a new document manager event that was added in modx 0.9.6.3, therefore it is only meant to be used from that version on.

    How to install - Instructions
    • Extract the archive and upload it to your /assets/plugins/ directory.
    • Open the file ’transalias.plugin.php’ with your favorite text editor. Copy and paste the content of the file into a new plugin. Name it "TransAlias" and give it a description of "Transliterate document alias".
    • Under the "System Events" tab, check the Documents -> "OnStripAlias" event.
    • Save.

    If you are not satisfied with the transliteration provided by default, you can change it in two different way.

    The first method is to modify the file "common.php" located in the "transliterations" folder of the plug-in.

    The second method is to duplicate and modify the file "common.php" and give it a relevant name of yours. Then in the configuration tab of the plug-in, add the following configuration:

    &table_name=Table Name;text;common



    Click on "Update Parameter Display" to display a text field containing the name of the file (without the php extension). You should change this to the name of your file (without the extension) and click "Save".

      Olivier Deland
      Montreal, Canada - Web Developer
      • 7231
      • 4,205 Posts
      I had to look up transliteration. rolleyes

      From a linguistic point of view, transliteration is a mapping from one system of writing into another, word by word, or ideally letter by letter.

      So does this plug-in allow you to use accents in aliases?
        [font=Verdana]Shane Sponagle | [wiki] Snippet Call Anatomy | MODx Developer Blog | [nettuts] Working With a Content Management Framework: MODx

        Something is happening here, but you don't know what it is.
        Do you, Mr. Jones? - [bob dylan]
        • 5727
        • 160 Posts
        Quote from: dev_cw at Jan 20, 2009, 11:40 AM

        I had to look up transliteration.  rolleyes

        Indeed! Thanks for pointing out, I should probably add this in the first post to clarify.

        Quote from: dev_cw at Jan 20, 2009, 11:40 AM

        So does this plug-in allow you to use accents in aliases?

        The plug-in will convert accented characters to an ASCII equivalent, so "é" will become "e". The problem is that a valid URL cannot contain accented characters. Before 0.9.6.3, modx was using a basic conversion table (like é => e) that we decided to move out of the core and into a plug-in. A new event called ’onStripAlias’ was added to allow developers to tweak the creation of alias.

        You can open the file called ’common.php’ inside the ’transliterations’ folder to see the conversion going on. I encourage people out there to come up with other transliterations table and send them to me or submit them as "Extras". For exemple, a russian transliteration would convert "русский язык" to "russkiy yazyk"
          Olivier Deland
          Montreal, Canada - Web Developer
          • 25663 MODX Staff
          • 12,272 Posts
          Very nice and thank you. Very much needed. smiley
            Ryan Thrash, MODX Co-Founder
            Follow me on Twitter at @rthrash or catch my occasional unofficial thoughts at thrash.me
            • 22772
            • 2 Posts
            I can’t find the OnStripAlias event... Neither on the System Events tab nor in the source code of MODx 0.9.6.3. Am I missing something crucial? Just dowloaded the default installation pack from the front page.