We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 16901
    • 35 Posts
    I’m having some problems with the FCKEditor. When logged into MODx, I can’t upload images when editing the content of a page. When I click on the "Insert/edit Image" button in the TinyMCE toolbar, I get the pop-up window that allows you to add/edit an image. When I click on the "Browse" button (next to the Image URL field) I’m taken to the FCKEditor Resources Browser window. When I try and upload an image I get the following message:

    Error, "Failed to upload file, internal error..."

    When I try and create a new folder, I get the following message:

    You have no permissions to create the folder.

    I’ve tried uploading image manually (via an FTP client) to /assets/media/ and that works fine. But my client needs to be able to use the TinyMCE/FCK Editor to upload the images.

    I’ve changed the permissions for /assets/ and /assets/media/ to 777 but that doesn’t seem to make a difference.

    Here are my stats, as requested. I don’t have all of this info at my fingertips, but I’ve requested the missing info from MediaTemple and I will update it here as soon as they get back to me.


    Web Server:
    • PHP version - 5
    • and how it’s running (suexec, mod_php, CGI, etc.) - no idea
    • Apache or IIS version - no idea
    • Operating System and version - no idea

    Database:
    • MySQL version - 4.1.25-Debian_mt1-log (not sure if I’ve got the right info here.)
    • List of any tables over 1MB in size - none

    MODx:
    • Version - 0.9.6.1p2
    • Any changes you’ve made - no changes to MODx, but I’ve added a bunch of snippets & chunks
    • Any snippets you’re running on the page that is not working properly - N/A
    • Any plugins you’re running - FCKEditor (2.6.3), QuickEdit, TinyMCE (2.1.2)

    Browser/Client:
    • Browser name and version - problems are happening across the board: FFox3, Safari3 (OS X 10.5) and FFox3, IE7, IE6 (PC - WinXP SP2)

    Thanks in advance for any suggestions you might have as to how I can get this working.

    Cheers!

      • 33982 ☆ A M B ☆
      • 476 Posts
      I’ve changed the permissions for /assets/ and /assets/media/ to 777 but that doesn’t seem to make a difference.
      Images should upload to assets/images (unless you changed the file path to "media"). If you didn’t change the file path to "media", then make sure the "images" directory is 777. Also, what is your maximum upload size on the server and what is the size of the image you’re uploading? Sometimes if the image is too large (or an incorrect file type), you will get that message (Error, "Failed to upload file, internal error..."). The default max upload size in MODx is "1048576" or 1.04 MB... is your image larger than that? You can change the Max Upload size in Tools >> Configuration >> File Manager >> Maximum upload size. Sometimes even when you change this, your server may have a max upload size set by the hosting company (which you can see in Reports >> System Info >> phpinfo() and click on "View"

      Hope that helps.

      Also if you type in "Failed to upload file, internal error..." above in the search, you’ll see many other incidents of this occurring (i.e. http://modxcms.com/forums/index.php/topic,27167.msg165242.html#msg165242). I used to run into this problem all the time, but it always comes down to have the correct permissions on my server and checking the issues I mentioned above. Good luck!
        Precision Web Development ... SmashStack.com
        • 16901
        • 35 Posts

        Images should upload to assets/images (unless you changed the file path to "media").  If you didn’t change the file path to "media", then make sure the "images" directory is 777.
        I double checked - the permissions for assets/images was set at 777.

        Also, what is your maximum upload size on the server and what is the size of the image you’re uploading?  Sometimes if the image is too large (or an incorrect file type), you will get that message (Error, "Failed to upload file, internal error...").  The default max upload size in MODx is "1048576" or 1.04 MB... is your image larger than that?  You can change the Max Upload size in Tools >> Configuration >> File Manager >> Maximum upload size.  Sometimes even when you change this, your server may have a max upload size set by the hosting company (which you can see in Reports >> System Info >> phpinfo() and click on "View"

        The image I was testing with was 8kb... pretty sure that wasn’t the problem.  I checked the default max upload site in MODx and it’s set to 1.04MB as you predicted.

        Hope that helps.

        I wish it had smiley

        Also if you type in "Failed to upload file, internal error..." above in the search, you’ll see many other incidents of this occurring (i.e. http://modxcms.com/forums/index.php/topic,27167.msg165242.html#msg165242).  I used to run into this problem all the time, but it always comes down to have the correct permissions on my server and checking the issues I mentioned above.  Good luck!

        I tried that and have been tinkering around with the suggestions I’ve found in those threads.  But so far no luck.  Any other thoughts?
          • 33982 ☆ A M B ☆
          • 476 Posts
          One other question...what type of image is it? If I remember correctly, in the past I think I had problems uploading images named "image.JPG" versus having just "image.jpg" ... if you go to Tools >> Interface and Features >> Uploadable Image Types ... you can control that there. It’s probably a long shot, but I think I had that problem a long time ago.

          Anyone else go any ideas? huh
            Precision Web Development ... SmashStack.com
            • 16901
            • 35 Posts
            Good suggestion. I’ve tried .jpg, .JPG, .png, .PNG, .gif, .GIF... no luck.
              • 33982 ☆ A M B ☆
              • 476 Posts
              I think the last thing I can think of is that something is maybe wrong on Configuration file manager, resource path and/or the resource URL?

              In Tools >> Configuration >> File Manager and under "File Manager Path:", is the path correct there?  Also when you click on the "Interface and Features" tab next to the "File Manager" tab and for "Resource Path", is that information the same as the path for "File Manager Path"?  Does "Resource URL" have "assets/"? Also do all the 3 file paths all end with a "/"?  If everything is correct there, I’m not quite sure where the problem could be.
                Precision Web Development ... SmashStack.com
                • 16901
                • 35 Posts
                I changed all three of those values to assets/

                Still no love.

                I appreciate your efforts though.

                Anyone else have any suggestions?
                  • 16901
                  • 35 Posts
                  I’ve got a few further details about my hosting setup that were missing from my initial post.

                  - All PHP runs as CGI.
                  - Apache 2.0.54
                  - Debian GNU/Linux 4.1.11

                  Not sure if that helps...
                    • 16901
                    • 35 Posts
                    One other detail...

                    I tried uploading a few test images to /assets/images/ via FTP. No problems with uploading them. But when I go to the FCKEditor Resource Browser in MODx, I don’t see any of the test images listed. Is that symptomatic of anything?
                      • 27442
                      • 103 Posts
                      There are several threads around related to this behavior. Here’s one that might want to read through.
                      http://modxcms.com/forums/index.php/topic,29295.msg178021.html#msg178021