• The codex states that mu-plugins are “automatically enabled” but that is not what I’m seeing–I don’t see them at all. I’ve tested several local WP installs and the plugins listed in /wp-content/mu-plugins/ are not appearing in the WP admin > Plugins > Must-Use

    http://codex.wordpress.org/Must_Use_Plugins

    I followed example and created load.php in the root of mu-plugins to no avail.
    <?php // mu-plugins/load.php
    require WPMU_PLUGIN_DIR . ‘/my-plugin/my-plugin.php’;

Viewing 5 replies - 1 through 5 (of 5 total)
  • Moderator t-p

    (@t-p)

    the path should be /wp-content/plugins/mu-plugins/

    Thread Starter KostRev

    (@kostrev)

    @tara

    The codex specifies the path to be /wp-content/mu-plugins/

    Mark Jaquith’s WordPress Skeleton project has a similar structure as does Ben Word’s Roots Soil so the structure would seem to be correct.

    My load.php file shows up in the list at WP Admin > Plugin > Must-Use. So that must mean the issue lies in the path to the individual plugins.

    The loader file inside mu-plugins looks like this:

    <?php
    /*
    Plugin Name:  Must Use Plugins Loader
    Plugin URI:   http://somewhere.org/
    Description:  Making sure this works!
    Version:      1.0
    Author:       Me
    Author URI:   http://somewhere.org/
    */
    
    require WPMU_PLUGIN_DIR . '/my-plugin/my-plugin.php';
    require WPMU_PLUGIN_DIR . '/advanced-custom-fields/acf.php';
    require WPMU_PLUGIN_DIR . '/wp-post-formats/cf-post-formats.php';

    Since I am using WordPress Skeleton I’ve had to define the mu-plugins folder in the wp-config.php like so:

    // ========================
    // Custom Content Directory
    // ========================
    define( 'WP_CONTENT_DIR', dirname( __FILE__ ) . '/content' );
    define( 'WP_CONTENT_URL', 'http://' . $_SERVER['HTTP_HOST'] . '/content' );
    
    // ========================
    // Custom MU Plugins Directory
    // ========================
    define( 'WPMU_PLUGIN_DIR', dirname( __FILE__ ) . '/content/mu-plugins' );

    If I try to change these paths, either in the wp-config.php or my load.php the page won’t load so it would seem the addressing is correct.

    Moderator t-p

    (@t-p)

    Try and see if it works for you: /wp-content/plugins/mu-plugins/
    It works for me.

    Thread Starter KostRev

    (@kostrev)

    OK, I misunderstood something about the mu-plugins folder. If your mu-plugins are in subfolders, like typical plugins (/mu-plugins/my-plugin/my-plugin.php), you will not see them listed in the WP admin. However, that does not mean they haven’t loaded.

    Moderator t-p

    (@t-p)

    I use like this and it works fro me:
    /wp-content/plugins/mu-plugins/my-plugin.php

Viewing 5 replies - 1 through 5 (of 5 total)

The topic ‘How to enable mu-plugins?’ is closed to new replies.