mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2026-07-04 17:20:07 +00:00
Allow wp-content to exist outside of webroot. Props sambauers. see #6938
git-svn-id: https://develop.svn.wordpress.org/trunk@7999 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
@@ -278,7 +278,7 @@ function load_default_textdomain() {
|
||||
*
|
||||
* The plugin may place all of the .mo files in another folder and set
|
||||
* the $path based on the relative location from ABSPATH constant. The
|
||||
* plugin may use the constant PLUGINDIR and/or plugin_basename() to
|
||||
* plugin may use the constant WP_PLUGIN_DIR and/or plugin_basename() to
|
||||
* get path of the plugin and then add the folder which holds the .mo
|
||||
* files.
|
||||
*
|
||||
@@ -291,9 +291,9 @@ function load_plugin_textdomain($domain, $path = false) {
|
||||
$locale = get_locale();
|
||||
|
||||
if ( false === $path )
|
||||
$path = PLUGINDIR;
|
||||
$path = WP_PLUGIN_DIR;
|
||||
|
||||
$mofile = ABSPATH . "$path/$domain-$locale.mo";
|
||||
$mofile = $path . '/'. $domain . '-' . $locale . '.mo';
|
||||
load_textdomain($domain, $mofile);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user