refs #104 - root relative urls shouldn't happen in admin
This commit is contained in:
@@ -91,10 +91,12 @@ function roots_root_relative_url($input) {
|
||||
return $output;
|
||||
}
|
||||
|
||||
if (!is_admin()) {
|
||||
add_filter('bloginfo_url', 'roots_root_relative_url');
|
||||
add_filter('theme_root_uri', 'roots_root_relative_url');
|
||||
add_filter('stylesheet_directory_uri', 'roots_root_relative_url');
|
||||
add_filter('template_directory_uri', 'roots_root_relative_url');
|
||||
add_filter('plugins_url', 'roots_root_relative_url');
|
||||
add_filter('the_permalink', 'roots_root_relative_url');
|
||||
add_filter('wp_list_pages', 'roots_root_relative_url');
|
||||
add_filter('wp_list_categories', 'roots_root_relative_url');
|
||||
@@ -110,10 +112,6 @@ add_filter('day_link', 'roots_root_relative_url');
|
||||
add_filter('year_link', 'roots_root_relative_url');
|
||||
add_filter('tag_link', 'roots_root_relative_url');
|
||||
add_filter('the_author_posts_link', 'roots_root_relative_url');
|
||||
|
||||
// Leaving plugins_url alone in admin to avoid potential issues (such as Gravity Forms)
|
||||
if (!is_admin()) {
|
||||
add_filter('plugins_url', 'roots_root_relative_url');
|
||||
}
|
||||
|
||||
// remove root relative URLs on any attachments in the feed
|
||||
|
||||
Reference in New Issue
Block a user