Skip to content

Commit 5a7be23

Browse files
author
moglia
committed
Fixed url redirect for phpmyadmin if you use another port as not a standards ports. I tested on my production environment. If database is on another server i presume all of panels is on same port. If not need put a field called port on server table, or another way to solve it.
1 parent 337a826 commit 5a7be23

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

interface/web/sites/database_phpmyadmin.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@
5858
* We only redirect to the login-form, so there is no need, to check any rights
5959
*/
6060
isset($_SERVER['HTTPS'])? $http = 'https' : $http = 'http';
61-
header('location:' . $http . '://' . $serverData['server_name'] . '/phpmyadmin');
61+
($_SERVER["SERVER_PORT"] != '80')? $serverPort = ':'.$_SERVER["SERVER_PORT"] : $serverPort = '';
62+
header('location:'.$http.'://'.$serverData['server_name'].$serverPort.'/phpmyadmin');
6263
exit;
63-
6464
?>

0 commit comments

Comments
 (0)