Better return value formatting.

This commit is contained in:
Michal Čihař
2004-04-19 08:11:44 +00:00
parent 4d81774960
commit 1485f89b53
2 changed files with 12 additions and 3 deletions

View File

@@ -5,8 +5,11 @@ phpMyAdmin - Changelog
$Id$
$Source$
2004-04-19 Michal Cihar <michal@cihar.com>
* libraries/tbl_change.js: Better return value formatting.
2004-04-18 Michal Cihar <michal@cihar.com>
* libraries/tbl_change.js: Fixed caledar behavior for DATE fields.
* libraries/tbl_change.js: Fixed caledar behaviour for DATE fields.
* libraries/auth/cookie.auth.lib.php: Fix LoginCookieValidity behaviour.
* libraries/tbl_change.js, tbl_change.php: Add support for DATETIME.

View File

@@ -209,11 +209,17 @@ function initCalendar() {
str += "</tr><tr>";
dayInWeek = 0;
}
dispmonth = 1 + month;
yearstring = (year < 1000 ? year < 100 ? year < 10 ? '000' : '00' : '0' : '') + year;
monthstring = (dispmonth < 10 ? '0' : '') + dispmonth;
daystring = (i < 10 ? '0' : '') + i;
if (window.opener.dateType == 'datetime' || window.opener.dateType == 'date') {
actVal = year + "-" + dispmonth + "-" + i;
actVal = yearstring + "-" + monthstring + "-" + daystring;
} else {
actVal = "" + (year < 1000 ? year < 100 ? year < 10 ? '000' : '00' : '0' : '') + year + (dispmonth < 10 ? '0' : '') + dispmonth + (i < 10 ? '0' : '') + i;
actVal = "" + yearstring + monthstring + daystring;
}
if (i == day) {
style = ' class="selected"';