Set MySQL time zone by PHP setting only in Editor
This commit is contained in:
parent
d8cba0eb5d
commit
e89f42d466
|
@ -251,7 +251,6 @@ if (!defined("DRIVER")) {
|
||||||
$credentials = $adminer->credentials();
|
$credentials = $adminer->credentials();
|
||||||
if ($connection->connect($credentials[0], $credentials[1], $credentials[2])) {
|
if ($connection->connect($credentials[0], $credentials[1], $credentials[2])) {
|
||||||
$connection->query("SET sql_quote_show_create = 1");
|
$connection->query("SET sql_quote_show_create = 1");
|
||||||
$connection->query("SET time_zone = " . $connection->quote(substr_replace(@date("O"), ":", -2, 0))); // date("P") available since PHP 5.1.3, @ - requires date.timezone since PHP 5.3.0
|
|
||||||
return $connection;
|
return $connection;
|
||||||
}
|
}
|
||||||
return $connection->error;
|
return $connection->error;
|
||||||
|
|
|
@ -10,12 +10,12 @@ Parse UTF-16 and UTF-8 BOM in all text uploads
|
||||||
Display ; in history (thanks to Jan Cerny)
|
Display ; in history (thanks to Jan Cerny)
|
||||||
Use DELIMITER in history
|
Use DELIMITER in history
|
||||||
Show databases even with skip_show_database in MySQL 5 (thanks to Radoslaw Kowalewski)
|
Show databases even with skip_show_database in MySQL 5 (thanks to Radoslaw Kowalewski)
|
||||||
Set MySQL time zone by PHP setting
|
|
||||||
Disable maxlength with functions in edit
|
Disable maxlength with functions in edit
|
||||||
Better placement of AJAX icon
|
Better placement of AJAX icon
|
||||||
Table header in CSV export (Editor)
|
Table header in CSV export (Editor)
|
||||||
Time format hint (Editor)
|
Time format hint (Editor)
|
||||||
Respect order after search (Editor)
|
Respect order after search (Editor)
|
||||||
|
Set MySQL time zone by PHP setting (Editor)
|
||||||
Allow own code in <head> (customization)
|
Allow own code in <head> (customization)
|
||||||
Polish translation
|
Polish translation
|
||||||
|
|
||||||
|
|
|
@ -50,6 +50,8 @@ document.getElementById('username').focus();
|
||||||
}
|
}
|
||||||
|
|
||||||
function login($login, $password) {
|
function login($login, $password) {
|
||||||
|
global $connection;
|
||||||
|
$connection->query("SET time_zone = " . q(substr_replace(@date("O"), ":", -2, 0))); // date("P") available since PHP 5.1.3, @ - requires date.timezone since PHP 5.3.0
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue