Ticket #22537: 22537-balanceTags.patch
File 22537-balanceTags.patch, 886 bytes (added by , 8 years ago) |
---|
-
wp-includes/formatting.php
1132 1132 } 1133 1133 1134 1134 /** 1135 * Will only balance the tags if forced to and the option is set to balance tags.1135 * Balances tags if forced to, or if the 'use_balanceTags' option is set to true. 1136 1136 * 1137 * The option 'use_balanceTags' is used to determine whether the tags will be balanced.1138 *1139 1137 * @since 0.71 1140 1138 * 1141 1139 * @param string $text Text to be balanced … … 1143 1141 * @return string Balanced text 1144 1142 */ 1145 1143 function balanceTags( $text, $force = false ) { 1146 if ( !$force && get_option('use_balanceTags') == 0 ) 1144 if ( $force || get_option('use_balanceTags') == 1 ) 1145 return force_balance_tags( $text ); 1146 else 1147 1147 return $text; 1148 return force_balance_tags( $text );1149 1148 } 1150 1149 1151 1150 /**