mirror of
https://github.com/vrana/adminer.git
synced 2025-08-31 18:11:52 +02:00
Change logo link to main page (login)
This commit is contained in:
@@ -13,7 +13,7 @@ class Adminer {
|
|||||||
* @return string HTML code
|
* @return string HTML code
|
||||||
*/
|
*/
|
||||||
function name() {
|
function name() {
|
||||||
return "<a href='https://github.com/pematon/adminer'" . target_blank() . " id='h1'>Adminer</a>";
|
return "<a id='h1' href='" . h(HOME_URL) . "'>Adminer</a>";
|
||||||
}
|
}
|
||||||
|
|
||||||
/** Connection parameters
|
/** Connection parameters
|
||||||
|
@@ -147,7 +147,7 @@ if ($auth) {
|
|||||||
set_session($key, null);
|
set_session($key, null);
|
||||||
}
|
}
|
||||||
unset_permanent();
|
unset_permanent();
|
||||||
redirect(substr(preg_replace('~\b(username|db|ns)=[^&]*&~', '', ME), 0, -1), lang('Logout successful.') . ' ' . lang('Thanks for using Adminer, consider <a href="https://www.adminer.org/en/donation/">donating</a>.'));
|
redirect(HOME_URL, lang('Logout successful.') . ' ' . lang('Thanks for using Adminer, consider <a href="https://www.adminer.org/en/donation/">donating</a>.'));
|
||||||
|
|
||||||
} elseif ($permanent && !$_SESSION["pwds"]) {
|
} elseif ($permanent && !$_SESSION["pwds"]) {
|
||||||
session_regenerate_id();
|
session_regenerate_id();
|
||||||
|
@@ -113,6 +113,7 @@ define("ME", preg_replace('~\?.*~', '', relative_uri()) . '?'
|
|||||||
. (isset($_GET["username"]) ? "username=" . urlencode($_GET["username"]) . '&' : '')
|
. (isset($_GET["username"]) ? "username=" . urlencode($_GET["username"]) . '&' : '')
|
||||||
. (DB != "" ? 'db=' . urlencode(DB) . '&' . (isset($_GET["ns"]) ? "ns=" . urlencode($_GET["ns"]) . "&" : "") : '')
|
. (DB != "" ? 'db=' . urlencode(DB) . '&' . (isset($_GET["ns"]) ? "ns=" . urlencode($_GET["ns"]) . "&" : "") : '')
|
||||||
);
|
);
|
||||||
|
define("HOME_URL", substr(preg_replace('~\b(username|db|ns)=[^&]*&~', '', ME), 0, -1) ?: ".");
|
||||||
|
|
||||||
include "../adminer/include/version.inc.php";
|
include "../adminer/include/version.inc.php";
|
||||||
include "../adminer/include/design.inc.php";
|
include "../adminer/include/design.inc.php";
|
||||||
|
@@ -62,8 +62,7 @@ function page_header($title, $error = "", $breadcrumb = [], $title2 = "") {
|
|||||||
if ($breadcrumb !== null) {
|
if ($breadcrumb !== null) {
|
||||||
echo '<p id="breadcrumb">';
|
echo '<p id="breadcrumb">';
|
||||||
|
|
||||||
$link = substr(preg_replace('~\b(username|db|ns)=[^&]*&~', '', ME), 0, -1);
|
echo '<a href="' . h(HOME_URL) . '">' . lang('Home') . '</a> » ';
|
||||||
echo '<a href="' . h($link ?: ".") . '">' . lang('Home') . '</a> » ';
|
|
||||||
|
|
||||||
$server = "";
|
$server = "";
|
||||||
if ($breadcrumb === false) {
|
if ($breadcrumb === false) {
|
||||||
|
@@ -6,7 +6,7 @@ class Adminer {
|
|||||||
var $_values = array();
|
var $_values = array();
|
||||||
|
|
||||||
function name() {
|
function name() {
|
||||||
return "<a href='https://www.adminer.org/editor/'" . target_blank() . " id='h1'>" . lang('Editor') . "</a>";
|
return "<a id='h1' href='" . h(HOME_URL) . "'>" . lang('Editor') . "</a>";
|
||||||
}
|
}
|
||||||
|
|
||||||
//! driver, ns
|
//! driver, ns
|
||||||
|
Reference in New Issue
Block a user