From 546d3a9994d9f365f75e55f2f22601dc4941f5d5 Mon Sep 17 00:00:00 2001 From: Andreas Gohr Date: Mon, 10 Mar 2008 22:49:39 +0100 Subject: another change in highlight handling Now higlighting phrases are passed as an array which then is quoted correctly when used in a regexp. This should make phrase highlighting work completely correct. Please everyone test it. darcs-hash:20080310214939-7ad00-1abefb02dde40edeead50b4fa5c866c46b95ca3a.gz --- inc/common.php | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'inc/common.php') diff --git a/inc/common.php b/inc/common.php index 7f550dbde..127276475 100644 --- a/inc/common.php +++ b/inc/common.php @@ -1197,6 +1197,11 @@ function php_to_byte($v){ return $ret; } - +/** + * Wrapper around preg_quote adding the default delimiter + */ +function preg_quote_cb($string){ + return preg_quote($string,'/'); +} //Setup VIM: ex: et ts=2 enc=utf-8 : -- cgit v1.2.3