Viewing 7 replies - 1 through 7 (of 7 total)
  • Thread Starter jasond5

    (@jasond5)

    I tried for grins & giggles to upload a new image and that doesn’t work either.

    They upload but it is the generic image shown. I can see the actual image when I click “Edit” in the media section, but they are not showing anywhere else…

    suggestions?

    are the permissions (including ownership) on the wp-content/uploads directory set properly? often times this is the cause of image issues.

    If you’ve confirmed that the images from your local machine are on the remote server, what happens when you manually open the url in the browser? e g. go to yoursite.com/wp-content/uploads/2014/05/some-image-that-you-know-is-there.jpg – does it 404?

    Check your apache error logs too.

    Thread Starter jasond5

    (@jasond5)

    Thanks for the reply! If I try go directly to the image I get the following.

    “The virtual host was set up successfully.

    If you can see this page, your new virtual host was set up successfully. Now, web contents can be added and this placeholder page1 should be replaced or deleted.

    Server name: localhost
    Document-Root: /Applications/MAMP/htdocs”

    I assume this is the equivalent of the 403. I’ve been reading about the permissions, however, on a localhost, where can I check them? I try via filezilla (like I would for a live server) but there is no permissions option.

    Using Finder (Mac): I use the “Get Info” and it shows I have “Read & Write” privileges. Is that the same as permissions?

    I have several local sites without issue so it is strange this one popped up.

    is the Document root /Applications/MAMP/htdocs indeed where the WP isntall lives – your post leads me to believe that it might not be.

    post a copy of your .htaccess file too.

    Thread Starter jasond5

    (@jasond5)

    My site is located at /Applications/MAMP/htdocs/inserts_local/

    The images are in their usual spot: /Applications/MAMP/htdocs/inserts_local/wp-contents/uploads/

    Here is contents of my .htaccess file…

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

    # END WordPress

    It looks like the vhost config is the issue. The error page you initially posted claims that the doc root is /Applications/MAMP/htdocs – looks like you need to find where the localhost directive is specified and set the document root correctly to /Applications/MAMP/htdocs/inserts_local

    Thread Starter jasond5

    (@jasond5)

    this .htaccess is exactly like others (different site name obviously). I have several local sites and they have no issues. How do I change vhost config?

    I don’t think it is a permissions issue because the images are there and new ones can be added… they merely appear broken. If it were, where on a localhost can permissions be modified?

    I did see other posts referencing putting this in the .htaccess file, however, I’m not certain I have the details correctly inputted…

    <VirtualHost *:80>
    ServerName wp.localhost
    ServerAlias *.wp.localhost
    ServerAlias …………………
    DocumentRoot /var/www/localhost/inserts_local/



    RewriteEngine On
    RewriteLogLevel 9
    RewriteLog /var/log/apache2/rewrite.log
    <directory /var/www/localhost/inserts_local/ >
    #AllowOverride FileInfo Options Indexes
    AllowOverride None

    # BEGIN WordPress
    RewriteEngine On
    RewriteRule ^index\.php$ – [L]
    # uploaded files
    RewriteRule ^files/(.+) wp-includes/ms-files.php?file=$1 [L]
    RewriteCond %{REQUEST_FILENAME} -f [OR]
    RewriteCond %{REQUEST_FILENAME} -d
    RewriteRule ^ – [L]
    RewriteRule . /inserts_local/index.php [L]
    # END WordPress
    </directory>
    ….


    </VirtualHost>

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘Localhost Images now showing after move’ is closed to new replies.