WordPress.org

Forums

[resolved] Uploaded images seen in FTP, but not HTTP or posts (9 posts)

  1. bccarlso
    Member
    Posted 5 years ago #

    Hi all, I'm fairly new to WordPress, but have been asked to troubleshoot an issue we're having on one of our sites. Any image that is uploaded through the image uploader will make it to the correct destination (e.g. wp-content/uploads/2009/03/join-pnp-now.gif), but does not appear in the post when the image is placed into it, and cannot be viewed at the specific URL of the image, like http://www.url.com/wp-content/uploads/2009/03/join-pnp-now.gif. I've viewed the source on the page where the image should appear, and the path to the image is correct, so it's not that.

    It would appear to be a corrupt image, but when I FTP in, I can see all the images fine, download them, they work, etc. I think it's something to do with PHP and the file/folder/URL structure that WP is using, but am not quite sure. The "Organize my uploads by year and month" is checked, and the "Full URL path to files" is blank.

    Any help in troubleshooting this would be appreciated, thanks!

  2. Samuel B
    moderator
    Posted 5 years ago #

    what do you have in
    admin -settings - miscellaneous
    ??

  3. bccarlso
    Member
    Posted 5 years ago #

    Store uploads in this folder: wp-content/uploads
    Full URL path to files: blank
    Organize my uploads into month- and year-based folders is checked
    Track Links' Update Times is unchecked
    Use legacy my-hacks.php file support is unchecked

  4. bccarlso
    Member
    Posted 5 years ago #

    Here's an example, on this page http://www.tacomayfc.org/get-involved/donate/, there is a join-pnp-now.gif near the bottom of the page. It doesn't show up here, and doesn't show up when you go to http://www.tacomayfc.org/wp-content/uploads/2009/03/join-pnp-now.gif, but when I navigate to that directory with a FTP client, it's there, and isn't a corrupt image.

    Any ideas?

  5. Samuel Wood (Otto)
    Tech Ninja
    Posted 5 years ago #

    What are the permissions of the files when you view them via FTP? Perhaps they're getting set wrong and so the webserver won't serve them properly.

    Alternately, got anything weird in your .htaccess file?

  6. bccarlso
    Member
    Posted 5 years ago #

    Everything in the wp-content/uploads folder is 777 for now (had tested that earlier), and I can't open the .htaccess file for some reason... I'm new to this Mac that I'm working on, and Coda won't allow me to open it.

  7. bccarlso
    Member
    Posted 5 years ago #

    The root .htaccess file has this, as well as the WPSuperCache plugin .htaccess stuff (though I have disabled all plugins to troubleshoot as well):

    # BEGIN WordPress
    <IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteBase /
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule . /index.php [L]
    </IfModule>
    # END WordPress

    Then in the wp-content/uploads folder is this:

    php_value safe_mode "1"

    I'm not quite sure what safe_mode is, but maybe that has something to do with it. Thanks for the help so far guys.

  8. bccarlso
    Member
    Posted 5 years ago #

    I believe it ended up being the PHP safe mode, which I removed from the .htaccess file in the /uploads/ directory, and things worked again. Not sure exactly the consequences of that command, but oh well! =)

  9. R3sshin
    Member
    Posted 5 years ago #

    @ bccarlso

    hi, what exactly did u do to disable safe mode? i don't see a .htaccess in my wp-content/uploads folder

Topic Closed

This topic has been closed to new replies.

About this Topic