WordPress.org

Ready to get started?Download WordPress

Forums

WordPress MU Domain Mapping
[resolved] domain_mapping_plugins_uri fail outside of /plugins/ (3 posts)

  1. Akeif
    Member
    Posted 10 months ago #

    Hi,

    I use the plugins_url function to get paths from file into /mu-plugins/.

    It work well when the website has no custom domain but with custom domains it just return weirdly cut string. Usualy just the last letter.

    For example calling
    plugins_url('feat-analytics.js', __FILE__)
    in /mu-plugins/feat-analytics.php
    will return string(1) "s"

    http://wordpress.org/plugins/wordpress-mu-domain-mapping/

  2. Ron Rennick
    MultiSite Guru
    Plugin Author

    Posted 10 months ago #

    You may want to review the codex page for the plugins_url function: http://codex.wordpress.org/Function_Reference/plugins_url

    Retrieves the absolute URL to the plugins directory...

    The mu-plugins folder is outside the plugins directory.

  3. Akeif
    Member
    Posted 10 months ago #

    Well, that's true. It say inside the plugin directory.
    I guess I'll have to update my code :P

    Ok thanks.

Reply

You must log in to post.

About this Plugin

About this Topic

Tags

No tags yet.