Support » Plugin: Breeze - WordPress Cache Plugin » Store minification/cache files in custom directory/folder

  • Resolved Jon Dingman

    (@jdingman)


    I’ve looked through the plugin and found a few constants to help define this, but couldn’t find anything in the documentation about it.

    Is there a way to store minified files in a different folder?

    Such as /wp-content/uploads/mincache/

    TIA!

Viewing 3 replies - 1 through 3 (of 3 total)
  • @adeelkhan any suggestions?

    I tried modifying BREEZE_CACHE_CHILD_DIR as shown below in wp-config.php, and the plugin does output in the HTML the correct path, but the files aren’t getting written to the directory, so the references result in a 404.

    define( 'BREEZE_CACHE_CHILD_DIR', '/uploads/mincache/' );

    Based on what I saw here, https://plugins.trac.wordpress.org/browser/breeze/trunk/inc/minification/breeze-minify-main.php

    I was able to get it working, but it’s a bit of a hack

    ...
    /* That's all, stop editing! Happy publishing. */
    /** Absolute path to the WordPress directory. */
    if ( ! defined( 'ABSPATH' ) ) {
            define( 'ABSPATH', dirname( __FILE__ ) . '/' );
    }
    
    define( 'BREEZE_CACHE_CHILD_DIR', '/uploads/mincache/' );
    define( 'BREEZE_MINIFICATION_CACHE', ABSPATH . '/wp-content/uploads/mincache/' );

    I’ll be using this until there’s official support for it.

    To note, my /wp-content/uploads folder is a symlink to a shared EFS drive so I can share the cache in real-time across clustered servers handling the frontend.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Store minification/cache files in custom directory/folder’ is closed to new replies.