From: Chuck Hagenbuch Date: Thu, 21 May 2009 15:17:52 +0000 (-0400) Subject: revert; this didn't fix all cases X-Git-Url: https://git.internetallee.de/?a=commitdiff_plain;h=5b65b9b90951893156ae0e1f4f09689a0d81c93f;p=horde.git revert; this didn't fix all cases --- diff --git a/framework/Date_Parser/lib/Horde/Support/Numerizer/Locale/Base.php b/framework/Date_Parser/lib/Horde/Support/Numerizer/Locale/Base.php index 9d314addc..b6cc380a5 100644 --- a/framework/Date_Parser/lib/Horde/Support/Numerizer/Locale/Base.php +++ b/framework/Date_Parser/lib/Horde/Support/Numerizer/Locale/Base.php @@ -124,7 +124,7 @@ class Horde_Support_Numerizer_Locale_Base protected function _andition($string) { while (true) { - if (preg_match('/([1-9]\d*)( | and )([1-9]\d*)(?=[^\w]|$)/i', $string, $sc, PREG_OFFSET_CAPTURE)) { + if (preg_match('/(\d+)( | and )(\d+)(?=[^\w]|$)/i', $string, $sc, PREG_OFFSET_CAPTURE)) { if (preg_match('/and/', $sc[2][0]) || $sc[1][0] > $sc[3][0]) { $string = substr($string, 0, $sc[1][1]) . ((int)$sc[1][0] + (int)$sc[3][0]) . substr($string, $sc[3][1] + strlen($sc[3][0])); continue;