Changeset 23554 for trunk/wp-includes/kses.php
- Timestamp:
- 03/01/2013 04:28:40 PM (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-includes/kses.php
r23416 r23554 1327 1327 function kses_init_filters() { 1328 1328 // Normal filtering 1329 add_filter('title_save_pre', 'wp_ kses_data');1329 add_filter('title_save_pre', 'wp_filter_kses'); 1330 1330 1331 1331 // Comment filtering 1332 1332 if ( current_user_can( 'unfiltered_html' ) ) 1333 add_filter( 'pre_comment_content', 'wp_ kses_post' );1333 add_filter( 'pre_comment_content', 'wp_filter_post_kses' ); 1334 1334 else 1335 add_filter( 'pre_comment_content', 'wp_ kses_data' );1335 add_filter( 'pre_comment_content', 'wp_filter_kses' ); 1336 1336 1337 1337 // Post filtering 1338 add_filter('content_save_pre', 'wp_ kses_post');1339 add_filter('excerpt_save_pre', 'wp_ kses_post');1340 add_filter('content_filtered_save_pre', 'wp_ kses_post');1338 add_filter('content_save_pre', 'wp_filter_post_kses'); 1339 add_filter('excerpt_save_pre', 'wp_filter_post_kses'); 1340 add_filter('content_filtered_save_pre', 'wp_filter_post_kses'); 1341 1341 } 1342 1342 … … 1355 1355 function kses_remove_filters() { 1356 1356 // Normal filtering 1357 remove_filter('title_save_pre', 'wp_ kses_data');1357 remove_filter('title_save_pre', 'wp_filter_kses'); 1358 1358 1359 1359 // Comment filtering 1360 remove_filter( 'pre_comment_content', 'wp_ kses_post' );1361 remove_filter( 'pre_comment_content', 'wp_ kses_data' );1360 remove_filter( 'pre_comment_content', 'wp_filter_post_kses' ); 1361 remove_filter( 'pre_comment_content', 'wp_filter_kses' ); 1362 1362 1363 1363 // Post filtering 1364 remove_filter('content_save_pre', 'wp_ kses_post');1365 remove_filter('excerpt_save_pre', 'wp_ kses_post');1366 remove_filter('content_filtered_save_pre', 'wp_ kses_post');1364 remove_filter('content_save_pre', 'wp_filter_post_kses'); 1365 remove_filter('excerpt_save_pre', 'wp_filter_post_kses'); 1366 remove_filter('content_filtered_save_pre', 'wp_filter_post_kses'); 1367 1367 } 1368 1368
Note: See TracChangeset
for help on using the changeset viewer.