From dd36543bce2de20d51ea20e07842f5897cd18427 Mon Sep 17 00:00:00 2001 From: Mark Jaquith Date: Thu, 7 Dec 2006 00:38:54 +0000 Subject: [PATCH] Disable RTE when editing comments. Props mdawaffe. fixes #3449 git-svn-id: https://develop.svn.wordpress.org/trunk@4622 602fd350-edb4-49c9-b593-d223f7449a82 --- wp-includes/general-template.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/wp-includes/general-template.php b/wp-includes/general-template.php index d5d7e043c7..d0ba5f4c7a 100644 --- a/wp-includes/general-template.php +++ b/wp-includes/general-template.php @@ -782,10 +782,10 @@ function rich_edit_exists() { } function user_can_richedit() { - global $wp_rich_edit; - + global $wp_rich_edit, $pagenow; + if ( !isset($wp_rich_edit) ) - $wp_rich_edit = ( 'true' == get_user_option('rich_editing') && !preg_match('!opera[ /][2-8]|konqueror|safari!i', $_SERVER['HTTP_USER_AGENT']) && rich_edit_exists() ) ? true : false; + $wp_rich_edit = ( 'true' == get_user_option('rich_editing') && !preg_match('!opera[ /][2-8]|konqueror|safari!i', $_SERVER['HTTP_USER_AGENT']) && 'comment.php' != $pagenow && rich_edit_exists() ) ? true : false; return apply_filters('user_can_richedit', $wp_rich_edit); }