Changeset 5425
- Timestamp:
- 05/10/2007 01:31:12 AM (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-includes/general-template.php
r5248 r5425 810 810 function user_can_richedit() { 811 811 global $wp_rich_edit, $pagenow; 812 813 if ( !isset($wp_rich_edit) ) 814 $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; 812 813 if ( !isset( $wp_rich_edit) ) { 814 if ( get_user_option( 'rich_editing' ) == 'true' && 815 ( ( preg_match( '!AppleWebKit/(\d+)!', $_SERVER['HTTP_USER_AGENT'], $match ) && intval($match[1]) >= 420 ) || 816 !preg_match( 'opera[ /][2-8]|konqueror|safari!i', $_SERVER['HTTP_USER_AGENT'] ) ) ) { 817 $wp_rich_edit = true; 818 } else { 819 $wp_rich_edit = false; 820 } 821 } 815 822 816 823 return apply_filters('user_can_richedit', $wp_rich_edit);
Note: See TracChangeset
for help on using the changeset viewer.