Index: default-filters.php
===================================================================
--- default-filters.php	(revision 17938)
+++ default-filters.php	(working copy)
@@ -12,6 +12,12 @@
  * @package WordPress
  */
 
+
+/**
+ * Filters
+ */
+
+
 // Strip, trim, kses, special chars for string saves
 foreach ( array( 'pre_term_name', 'pre_comment_author_name', 'pre_link_name', 'pre_link_target', 'pre_link_rel', 'pre_user_display_name', 'pre_user_first_name', 'pre_user_last_name', 'pre_user_nickname' ) as $filter ) {
 	add_filter( $filter, 'sanitize_text_field'  );
@@ -57,8 +63,7 @@
 }
 
 // Save URL
-foreach ( array( 'pre_comment_author_url', 'pre_user_url', 'pre_link_url', 'pre_link_image',
-	'pre_link_rss' ) as $filter ) {
+foreach ( array( 'pre_comment_author_url', 'pre_user_url', 'pre_link_url', 'pre_link_image', 'pre_link_rss' ) as $filter ) {
 	add_filter( $filter, 'wp_strip_all_tags' );
 	add_filter( $filter, 'esc_url_raw'       );
 	add_filter( $filter, 'wp_filter_kses'    );
@@ -91,7 +96,7 @@
 	add_filter( $filter, 'balanceTags', 50 );
 }
 
-// Format strings for display.
+// Format strings for display
 foreach ( array( 'comment_author', 'term_name', 'link_name', 'link_description', 'link_notes', 'bloginfo', 'wp_title', 'widget_title' ) as $filter ) {
 	add_filter( $filter, 'wptexturize'   );
 	add_filter( $filter, 'convert_chars' );
@@ -99,8 +104,8 @@
 }
 
 // Format WordPress
-foreach ( array( 'the_content', 'the_title' ) as $filter )
-	add_filter( $filter, 'capital_P_dangit', 11 );
+add_filter( 'the_title',    'capital_P_dangit', 11 );
+add_filter( 'the_content',  'capital_P_dangit', 11 );
 add_filter( 'comment_text', 'capital_P_dangit', 31 );
 
 // Format titles
@@ -109,28 +114,25 @@
 	add_filter( $filter, 'strip_tags'  );
 }
 
-// Format text area for display.
-foreach ( array( 'term_description' ) as $filter ) {
-	add_filter( $filter, 'wptexturize'      );
-	add_filter( $filter, 'convert_chars'    );
-	add_filter( $filter, 'wpautop'          );
-	add_filter( $filter, 'shortcode_unautop');
-}
+// Format text area for display
+add_filter( 'term_description', 'wptexturize'       );
+add_filter( 'term_description', 'convert_chars'     );
+add_filter( 'term_description', 'wpautop'           );
+add_filter( 'term_description', 'shortcode_unautop' );
 
 // Format for RSS
-foreach ( array( 'term_name_rss' ) as $filter ) {
-	add_filter( $filter, 'convert_chars' );
-}
+add_filter( 'term_name_rss', 'convert_chars' );
 
 // Pre save hierarchy
 add_filter( 'wp_insert_post_parent', 'wp_check_post_hierarchy_for_loops', 10, 2 );
 add_filter( 'wp_update_term_parent', 'wp_check_term_hierarchy_for_loops', 10, 3 );
 
-// Display filters
+// Title Display filters
 add_filter( 'the_title', 'wptexturize'   );
 add_filter( 'the_title', 'convert_chars' );
 add_filter( 'the_title', 'trim'          );
 
+// Content Display filters
 add_filter( 'the_content', 'wptexturize'        );
 add_filter( 'the_content', 'convert_smilies'    );
 add_filter( 'the_content', 'convert_chars'      );
@@ -138,24 +140,25 @@
 add_filter( 'the_content', 'shortcode_unautop'  );
 add_filter( 'the_content', 'prepend_attachment' );
 
-add_filter( 'the_excerpt',     'wptexturize'      );
-add_filter( 'the_excerpt',     'convert_smilies'  );
-add_filter( 'the_excerpt',     'convert_chars'    );
-add_filter( 'the_excerpt',     'wpautop'          );
-add_filter( 'the_excerpt',     'shortcode_unautop');
-add_filter( 'get_the_excerpt', 'wp_trim_excerpt'  );
+// Excerpt Display filters
+add_filter( 'the_excerpt',     'wptexturize'       );
+add_filter( 'the_excerpt',     'convert_smilies'   );
+add_filter( 'the_excerpt',     'convert_chars'     );
+add_filter( 'the_excerpt',     'wpautop'           );
+add_filter( 'the_excerpt',     'shortcode_unautop' );
+add_filter( 'get_the_excerpt', 'wp_trim_excerpt'   );
 
-add_filter( 'comment_text', 'wptexturize'            );
-add_filter( 'comment_text', 'convert_chars'          );
-add_filter( 'comment_text', 'make_clickable',      9 );
-add_filter( 'comment_text', 'force_balance_tags', 25 );
-add_filter( 'comment_text', 'convert_smilies',    20 );
-add_filter( 'comment_text', 'wpautop',            30 );
+// Comment Display filters
+add_filter( 'comment_text',    'wptexturize'            );
+add_filter( 'comment_text',    'convert_chars'          );
+add_filter( 'comment_text',    'make_clickable',      9 );
+add_filter( 'comment_text',    'force_balance_tags', 25 );
+add_filter( 'comment_text',    'convert_smilies',    20 );
+add_filter( 'comment_text',    'wpautop',            30 );
+add_filter( 'comment_excerpt', 'convert_chars'          );
 
-add_filter( 'comment_excerpt', 'convert_chars' );
-
-add_filter( 'list_cats',         'wptexturize' );
-
+// Other Display filters
+add_filter( 'list_cats',  'wptexturize'         );
 add_filter( 'wp_sprintf', 'wp_sprintf_l', 10, 2 );
 
 // RSS filters
@@ -173,7 +176,7 @@
 
 // Misc filters
 add_filter( 'option_ping_sites',    'privacy_ping_filter'                 );
-add_filter( 'option_blog_charset',  '_wp_specialchars'                    ); // IMPORTANT: This must not be wp_specialchars() or esc_html() or it'll cause an infinite loop
+add_filter( 'option_blog_charset',  '_wp_specialchars'                    ); // IMPORTANT: This must not be wp_specialchars() or esc_html() or it'll cause an infinite loop.
 add_filter( 'option_home',          '_config_wp_home'                     );
 add_filter( 'option_siteurl',       '_config_wp_siteurl'                  );
 add_filter( 'tiny_mce_before_init', '_mce_set_direction'                  );
@@ -191,7 +194,15 @@
 add_filter( 'editable_slug',        'urldecode'                           );
 add_filter( 'nav_menu_meta_box_object', '_wp_nav_menu_meta_box_object'    );
 
-// Actions
+// Timezone
+add_filter( 'pre_option_gmt_offset', 'wp_timezone_override_offset' );
+
+
+/**
+ * Actions
+ */
+
+
 add_action( 'wp_head',             'wp_enqueue_scripts',            1     );
 add_action( 'wp_head',             'feed_links',                    2     );
 add_action( 'wp_head',             'feed_links_extra',              3     );
@@ -255,9 +266,9 @@
 add_action( 'admin_init',                 'send_frame_options_header', 10, 0 );
 
 // Navigation menu actions
-add_action( 'delete_post',                '_wp_delete_post_menu_item'      );
-add_action( 'delete_term',                '_wp_delete_tax_menu_item'       );
-add_action( 'transition_post_status', '_wp_auto_add_pages_to_menu',  10, 3 );
+add_action( 'delete_post',                '_wp_delete_post_menu_item'          );
+add_action( 'delete_term',                '_wp_delete_tax_menu_item'           );
+add_action( 'transition_post_status',     '_wp_auto_add_pages_to_menu',  10, 3 );
 
 // Post Thumbnail CSS class filtering
 add_action( 'begin_fetch_post_thumbnail_html', '_wp_post_thumbnail_class_filter_add'    );
@@ -270,13 +281,10 @@
 // Nonce check for Post Previews
 add_action( 'init', '_show_post_preview' );
 
-// Timezone
-add_filter( 'pre_option_gmt_offset','wp_timezone_override_offset' );
-
 // Admin Color Schemes
 add_action( 'admin_init', 'register_admin_color_schemes', 1);
 add_action( 'admin_color_scheme_picker', 'admin_color_scheme_picker' );
 
-unset($filter, $action);
+unset( $filter, $action );
 
 ?>
