diff --git a/b2-include/b2functions.php b/b2-include/b2functions.php index 23b306101..af353d7fa 100644 --- a/b2-include/b2functions.php +++ b/b2-include/b2functions.php @@ -42,8 +42,8 @@ function wptexturize($text) { $curl = preg_replace("/(\d+)\"/", "$1″", $curl); $curl = preg_replace("/(\d+)'/", "$1′", $curl); $curl = preg_replace("/(\S)'([^'\s])/", "$1’$2", $curl); - $curl = preg_replace('/"([\s.]|\Z)/', '”$1', $curl); - $curl = preg_replace('/(\s|\A)"/', '$1“', $curl); + $curl = preg_replace('/"([\s.,!?;:&\']|\Z)/', '”$1', $curl); + $curl = preg_replace('/(\s|\A)"/', '$1“', $curl); $curl = preg_replace("/'([\s.]|\Z)/", '’$1', $curl); $curl = preg_replace("/\(tm\)/i", '™', $curl); $curl = preg_replace("/\(c\)/i", '©', $curl); @@ -62,7 +62,7 @@ function wptexturize($text) { $output .= $curl; } return $output; - } +} function wpautop($pee, $br=1) { $pee = $pee . "\n"; // just to make things a little easier, pad the end @@ -1393,6 +1393,7 @@ function apply_filters($tag, $string) { $b2_filter[$tag] = (is_string($b2_filter[$tag])) ? array($b2_filter[$tag]) : $b2_filter[$tag]; $functions = $b2_filter[$tag]; foreach($functions as $function) { + //error_log("apply_filters #1 applying filter $function"); $string = $function($string); } }