Multisite install images not working

Home Forums BulletProof Security Pro Multisite install images not working

This topic contains 8 replies, has 2 voices, and was last updated by  AITpro Admin 6 years, 12 months ago.

Viewing 9 posts - 1 through 9 (of 9 total)
  • Author
    Posts
  • #338

    james8
    Member

    Hey Guys my images aren’t showing up after install followed your instructions about the rewrite rule to no avail. Wp multi is installed in my root directory, i only have one site.
    I’ve tried the below with combinations in the rewrite of ^example.com/files/(.*) and also ^public_html/files/(.*)

    RewriteEngine On
    RewriteBase /
    RewriteRule ^files/(.*)$ http://example.com/wp-content/blogs.dir/1/files/$1 [L,R=301]
    

    Any ideas?

    #341

    AITpro Admin
    Keymaster

    UPDATE:  Things have changed with Network/Multisite regarding the blogs.dir folder.  See the link below.

    http://forum.ait-pro.com/forums/topic/an-htaccess-file-was-not-found-in-your-blogs-dir-uploads-folder/

    Have you looked at this help post below regarding Network / Multisite images not displaying?  This issue is not directly related to or caused by BPS Pro and i thought that this was an old issue that was no longer occurring in the newer versions of Network / Multisite, but maybe it is still occurring after-all.

    Network / Multisite images issue /problem (not related to BPS):  http://www.ait-pro.com/aitpro-blog/3454/misc-projects/wordpress-tips-tricks-fixes/wordpress-network-mu-images-not-displaying-images-not-displaying-in-media-library-images-not-displaying-on-website/

    Do you have the latest BPS Pro 5.3 version installed?  If not, then install the upgrade from within your WP Dashboard. If you do not see the BPS Pro upgrade notification then click on My Sites >>> Network Admin >>> Updates >>> Check Again button.

    Then go to the B-Core System Info page and copy and paste all the info you see between WordPress Installation Folder to Browser Compression Supported.

    WordPress Installation Folder:



    Browser Compression Supported:

    BPS Pro General WordPress Network / MU Specific Help Support

    http://forum.ait-pro.com/forums/topic/read-me-first-pro/#network-multisite

    #470

    james8
    Member

    I have the latest version of free installed and have tried all the things listed on your help page regarding this.
    Here is the info you requested
    WordPress Installation Folder: /WordPress

    Installation Type: Root Folder Installation

    Network/Multisite: Multisite: Multisite is enabled

    WP Permalink Structure: /%category%/%postname%/

    Permalinks Enabled: √ Permalinks are Enabled

    PHP Version Check: √ Using PHP5

    Browser Compression Supported: gzip,deflate,sdch
     
    Thanks

    #471

    AITpro Admin
    Keymaster

    It is also possible that the problem has to do with an image Thumbnailer script. Please post a link to your website so that i can look at your image files to see if this is the problem that is occuring on your website.  If you wish to keep your website anonymous then state that when you post your link to your website and i will remove your link from your post reply.  Thanks.

    #478

    james8
    Member

    There is no image thumbnail script, it is just a child theme based on Thematic. Thanks for your help so far, it’s very strange to me I’m no pro, but just can’t see what I am missing here.
    the-exemplars.com

    #479

    AITpro Admin
    Keymaster

    UPDATE:  Things have changed with Network/Multisite regarding the blogs.dir folder.  See the link below.

    https://forum.ait-pro.com/forums/topic/an-htaccess-file-was-not-found-in-your-blogs-dir-uploads-folder/

    Ok it looks like the problem has something to do with your blogs.dir folder and/or the .htaccess file code you are using for your site.  Do you have a subdirectory or subdomain installation of Multisite?

    This path does not show the blogs.dir folder in the path…

    the-exemplars.com/files/2012/10/Trekstock.jpg

    …and should look like this… the-exemplars.com/wp-content/blogs.dir/1/files/2012/10/Trekstock.jpg…or if this is the Primary site it could also have this path…the-exemplars.com/wp-content/uploads/2012/10/Trekstock.jpg…and the rest of your sites would have a path with blogs.dir in it.

    When i try to view the Trekstock.jpg file i see this 403 Forbidden error – You don’t have permission to access /wp-includes/ms-files.php on this server.

    This tells me that something has not been setup or done correctly on your site.  This is the line of .htaccess code in your Root .htaccess file that does the rewrite for the “files” folder.

    # uploaded filesRewriteRule ^([_0-9a-zA-Z-]+/)?files/(.+) wp-includes/ms-files.php?file=$2 [L]

    On the Primary or first site for a Multisite installation the /uploads folder is used for the Primary site – multi-3-4-2.local/wp-content/uploads/2012/11/bad-juju-test.png

    All virtual subsites should be using the /blogs.dir uploads folder for image uploads/storage and would have the /blogs.dir/X/files path to the image uploads folder for all of those subsites.

    Ok so knowing all of this information above about the issue/problem on your website – please check the following things on your site:

    Have your created the /blogs.dir folder.  This is not done automatically for you – you need to create this folder yourself.

    Are you using the right [obsolete-removed] buttons?  If you have a subdirectory site then you would use the [obsolete-removed] subdirectory buttons to create your Master htaccess files.  If you have a subdomain site then you would use the [obsolete-removed] subdomain buttons.

    Have you followed these BulletProof Security setup instructions for Network / Multisite?

    https://forum.ait-pro.com/forums/topic/read-me-first-pro/#network-multisite

     

    #480

    AITpro Admin
    Keymaster

    I think your issue/problem could also possibly be this same exact problem described in this post – http://wordpress.org/support/topic/all-images-on-new-sub-site-getting-403-forbidden-errors?replies=16

    The logic for why that problem above happened/was occurring is that at some point this person did not have the correct setup/rewriterules/folder or some other mistake and files were being uploaded to the wrong folder – /tryhandmade/files.  Then at some point this person fixed that problem, but the wrong path was still being seen in the .htaccess rewriting process/code.

    Correction:

    The image files were not being seen because the rewriterule issue or folder issue had been corrected and the site/htaccess code was now looking in the correct folder, but the image files were still in the old/incorrect folder.

    #484

    james8
    Member

    Thanks I ended up reinstalling, redoing htacess and re inserting the line of code needed and it fixed it.
    Cheers

    #485

    AITpro Admin
    Keymaster

    Excellent!  Glad you got it sorted out.  Thanks for confirming all is well.

Viewing 9 posts - 1 through 9 (of 9 total)

You must be logged in to reply to this topic.