From a4d045fe5bae74d7ef6cedb668a562281a888695 Mon Sep 17 00:00:00 2001 From: saxmatt Date: Sun, 23 May 2004 16:27:59 +0000 Subject: [PATCH] Allow people to modify and add on to rewrite rules. git-svn-id: http://svn.automattic.com/wordpress/trunk@1350 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-admin/options-permalink.php | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/wp-admin/options-permalink.php b/wp-admin/options-permalink.php index 2e4a7054bb..8bbd41b368 100644 --- a/wp-admin/options-permalink.php +++ b/wp-admin/options-permalink.php @@ -123,10 +123,12 @@ if ('/' != substr($home_root, -1)) $home_root = $home_root . '/'; RewriteBase $query) { - if (strstr($query, 'index.php')) echo 'RewriteRule ^' . $match . ' ' . $home_root . $query . " [QSA]\n"; - else echo 'RewriteRule ^' . $match . ' ' . $site_root . $query . " [QSA]\n"; + if (strstr($query, 'index.php')) $rules .= 'RewriteRule ^' . $match . ' ' . $home_root . $query . " [QSA]\n"; + $rules .= 'RewriteRule ^' . $match . ' ' . $site_root . $query . " [QSA]\n"; } +echo apply_filters('rewrite_rules', $rules); ?>