On March 26, 2019 we launched new MODX Forums. Please join us at the new MODX Community Forums.
Subscribe: RSS
  • EDIT: it was problems with the language file charset






    Hi!

    Im using utf8 as charset...

    I tried editing a template and saving it, then open it and all the extended characters are broken (so, utf8 is lost)
    then I have seen the code of that frame and it is using iso8859-1... that is the problem?
    all the information saved with the RTE will be saved as iso8859-1 instead the charset you have select/you are using in your system/browser?



    • Check the site configuration (Tools -> Configuration) and make sure that is set to use utf-8.
        Studying MODX in the desert - http://sottwell.com
        Tips and Tricks from the MODX Forums and Slack Channels - http://modxcookbook.com
        Join the Slack Community - http://modx.org
      • yep, its utf8 there...

        the hard code <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" /> is in source_editor.html aparently, maybe in other files too...

        btw, I was wrong... it is not RTE, templates are not edited using the RTE....
        • Well, that’s odd, because those frames all get the charset from the config array. Hmm. Check your assets/cache/siteCache.idx.php file; do a search for $c[’modx_charset’] (should be around line cool
          $c['modx_charset'] = "UTF-8";

            Studying MODX in the desert - http://sottwell.com
            Tips and Tricks from the MODX Forums and Slack Channels - http://modxcookbook.com
            Join the Slack Community - http://modx.org
          • yep, it is there...
            but the line I post up there is hard coded... I see it in the file

            oh, btw2, it not looks like a RTE, but it is a tinymce editor...

            there are other files with that line too, tinymce related
            • That’s what has me puzzled; TinyMCE has nothing at all to do with template editing.
                Studying MODX in the desert - http://sottwell.com
                Tips and Tricks from the MODX Forums and Slack Channels - http://modxcookbook.com
                Join the Slack Community - http://modx.org
              • are you sure?

                I saw that code frame, and iso8859-1 code was there...

                then I searched the files and saw it there...

                it cames from somewhere
                • oks, yep... I have added some code to that file to see if it apears, and nothing...

                  I have no idea where is coming that iso8859-1...

                  Im going to download the whole site, and database... to look it better...
                  • The character set used in the Manager is now specified in the relevant language files. In the Spanish language file (which I’m assuming you’re using), the specified character set is:
                    $modx_manager_charset = 'iso-8859-1';

                    I suspect that’s the root of your problems smiley I also suspect that the tinyMCE source_editor.htm is not actually utilized by MODx, but just comes as part of the stock tinyMCE distribution that we use.
                      Garry Nutting
                      Senior Developer
                      MODX, LLC

                      Email: support@modx.com
                      Twitter: @garryn
                      Web: modx.com
                    • yep, I saw that in the language files, prior install it...
                      so I changed install and core spanish files to utf8
                      and changed that line to $modx_manager_charset = ’UTF-8’;

                      but.... there is always a but... I forgot to upload it!!!!

                      LOL

                      :(