diff -uNrp zabbix-2.0.4.orig/frontends/php/chart4.php zabbix-2.0.4/frontends/php/chart4.php --- zabbix-2.0.4.orig/frontends/php/chart4.php 2012-12-08 20:09:20.000000000 +0900 +++ zabbix-2.0.4/frontends/php/chart4.php 2013-03-27 10:27:21.400379912 +0900 @@ -87,7 +87,7 @@ $y = imagesy($im); imagefilledrectangle($im, 0, 0, $x, $y, $white); imagerectangle($im, 0, 0, $x - 1, $y - 1, $black); -$str = _s('%1$s (year %2$s)', $db_data['description'], zbx_date2str('Y')); +$str = _s('%1$s (year %2$s)', $db_data['description'], zbx_date2str(_x('Y', 'date format'))); $x = imagesx($im) / 2 - imagefontwidth(4) * zbx_strlen($str) / 2; imageText($im, 10, 0, $x, 14, $darkred, $str); diff -uNrp zabbix-2.0.4.orig/frontends/php/chart5.php zabbix-2.0.4/frontends/php/chart5.php --- zabbix-2.0.4.orig/frontends/php/chart5.php 2012-12-08 20:09:20.000000000 +0900 +++ zabbix-2.0.4/frontends/php/chart5.php 2013-03-27 10:27:21.400379912 +0900 @@ -80,7 +80,7 @@ $y = imagesy($im); imagefilledrectangle($im, 0, 0, $x, $y, $white); imagerectangle($im, 0, 0, $x-1, $y-1, $black); -$d = zbx_date2str('Y'); +$d = zbx_date2str(_x('Y', 'date format')); $str = _s('%1$s (year %2$s)', $service['name'], $d); $x = imagesx($im) / 2 - imagefontwidth(4) * zbx_strlen($str) / 2; imageText($im, 10, 0, $x, 14, $darkred, $str); diff -uNrp zabbix-2.0.4.orig/frontends/php/include/func.inc.php zabbix-2.0.4/frontends/php/include/func.inc.php --- zabbix-2.0.4.orig/frontends/php/include/func.inc.php 2012-12-08 20:09:18.000000000 +0900 +++ zabbix-2.0.4/frontends/php/include/func.inc.php 2013-03-27 10:29:19.838386152 +0900 @@ -247,11 +247,21 @@ function zbx_date2str($format, $value = ); } + if (strcmp(_('S_DAY_UNIT'), "S_DAY_UNIT") == 0) $sdu=""; + else $sdu=_('S_DAY_UNIT'); + + if (strcmp(_('S_YEAR_UNIT'), "S_YEAR_UNIT") == 0) $syu=""; + else $syu=_('S_YEAR_UNIT'); + $rplcs = array( 'l' => $weekdaynameslong[date('w', $value)], 'F' => $monthslong[date('n', $value)], 'D' => $weekdaynames[date('w', $value)], - 'M' => $months[date('n', $value)] + 'j' => date('j',$value).$sdu, + 'z' => date('z',$value).$sdu, + 'M' => $months[date('n', $value)], + 'o' => date('o',$value).$syu, + 'J' => date('Y',$value).$syu ); $output = ''; diff -uNrp zabbix-2.0.4.orig/frontends/php/report3.php zabbix-2.0.4/frontends/php/report3.php --- zabbix-2.0.4.orig/frontends/php/report3.php 2012-12-08 20:09:20.000000000 +0900 +++ zabbix-2.0.4/frontends/php/report3.php 2013-03-27 10:27:21.514451841 +0900 @@ -96,7 +96,7 @@ switch ($period) { } function format_time($t) { - return zbx_date2str(_('Y'), $t); + return zbx_date2str(_x('Y', 'date format'), $t); } function format_time2($t) {