• Resolved worgdev

    (@worgdev)


    Hi. Just a quick query to find out if you are planning to extend support to the bedrock WP template?

    Maybe there is something I can do to enable support for this?

    I did read other threads and found out that uploads outside wp-content are not supported.

    Roots.io Bedrock template file structure is different to enhance the security of a website.

    Please see file structure here: https://roots.io/bedrock/

    Thanks

    The page I need help with: [log in to see the link]

Viewing 7 replies - 1 through 7 (of 7 total)
  • Plugin Author kubiq

    (@kubiq)

    Hello,

    I can not see any reason why it should not work.

    In older versions of this plugin was rewrite rule focused on uploads folder, then on wp-content but in a few latest releases it is simply applied for the whole web.

    What exactly is your problem? Are you receiving some error?

    Thread Starter worgdev

    (@worgdev)

    Thanks for a quick response. Really appreciate it.

    I have now pinpointed the issue.

    You are right. The conversion functionality does work. Checked theme files and could see webp. Also can confirm that the plugin is loading webp on the front end as expected.

    The issue (which led me to believe that the plugin might not work) is with converting existing images. It lists “wp-admin” and “wp-includes” only.

    Essentially the actual uploads directory is not listed due to a different directory structure on bedrock.

    Plugin Author kubiq

    (@kubiq)

    Aha, yes, well, it’s disabled to go out of the root folder for the security reasons and I’m not sure if it’s good idea to enable something like this…

    If you know which variables or functions can ensure code condition that it is bedrock installation and it’s safe to go 1 up, then maybe i can implement something like that later, but right now I have no time for such an investigation unfortunately.

    Thread Starter worgdev

    (@worgdev)

    Yes, I thought that might be the case actually. There is a reason why it was separated to begin with.

    I am not aware of conditionals or functions currently, but I also think it might not even be worth exploring as I would much prefer security over “extra functionality”.

    I will mark this as resolved because the core functionality actually does work. I guess, in this instance, it is more of a case of a choice – add an extra security layer or support existing image conversion.

    Again – thank you for your support.

    Hi, I have created a fork of file images-to-webp.php with a filter "itw_abspath" for ABSPATH.

    Bedrock users only need to add a this filter to get access to /app folder:

    add_filter( 'itw_abspath', function( $path ){ return trailingslashit( WP_CONTENT_DIR ); } );
    • This reply was modified 1 year, 5 months ago by Pacotole.
    • This reply was modified 1 year, 5 months ago by Pacotole.
    Plugin Author kubiq

    (@kubiq)

    If that’s all you need, then sure – version 4.3 just for you is released!

    Thank you very much @pacotole ??

    Thanks to you ??????

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘Roots Bedrock support’ is closed to new replies.