Skip to content
Snippets Groups Projects
Commit 5cc966ca authored by Michael Klier's avatar Michael Klier
Browse files

XMLRPC: fix for IXR_Date which returned a wrong formatted UTC timestamp

darcs-hash:20080305193802-23886-b786952c122c36e63676dd82d771494d763b9569.gz
parent 51597811
No related branches found
No related tags found
No related merge requests found
......@@ -585,8 +585,8 @@ class IXR_Date {
}
function parseTimestamp($timestamp) {
$this->year = date('Y', $timestamp);
$this->month = date('Y', $timestamp);
$this->day = date('Y', $timestamp);
$this->month = date('m', $timestamp);
$this->day = date('d', $timestamp);
$this->hour = date('H', $timestamp);
$this->minute = date('i', $timestamp);
$this->second = date('s', $timestamp);
......@@ -600,7 +600,7 @@ class IXR_Date {
$this->second = substr($iso, 15, 2);
}
function getIso() {
return $this->year.$this->month.$this->day.'T'.$this->hour.':'.$this->minute.':'.$this->second;
return $this->year.'-'.$this->month.'-'.$this->day.'T'.$this->hour.':'.$this->minute.':'.$this->second;
}
function getXml() {
return '<dateTime.iso8601>'.$this->getIso().'</dateTime.iso8601>';
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment