Support » Plugin: Smush Image Compression and Optimization » must be within the content directory

  • Resolved Jo Sprague

    (@josiahsprague)


    I am getting the error “must be within the content directory” on all of my images. The images are in the correct content directory, and the directory displayed in the error is correct as well. However, there is something preventing this from working. I suspect that it is this;

    My wordpress installation is in /wordpress/ but my wp-content folder is outside of the wordpress folder in /wp-content/.

    So the full path to the plugin is
    /wp-content/plugins/wp-smushit/

    And the full path to the uploads folder is
    /wp-content/uploads/

    I’ve redefined the location of my wp-content folder in wp-config.php, I have the correct site URL in the database, and everything else works fine, every other plugin, etc.

    I found a few old support requests about this error, but all of them seemed to say that the latest version fixes the problem. I’ve tried all of the workarounds I can find.

    Any ideas?

    http://wordpress.org/extend/plugins/wp-smushit/

Viewing 4 replies - 1 through 4 (of 4 total)
  • If I bypass “check that the file is within the WP_CONTENT_DIR” by commenting out that loop, I get “unknown error”.

    Did you ever find a solution to this?

    I’m experiencing the same problem with my WP installation and content in directories outside each other.

    Nope, but Kraken.io has a WP plugin coming out that is going to blow smush.it out of the water. With the lack of support on this plugin, I think it’s more likely that the Kraken plugin will be complete before this plugin gets fixed. If you’re up for writing your own code to solve the problem, I’d recommend using Kraken as well, since their image optimization is even better than smushit.

    Sounds good. I’ll look into it. Thanks for the quick reply.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘must be within the content directory’ is closed to new replies.