mirror of
https://github.com/glest/glest-source.git
synced 2025-08-29 19:00:07 +02:00
* Add preliminary server side support for linking to gameservers on the web
* Fix typo on masterserver HTML output refresh header * Better style for masterserver HTML output
This commit is contained in:
@@ -15,6 +15,19 @@
|
|||||||
// allow for filtering by gameserver version
|
// allow for filtering by gameserver version
|
||||||
define( 'FILTER_VERSION', $_GET['version'] );
|
define( 'FILTER_VERSION', $_GET['version'] );
|
||||||
|
|
||||||
|
define( 'MGG_HOST', $_GET['mgg_host'] );
|
||||||
|
define( 'MGG_PORT', $_GET['mgg_port'] );
|
||||||
|
|
||||||
|
if ( MGG_HOST != '' ) {
|
||||||
|
$body = MGG_HOST . ':' . MGG_PORT;
|
||||||
|
header( 'Content-Type: application/x-megaglest-gameserver; charset=utf-8' );
|
||||||
|
header( 'Content-Disposition: attachment; filename="megaglest_gameserver.mgg' );
|
||||||
|
header( 'Content-Length: ' . strlen( $body ));
|
||||||
|
header( 'Accept-Ranges: bytes' );
|
||||||
|
echo $body;
|
||||||
|
exit;
|
||||||
|
}
|
||||||
|
|
||||||
// consider replacing this by a cron job
|
// consider replacing this by a cron job
|
||||||
cleanupServerList();
|
cleanupServerList();
|
||||||
|
|
||||||
@@ -34,7 +47,7 @@
|
|||||||
header( 'Content-Type: text/html; charset=utf-8' );
|
header( 'Content-Type: text/html; charset=utf-8' );
|
||||||
if ( REFRESH_INTERVAL != 0 ) {
|
if ( REFRESH_INTERVAL != 0 ) {
|
||||||
if ( REFRESH_INTERVAL <= 10 ) {
|
if ( REFRESH_INTERVAL <= 10 ) {
|
||||||
header( 'Refresh: 10:' );
|
header( 'Refresh: 10' );
|
||||||
} else {
|
} else {
|
||||||
header( 'Refresh: ' . REFRESH_INTERVAL );
|
header( 'Refresh: ' . REFRESH_INTERVAL );
|
||||||
}
|
}
|
||||||
|
@@ -9,6 +9,10 @@ body {
|
|||||||
font-family: sans-serif;
|
font-family: sans-serif;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
h1 {
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
|
||||||
table {
|
table {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
border: 2px solid black;
|
border: 2px solid black;
|
||||||
@@ -17,7 +21,12 @@ table {
|
|||||||
th, td {
|
th, td {
|
||||||
border: 1px solid black;
|
border: 1px solid black;
|
||||||
padding: 5px;
|
padding: 5px;
|
||||||
text-align: left;
|
text-align: center;
|
||||||
|
text-transform: capitalize;
|
||||||
|
}
|
||||||
|
|
||||||
|
th {
|
||||||
|
background-color: LightGray;
|
||||||
}
|
}
|
||||||
|
|
||||||
.waiting_for_players {
|
.waiting_for_players {
|
||||||
@@ -33,7 +42,7 @@ th, td {
|
|||||||
}
|
}
|
||||||
|
|
||||||
.finished {
|
.finished {
|
||||||
background-color: LightGray;
|
background-color: Gray;
|
||||||
}
|
}
|
||||||
|
|
||||||
.unknown {
|
.unknown {
|
||||||
|
Reference in New Issue
Block a user