summaryrefslogtreecommitdiff
path: root/framework/Util
diff options
context:
space:
mode:
authorxue <>2006-08-31 20:17:39 +0000
committerxue <>2006-08-31 20:17:39 +0000
commit47a3cb88e7ed7f2a87bbf024dff3416fc6cd8002 (patch)
tree0eb41f1ab1f2351905cd95054a328c34361e5080 /framework/Util
parentb680e71693696a7b5280787ccd084cf860bcf989 (diff)
merge from 3.0 branch till 1374.
Diffstat (limited to 'framework/Util')
-rw-r--r--framework/Util/TSimpleDateFormatter.php3
1 files changed, 2 insertions, 1 deletions
diff --git a/framework/Util/TSimpleDateFormatter.php b/framework/Util/TSimpleDateFormatter.php
index 9c2975d5..046a3442 100644
--- a/framework/Util/TSimpleDateFormatter.php
+++ b/framework/Util/TSimpleDateFormatter.php
@@ -118,7 +118,8 @@ class TSimpleDateFormatter
$bits['dd'] = str_pad("{$date['mday']}", 2, '0', STR_PAD_LEFT);
$bits['d'] = $date['mday'];
- return str_replace(array_keys($bits), $bits, $this->pattern);
+ $pattern = preg_replace('/M{3,4}/', 'MM', $this->pattern);
+ return str_replace(array_keys($bits), $bits, $pattern);
}
public function getMonthPattern()