Fix clean URL issues with non-standard setups

This commit is contained in:
Ben Word
2013-05-01 15:51:59 -05:00
parent ec94cfb2f5
commit a8c543753a
5 changed files with 6 additions and 59 deletions

View File

@@ -28,8 +28,8 @@ function roots_add_rewrites($content) {
}
function roots_clean_urls($content) {
if (strpos($content, FULL_RELATIVE_PLUGIN_PATH) === 0) {
return str_replace(FULL_RELATIVE_PLUGIN_PATH, WP_BASE . '/plugins', $content);
if (strpos($content, RELATIVE_PLUGIN_PATH) > 0) {
return str_replace('/' . RELATIVE_PLUGIN_PATH, '/plugins', $content);
} else {
return str_replace('/' . THEME_PATH, '', $content);
}