Uploaded image for project: 'LAMS Development'
  1. LAMS Development
  2. LDEV-2599

FCKEditor connector not being able to handle utf-8 filenames for uploads

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 2.3.4
    • Fix Version/s: 2.4, 2.3.5
    • Component/s: General
    • Labels:
      None

      Description

      Spyros Papadakis reports on the LAMS Community:

      "If you upload an image with utf8 characters on its name you can see it but when you try to use it you can not." (see picture)

      This happens with the FCKEditor connector when trying to upload pictures that contain UTF-8 character (Greek, Russian, etc). I believe this might be because the FCKEditor connector isn't encoding the file info appropriately.

        Activity

        ernieg Ernie Ghiglione created issue -
        Hide
        ernieg Ernie Ghiglione added a comment -
        (image from Spyros posting http://is.gd/gP04p)
        Show
        ernieg Ernie Ghiglione added a comment - (image from Spyros posting http://is.gd/gP04p)
        ernieg Ernie Ghiglione made changes -
        Field Original Value New Value
        Attachment EFCKEditor+folder+name+with+utf8+chars.jpeg [ 12002 ]
        Hide
        dronych Andrey Balan added a comment -
        fixed

        there were also lots of errors with encoding of folder names.
        although it seems to be working all right now. (tested both for IE and FF)

        and it might be a good idea to test it on another platforms as well (e.g. linux server, client coming from windows)

        Show
        dronych Andrey Balan added a comment - fixed there were also lots of errors with encoding of folder names. although it seems to be working all right now. (tested both for IE and FF) and it might be a good idea to test it on another platforms as well (e.g. linux server, client coming from windows)
        dronych Andrey Balan made changes -
        Status Open [ 1 ] Resolved [ 5 ]
        Fix Version/s 2.4 [ 10110 ]
        Resolution Fixed [ 1 ]
        Hide
        dronych Andrey Balan added a comment -
        and i don't commit it to HEAD as we have CKEditor there now (and not the FCK one)
        Show
        dronych Andrey Balan added a comment - and i don't commit it to HEAD as we have CKEditor there now (and not the FCK one)
        Hide
        ernieg Ernie Ghiglione added a comment -
        Hi Andrey, I attempt to use the attached image (see the one with the greek name on it) to see if that would work but it fails.
        Show
        ernieg Ernie Ghiglione added a comment - Hi Andrey, I attempt to use the attached image (see the one with the greek name on it) to see if that would work but it fails.
        ernieg Ernie Ghiglione made changes -
        Resolution Fixed [ 1 ]
        Status Resolved [ 5 ] Reopened [ 4 ]
        ernieg Ernie Ghiglione made changes -
        Attachment Φόρτωση.png [ 12004 ]
        Hide
        dronych Andrey Balan added a comment -
        thanks Ernie

        I've fixed that issue
        Show
        dronych Andrey Balan added a comment - thanks Ernie I've fixed that issue
        dronych Andrey Balan made changes -
        Status Reopened [ 4 ] Resolved [ 5 ]
        Resolution Fixed [ 1 ]
        Hide
        ernieg Ernie Ghiglione added a comment -
        Also, say you have the following file Φόρτωση.gif in lams.ear/lams-www.war/secure/ff8081812c297cb1012c2a0662c4001b/Image

        When trying to access it via web like:

        /lams//www/secure/ff8081812c297cb1012c2a0662c4001b/Image/%CE%A6%CF%8C%CF%81%CF%84%CF%89%CF%83%CE%B7.gif (urlencoded name)

        or

        /lams//www/secure/ff8081812c297cb1012c2a0662c4001b/Image/Φόρτωση.gif

        it automatically sends me to 404.

        Show
        ernieg Ernie Ghiglione added a comment - Also, say you have the following file Φόρτωση.gif in lams.ear/lams- www.war/secure/ff8081812c297cb1012c2a0662c4001b/Image When trying to access it via web like: /lams//www/secure/ff8081812c297cb1012c2a0662c4001b/Image/%CE%A6%CF%8C%CF%81%CF%84%CF%89%CF%83%CE%B7.gif (urlencoded name) or /lams//www/secure/ff8081812c297cb1012c2a0662c4001b/Image/Φόρτωση.gif it automatically sends me to 404.
        Hide
        ernieg Ernie Ghiglione added a comment -
        Andrey, I can't seem to make this work. I also compile this in Windows and I get the same result as with Unix. (see my last comment).

        Are you able to upload a picture with greek characters and then add them to the fckeditor as image?
        Show
        ernieg Ernie Ghiglione added a comment - Andrey, I can't seem to make this work. I also compile this in Windows and I get the same result as with Unix. (see my last comment). Are you able to upload a picture with greek characters and then add them to the fckeditor as image?
        ernieg Ernie Ghiglione made changes -
        Resolution Fixed [ 1 ]
        Status Resolved [ 5 ] Reopened [ 4 ]
        Hide
        dronych Andrey Balan added a comment -
        yep, i'm able to upload and add image with greek filename to fckeditor.
        Although I get the error once I try to access it later at /lams//www/secure/ff8081812c297cb1012c2a0662c4001b/Image/......
        Show
        dronych Andrey Balan added a comment - yep, i'm able to upload and add image with greek filename to fckeditor. Although I get the error once I try to access it later at /lams//www/secure/ff8081812c297cb1012c2a0662c4001b/Image/......
        Hide
        ernieg Ernie Ghiglione added a comment -
        is that because we filter calls to the "secure" folder?
        Show
        ernieg Ernie Ghiglione added a comment - is that because we filter calls to the "secure" folder?
        Hide
        ernieg Ernie Ghiglione added a comment -
        From:Andrey

        "yep, I can confirm the problem exists for all other applications deployed under the jboss

        and it seems i might have found the solution to that:
        we need to add the URIEncoding="UTF-8" attribute to the connector configuration.
        change ${JBOSS_HOME}/server/(default)/deploy/jbossweb-tomcat55.sar/server.xml:
        <Connector port="8080" URIEncoding="UTF-8"...
        (as it's advised here http://docs.jboss.org/seam/2.0.3.CR1/reference/en-US/html/i18n.html)

        and it works ok after doing this.

        another question is how to implement this in Lams.
        don't know if we could modify server.xml during lams deployment,
        but we could at least tell people to change that file if they're going to use UTF-8 filenames
        "
        Show
        ernieg Ernie Ghiglione added a comment - From:Andrey "yep, I can confirm the problem exists for all other applications deployed under the jboss and it seems i might have found the solution to that: we need to add the URIEncoding="UTF-8" attribute to the connector configuration. change ${JBOSS_HOME}/server/(default)/deploy/jbossweb-tomcat55.sar/server.xml: <Connector port="8080" URIEncoding="UTF-8"... (as it's advised here http://docs.jboss.org/seam/2.0.3.CR1/reference/en-US/html/i18n.html) and it works ok after doing this. another question is how to implement this in Lams. don't know if we could modify server.xml during lams deployment, but we could at least tell people to change that file if they're going to use UTF-8 filenames "
        Hide
        ernieg Ernie Ghiglione added a comment -
        Tested and closed for 2.3.4 and 2.4.

        This will be fine for new installations but for existing installations changes would have to be done manually by the system administrator. We will include this in the Release Notes.
        Show
        ernieg Ernie Ghiglione added a comment - Tested and closed for 2.3.4 and 2.4. This will be fine for new installations but for existing installations changes would have to be done manually by the system administrator. We will include this in the Release Notes.
        ernieg Ernie Ghiglione made changes -
        Status Reopened [ 4 ] Resolved [ 5 ]
        Fix Version/s 2.4 [ 10110 ]
        Resolution Fixed [ 1 ]
        ernieg Ernie Ghiglione made changes -
        Status Resolved [ 5 ] Closed [ 6 ]

          People

          • Assignee:
            dronych Andrey Balan
            Reporter:
            ernieg Ernie Ghiglione
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development