WordPress.org

Ready to get started?Download WordPress

Forums

images not showing mystery (17 posts)

  1. petergus
    Member
    Posted 10 months ago #

    Everything was working infact, but maybe something happened to the server.

    I have checked permissions, uploaded files are there and readable, and also can add new to the right directory in blogs.dir.

    i have checked .htaccess and mod rewrite is enabled and working.

    i have set the "Upload Path" to "wp-content/blogs.dir/5/files" and "Fileupload Url" and "Upload Url Path" to just "files".

    i have read through this topic and seems to have covered everything but now i have no clue!!

    The images do show if i put in the full path (wp-content...).

  2. akhilesh1010
    Member
    Posted 10 months ago #

    Check the image path in source code you can also use firebug for this.

  3. Are you still on WP 3.5.2?

  4. petergus
    Member
    Posted 10 months ago #

    actually im still on version 3.3.2.
    dont really want to update and break things.
    everything was infact running fine, dont know what would have changed, i run it also on a VPS, must be something related because i restarted and then noticed the break. but mod rewrite is running.

    path in source is http://example.com/files/2013/01/image.jpeg

    Thanks!

  5. Ugh. You really NEED to update.

    3.3.2 isn't supported by anyone, plugins are dropping support for it, and you're at risk for security vulnerabilities. The longer you wait to upgrade, the harder it gets. It seems paradoxical, but the more you update, the less likely it is you'll have problems.

    What's the content of your .htaccess? We can try to help you out but most of our debugging is already aimed for WP 3.6. It'll probably work for 3.5, but 3.3 is really different.

  6. petergus
    Member
    Posted 10 months ago #

    hehe, yes, i can imagine. ok, i will look into updating. my only point being it *was* working, thus the mystery.

    here is my htaccess. Thanks for the help!!

    <IfModule mod_rewrite.c>
    # BEGIN WordPress
    RewriteEngine On
    RewriteBase /
    RewriteRule ^index\.php$ - [L]
    
    # uploaded files
    RewriteRule ^([_0-9a-zA-Z-]+/)?files/(.+) wp-includes/ms-files.php?file=$2 [L]
    
    RewriteRule ^files/(.*)$ http://domain.com/wp-content/files/$1 [L,R=301]
    
    # add a trailing slash to /wp-admin
    RewriteRule ^([_0-9a-zA-Z-]+/)?wp-admin$ $1wp-admin/ [R=301,L]
    
    RewriteCond %{REQUEST_FILENAME} -f [OR]
    RewriteCond %{REQUEST_FILENAME} -d
    RewriteRule ^ - [L]
    RewriteRule  ^[_0-9a-zA-Z-]+/(wp-(content|admin|includes).*) $1 [L]
    RewriteRule  ^[_0-9a-zA-Z-]+/(.*\.php)$ $1 [L]
    RewriteRule . index.php [L]
    # END WordPress
    </IfModule>
  7. This is a problem:

    # uploaded files
    RewriteRule ^([_0-9a-zA-Z-]+/)?files/(.+) wp-includes/ms-files.php?file=$2 [L]
    
    RewriteRule ^files/(.*)$ http://domain.com/wp-content/files/$1 [L,R=301]

    You don't need BOTH, and the second one has never been supported... Can you remove it or comment it out to test?

  8. petergus
    Member
    Posted 10 months ago #

    Unfortunately that didn't do anything :(
    i commented out RewriteRule ^files/(.*)$ http://domain.com/wp-content/files/$1 [L,R=301]

  9. petergus
    Member
    Posted 10 months ago #

    broken image icon

  10. Yeah, it's your server :/

    The httpd.conf needs to be set for your domain to have AllowOptions set to either 'All' or 'Options All'

  11. petergus
    Member
    Posted 10 months ago #

    in my apache2/sites-available/examplesite.conf (the one used as the 'parent site' for the multisite) i have

    <Directory /home/examplesite/public_html>
    Options -Indexes +IncludesNOEXEC +FollowSymLinks +ExecCGI
    allow from all
    AllowOverride All
    AddHandler fcgid-script .php
    AddHandler fcgid-script .php5
    FCGIWrapper /home/examplesite/fcgi-bin/php5.fcgi .php
    FCGIWrapper /home/examplesite/fcgi-bin/php5.fcgi .php5
    </Directory>

    I added in Options All and restarted apache but nothing new.
    (AllowOptions All threw a syntax error)

  12. AllowOverride All should be AllowOverride Options All

  13. petergus
    Member
    Posted 10 months ago #

    still no go.
    it cant be this because i didn’t edit this file and it was working.
    can you tell me which modules this depends on? Because i restarted the server and lately things havnt been working right on the server, so i have the feeling it didn’t start some modules.

    but in general the mod rewrite is working, so cant really tell... mystery!

    thanks for your help :)

  14. it cant be this because i didn’t edit this file and it was working.

    I understand WHY you think that, but it's incorrect assumption.

    Anyway, this is one of the times when I would say that since the redirect isn't working, for whatever reason, it's time to consider changing WP to stop using ms-files.php

    It's possible to change to the NEW config, which puts the files in /wp-content/uploads/sites/ instead:

    http://halfelf.org/2012/dumping-ms-files/
    http://trepmal.com/2013/03/24/removing-ms-files-php-dependency/

    IMO? Easier to wrangle WP than Apache sometimes.

  15. petergus
    Member
    Posted 10 months ago #

    probably :D was thinking to actually just move it to a single install, any tips for that?

  16. Export posts from the sub sites via WP exporter.

    Import into main site.

    Remove subsites

    Disable Multisite - http://wpmututorials.com/how-to/how-to-disable-multisite/

Reply

You must log in to post.

About this Topic

Tags

No tags yet.