ExpressionEngine CMS
Open, Free, Amazing

Thread

This is an archived forum and the content is probably no longer relevant, but is provided here for posterity.

The active forums are here.

File Manager not able to upload files

October 28, 2010 5:11pm

Subscribe [6]
  • #1 / Oct 28, 2010 5:11pm

    lttc

    51 posts

    Have the same problem : file manager can upload but can’t insert “image” files (.png, .gif or .jpg) in publish (custom text field).

    But it can with text, html, tiff and pdf files…

    I found this strange code in a “edit” page with the file manager opened :

    <div title="https://ellislab.com/asset/images/pronet-logo/|ADQCAHIER.pdf">http://www.something.org/themes/cp_global_images/default.png</div>
    
    <div title="width="200" height="133"">http://www.something.org/themes/cp_global_images/default.png</div>

    In the div title you have the path to the pdf file (that I can insert), but there seems to be a mix up in the .jpg file information : the width and height information should not be there while the path of the image should probably be in the div title…

    Tried the thing with the “mimes”, but I upgraded directly from 1.6.9 to the last build, so it did not changed anything. Any browser on Mac.

  • #2 / Oct 29, 2010 9:49am

    Ingmar

    29245 posts

    I split off your posting to a new thread. I am a little confused as to what version and build you are now using? Also, any extensions in play?

  • #3 / Oct 29, 2010 11:03am

    lttc

    51 posts

    EE 2.1.1 build : 20101020, hosted with Engine Hosting. No extensions, only some plug-ins and modules.

    Anyway, the rendering code that I have posted is clearly buggy. Is the problem on my side or is it a bug of EE 2, I don’t know, but still, this code give us clues about the problem.

  • #4 / Oct 29, 2010 4:39pm

    Sue Crocker

    26054 posts

    Here’s what I get when I build an image link:

    https://ellislab.com/asset/images/team-photo/purpleflowers.jpg

    I expect to see width and height added for me. I don’t have any pre or post formatting set up. How does that differ from what you’re wanting?

  • #5 / Oct 29, 2010 5:14pm

    lttc

    51 posts

    It seems that we have a misunderstanding here…

    The code that I have pasted is the one of the File manager “chooser” who demonstrate why I can’t insert some kinds of file : .png, .gif or .jpg in edit or publish.

    Look at the div for a .pdf file, where in the div title you have the path of the file. This seems to be the good code, since when I click on the thumbnail in the file manager, it does insert it in the custom field.

    Then, still in the File manager “chooser”, the code in the div for a .jpg file is wrong : in the div title you don’t have the path for the file, like in the .pdf, instead you get the width and the height. This code should be in the img code. And, in the img code, at title you get the path that should be in the div title. That’s probably why when I click on the thumbnail of the .jpg, nothing happens. There is a mix up in the file manager code for the png, .gif and .jpg files.

  • #6 / Oct 29, 2010 5:17pm

    lttc

    51 posts

    In fact after a second look I’m not sure where the width and height should be, still, the path of the .jpg file is not at the good place…

  • #7 / Oct 30, 2010 4:52pm

    Greg Salt

    3988 posts

    Hi lttc,

    Have you modified any of the default file properties or pre/post formatting when creating the upload destination? If so, can you please post what your settings are there?

    Cheers

    Greg

  • #8 / Oct 30, 2010 6:13pm

    lttc

    51 posts

    This is an upgrade from our live EE 1.6.8 so it is an exact copy of it : upgraded to 1.6.9 and after to EE 2.1.1 last build. So yes, we have “image post formatting” :

    , and “All file types” settings.

    Strange… I had made, for testing, a new “upload destination”, with the same settings of our major one and just removed the post information and bingo, now I’m able to insert .jpg image. Hum !

    But now, whatever I put in the “image post formatting” is doubled in the insert code : let’s say I put

    
    
    in the post, in the custom text field I now get this :
    https://ellislab.com/asset/images/member_photos/manifestation-moore-3_thumb.jpg
    
    

     : see the double br…

    I have to say, that when I created this new upload destination I got an error (see the image), but it finally went in the database. Now, when I removed the “post” code in our “major” upload destination I got the same error. Following this, making more changes in the “post” don’t get any error but now the post code is doubled…

    Finally I’m beginning to guess that there is a problem in the database. If it is, is there an easy way to repair that ? Maybe erasing all the “upload destinations” and recreate them ?

  • #9 / Nov 01, 2010 4:14am

    John Henry Donovan

    12339 posts

    lttc,

    Can you go into your SQL Manager please and click on the Database Query form and submit the following please?

    Tools > Data > SQL Manager

    DESC exp_upload_no_access

    Can you take a screen shot of what it shows next please? It should show the 3 fields for that table

  • #10 / Nov 01, 2010 10:06am

    lttc

    51 posts

    Here it is.

  • #11 / Nov 01, 2010 11:49pm

    Sue Crocker

    26054 posts

    Ittc, you should have three fields in there. I’m assuming you have no rows there. The field missing is upload_loc.

    You would need to drop the table and rebuild it using:

    DROP TABLE IF EXISTS `exp_upload_no_access`;
    CREATE TABLE exp_upload_no_access (
    upload_id int(6) unsigned NOT NULL,
    upload_loc varchar(3) NOT NULL,
    member_group smallint(4) unsigned NOT NULL,
    PRIMARY KEY `upload_id_member_group` (`upload_id`, `member_group`)
    )

    NOTE: Be sure to back up your database before attempting this.

  • #12 / Nov 02, 2010 10:42am

    lttc

    51 posts

    Thanks !

    But should I replace this character (`) with ( ’ ) as : (`upload_id`) to (‘upload_id’) ? Or is it OK to copy-paste your post ?

  • #13 / Nov 02, 2010 5:49pm

    Ingmar

    29245 posts

    These are literally back-ticks, yes. Copy & paste should work fine.

  • #14 / Nov 03, 2010 2:47pm

    lttc

    51 posts

    I have doned it but it still “doubled” the image post formatting code.

    The results of the query seems to have change nothing like you will see in the image attached.

  • #15 / Nov 04, 2010 3:58am

    John Henry Donovan

    12339 posts

    lttc,

    Can you go ahead and use DESC exp_upload_no_access in your SQL Manager again please and confirm you now have 3 fields?

    I have to say, that when I created this new upload destination I got an error (see the image),

    Does the error still appear when you create a new upload destination?

.(JavaScript must be enabled to view this email address)

ExpressionEngine News!

#eecms, #events, #releases