Mercurial > hg > batmud > maputils
changeset 1140:3bb8253db932
New website layout and some minor improvements.
author | Matti Hamalainen <ccr@tnsp.org> |
---|---|
date | Fri, 08 Jul 2011 02:17:22 +0300 |
parents | 06fd8ca64157 |
children | 33fcce8436c1 |
files | www/common.inc.php www/config.inc.php www/faq.xml www/index.php www/info.php www/latest.php www/loc.php www/quests.php www/ss.php |
diffstat | 9 files changed, 107 insertions(+), 92 deletions(-) [+] |
line wrap: on
line diff
--- a/www/common.inc.php Fri Jul 08 02:17:00 2011 +0300 +++ b/www/common.inc.php Fri Jul 08 02:17:22 2011 +0300 @@ -42,7 +42,10 @@ function printPageHeader($title, $extra = "") { - global $pageCharset, $pageAuthor; + global $pageCharset, $pageAuthor, $pageCSS; + +if (!isset($pageCSS)) + $pageCSS = "maps.css"; echo "<?xml version=\"1.0\" encoding=\"".$pageCharset."\"?>\n"; ?> @@ -52,7 +55,7 @@ <meta http-equiv="Content-Type" content="text/html; charset=<? echo $pageCharset ?>" /> <meta name="Author" content="<? echo $pageAuthor ?>" /> <title><? echo $title ?></title> - <link href="maps.css" rel="stylesheet" type="text/css" /> + <link href="<? echo $pageCSS ?>" rel="stylesheet" type="text/css" /> <meta name="keywords" content="batmud,map,laenor,lucentium,rothikgen,desolathya,furnachia,mud,mush,mmorpg,mmo,massively,multiplayer,online,network,game,ggr,pupunen"/> <link rel="shortcut icon" href="/maps/favicon.ico" type="image/x-icon" /> <?
--- a/www/config.inc.php Fri Jul 08 02:17:00 2011 +0300 +++ b/www/config.inc.php Fri Jul 08 02:17:22 2011 +0300 @@ -9,6 +9,6 @@ #$pageIndex = "maps.php"; $protocolPrefix = ($_SERVER["HTTPS"] == "off" || $_SERVER["HTTPS"] == "") ? "http" : "https"; -$pageMapURL = $protocolPrefix."://www.tnsp.org/maps/"; +$pageMapURL = $protocolPrefix."://tnsp.org/maps/"; ?> \ No newline at end of file
--- a/www/faq.xml Fri Jul 08 02:17:00 2011 +0300 +++ b/www/faq.xml Fri Jul 08 02:17:22 2011 +0300 @@ -259,6 +259,9 @@ closing of almost whole north-European airspace. </li><br /> + <li><b>08 Jul 2011</b> - PupuMaps site finally gets a new layout and various + smaller improvements. + </li><br /> </ul> More to come...
--- a/www/index.php Fri Jul 08 02:17:00 2011 +0300 +++ b/www/index.php Fri Jul 08 02:17:22 2011 +0300 @@ -2,7 +2,6 @@ require "config.inc.php"; require "common.inc.php"; - function printFileTD($fileName, $mapName, $useTD = TRUE) { if ($useTD) echo " <td>"; @@ -66,7 +65,10 @@ printPageHeader($pageTitle, "<link rel=\"search\" type=\"application/opensearchdescription+xml\" href=\"/maps/opensearch.xml\" title=\"PupuMaps\" />\n"); +require "menu.inc.php"; ?> + +<div id="contents"> <h1><? echo $pageTitle; ?></h1> <div id="intro"> @@ -77,59 +79,18 @@ to your browser. </div> -<table> -<tr> -<td width="75%"> -<h2>General Information</h2> -<ul> - <li>List of <a href="loc.php">scenics/locations of the whole world</a>, with coder information.</li> - - <li>List of <a href="latest.php">latest added locations</a>.</li> - - <li>Information about <a href="quests.php">level- and area quests</a> and their locations.</li> - - <li>List of <a href="loc.php?c">player cities</a>.</li> - - <li>List of <a href="ss.php">secret societies</a> (player guilds) and their locations.</li> - - <li>List of <a href="loc.php?c&n=limbo">player cities still in "limbo"</a> (aka cities - that have not been placed in the new world.)</li> - - <li><a href="info.php">List of Wizards</a> - the incomplete "who is who" database of BatMUD immortals.</li> - - <li>Answers to few <a href="faq.php">frequently asked questions</a>.</li> -</ul> -</td> - -<td> <? -include "donate.inc.php"; +require "donate.inc.php"; ?> -</td> - -<!-- -<td> -<div style="width: 200px; height: 244px; background: black url(ruoho2.png) no-repeat bottom center; padding: 0px;"> -<div style="width: 200px; height: 240px; background: url(snowfall.gif); padding: 0px;"> -<div style="width: 200px; height: 240px; background: url(bunny.gif) no-repeat bottom right; padding: 0px;"> -</div> -</div> -</div> - -</td> ---> -</tr> -</table> - <h2>Continents of BatMUD: Age of Exiles</h2> <div class="attnbox"> -<b>WARNING!</b> The alternative JavaScript-enhanced HTML-maps may +<b>WARNING!</b> The JavaScript-enhanced HTML-maps do not render properly in Internet Explorer and Opera at the moment. </div> -<table class="area" width="90%"> +<table class="area"> <tr> <th>Continent (HTML)</th> <th>JS + HTML</th> @@ -152,7 +113,7 @@ </p> <h2>Miscellaneous maps</h2> -<table class="area" width="90%"> +<table class="area"> <tr> <th>Area (HTML)</th> <th>JS + HTML</th> @@ -184,5 +145,26 @@ <p> <b>-- <a href="<? echo fingerURL('ggr'); ?>">Ggr Pupunen</a>, master of carrots.</b> </p> +</div> + +<div id="extrabox"> + <h1>Ggr's BatMUD con pictures</h1> +<? +$conpics = array( + + "Kepucon'10" => "kepucon2010", + "Kepucon'08" => "kepucon2008", + "Kepucon'07" => "kepucon2007", + "Kuopiocon'04" => "kuopiocon04" +); +foreach ($conpics as $id => $url) { + echo " <a href=\"http://tnsp.org/kuvia/bile/".$url."/\">".$id."</a>\n"; +} +?> + <h1>Other links</h1> + <a href="http://tnsp.org/~ccr/ggrtf/">GgrTF</a> + <a href="http://tnsp.org/~ccr/bat/">Ggr's Bat page</a> +</div> + </body> </html>
--- a/www/info.php Fri Jul 08 02:17:00 2011 +0300 +++ b/www/info.php Fri Jul 08 02:17:22 2011 +0300 @@ -5,8 +5,10 @@ /* Page start */ printPageHeader($pageTitle." - Wizards of the Realm"); -//echo "<div><b>DEVELOPMENT VERSION</b></div>"; + +require "menu.inc.php"; ?> +<div id="contents"> <h1>Wizards of the Realm</h1> <div class="attnbox"> @@ -23,6 +25,7 @@ <b>Notice #3</b>: It is certainly possible, that some of this information is incorrect. Sorry for that. Please report to <? burl("Ggr") ?>, if you have Knowledge(tm). </div> +<hr /> <div style="text-align: center;"> <table style="background: black;"> <tr> @@ -30,7 +33,6 @@ <td style="background: #744">No wizard information entry.</td> </tr> </table> - [<a href="<? echo $pageIndex ?>">Back to main page</a>]<br /> </div> <? @@ -78,8 +80,8 @@ if (count($data) > 0) { usort($data, "wizardSort"); - echo "<h3><a name=\"".strtolower($alpha)."\"></a>".$alpha."</h3>\n"; - echo "<table class=\"loc\" width=\"95%\">\n"; + echo "<h3><a name=\"".$alpha."\"></a>".$alpha."</h3>\n"; + echo "<table class=\"loc\">\n"; $n = 0; foreach ($data as $wizard) { @@ -112,9 +114,20 @@ } echo "<p><b>".$totalWiz."</b> wizards.</p>\n"; + + /* Print out the alpha link index + */ + echo "<div id=\"extrabox\">\n". + " <div style=\"font-size: 12pt; padding: 5pt;\">\n"; + foreach ($alphaTable as $alpha => $alphaLocs) { + echo " <a href=\"#".$alpha."\">".$alpha."</a> \n"; + } + echo "\n </div>\n". + "</div>\n"; } else { echo "<p><b>No wizards known!</b></p>\n"; } ?> +</div> </body> </html>
--- a/www/latest.php Fri Jul 08 02:17:00 2011 +0300 +++ b/www/latest.php Fri Jul 08 02:17:22 2011 +0300 @@ -2,17 +2,19 @@ require "config.inc.php"; require "common.inc.php"; +$locTable = readLocationFiles(FALSE); + /* Page start */ printPageHeader($pageTitle." - Latest added locations"); //echo "<div><b>DEVELOPMENT VERSION</b></div>"; -$locTable = readLocationFiles(FALSE); - +require "menu.inc.php"; /* Header */ ?> +<div id="contents"> <h1>Latest added locations</h1> <div class="attnbox"> @@ -25,9 +27,6 @@ </ol> In any case, the idea of this list is to approximately show what has been added in recently. </div> -<div style="text-align: center;"> -[<a href="<? echo $pageIndex ?>">Back to main page</a>] -</div> <hr /> <? // Compare two location records by addition date timestamp and primary name @@ -101,5 +100,6 @@ echo "<p><b>No locations known!</b></p>\n"; } ?> +</div> </body> </html>
--- a/www/loc.php Fri Jul 08 02:17:00 2011 +0300 +++ b/www/loc.php Fri Jul 08 02:17:22 2011 +0300 @@ -40,12 +40,6 @@ /* Initialization */ -printPageHeader($pageTitle." - Locations", - "<script type=\"text/javascript\" src=\"tooltip.js\"></script>\n". - "<meta name=\"robots\" content=\"nofollow\" />\n"); -//echo "<div><b>DEVELOPMENT VERSION</b></div>"; - - if (isset($_GET["c"])) { $filter = "C"; $applyFilter = TRUE; @@ -53,7 +47,7 @@ if (isset($_GET["f"]) && $_GET["f"] != "") { $filter = $_GET["f"]; if (!preg_match("/^[\^A-Za-z]+\$/", $filter)) { - echo "<h1>Invalid filter rule '".chentities($filter)."'</h1>\n"; + $errorStr = "Invalid filter rule '".chentities($filter)."'"; $filter = "C"; $applyFilter = FALSE; } else { @@ -82,7 +76,7 @@ if (file_exists($setName.".loc")) { parseLocFile($setName, $locTable, $applyFilter, $filter); } else { - echo "<h1>No such continent ID!</h1>\n"; + $errorStr = "No such continent ID!"; unset($setName); } } else { @@ -92,7 +86,16 @@ /* Start of the page */ -echo "<h1>"; +printPageHeader($pageTitle." - Locations", + "<script type=\"text/javascript\" src=\"tooltip.js\"></script>\n". + "<meta name=\"robots\" content=\"nofollow\" />\n"); + +require "menu.inc.php"; + +echo +"<div id=\"contents\">\n". +"<h1>"; + if ($applyFilter) { if (array_key_exists($filter, $locationTypes)) echo $locationTypes[$filter][2]; @@ -112,6 +115,9 @@ echo " by ".chentities($coderName); echo "</h1>\n"; +if (isset($errorStr)) + echo "<p style=\"color: red;\"><b>Error: ".$errorStr."</b>.</p>\n"; + ?> <div class="selbar"> <form action="<? echo $_SERVER["PHP_SELF"]; ?>" method="get"> @@ -122,7 +128,7 @@ <table> <tr> <td> - <select name="f"> + <select class="dropdown" name="f"> <? foreach ($locationTypes as $id => $type) { echo " <option value=\"".$id."\""; @@ -134,7 +140,7 @@ </select> </td> <td> - <input type="submit" value=" Update " class="isubmit" /> + <input type="submit" value=" Update " class="submit" /> </td> <td></td> <? @@ -145,7 +151,6 @@ } printTitleLink($applyFilter, $filter, $showCoders, "Special", "special", "special"); ?> - <td><a href="<? echo $pageIndex ?>">Main page</a></td> </tr> </table> </form> @@ -230,7 +235,7 @@ asort($alphaLocs); - echo "<h3><a name=\"".strtolower($alpha)."\"></a>".$alpha."</h3>\n". + echo "<h3><a name=\"".$alpha."\"></a>".$alpha."</h3>\n". "<table class=\"loc\" width=\"95%\">\n"; $n = 0; @@ -298,11 +303,12 @@ $fs = ""; foreach ($iv["coders"] as $name) { if ($fs != "") $fs .= ", "; + // Tags/flags of this coder in relation to the area switch ($name["flags"]) { - case NAME_ORIG: $qs = "title=\"Original creator\""; break; - case NAME_RECODER: $qs = "title=\"Converter, recoder\""; break; - case NAME_MAINTAINER: $qs = "title=\"Maintainer\""; break; - case NAME_EXPANDER: $qs = "title=\"Implemented new content, expansion(s)\""; break; + case NAME_ORIG: $qs = "title=\"Original creator\" class=\"wizorig\""; break; + case NAME_RECODER: $qs = "title=\"Converter, recoder\" class=\"wizrecoder\""; break; + case NAME_MAINTAINER: $qs = "title=\"Maintainer\" class=\"wizmaintainer\""; break; + case NAME_EXPANDER: $qs = "title=\"Implemented new content, expansion(s)\" class=\"wizexpander\""; break; default: $qs = ""; } if ($filter != "C" || !$applyFilter) @@ -332,6 +338,8 @@ echo "<p><b>".$totalLoc."</b> locations.</p>\n"; + echo "</div>\n"; + /* Print out location tooltip HTML code */ foreach ($locationTips as $tipID => $tip) { @@ -339,8 +347,19 @@ "\"><div class=\"holder\"><b>".chentities($tip["title"]). "</b><br />".$tip["desc"]."</div></div>\n"; } + + /* Print out the alpha link index + */ + echo "<div id=\"extrabox\">\n". + " <div style=\"font-size: 12pt; padding: 5pt;\">\n"; + foreach ($alphaTable as $alpha => $alphaLocs) { + echo " <a href=\"#".$alpha."\">".$alpha."</a> \n"; + } + echo "\n </div>\n". + "</div>\n"; } else { echo "<p><b>No locations known!</b></p>\n"; + echo "</div>\n"; } ?> </body>
--- a/www/quests.php Fri Jul 08 02:17:00 2011 +0300 +++ b/www/quests.php Fri Jul 08 02:17:22 2011 +0300 @@ -13,7 +13,10 @@ $hcbat = FALSE; } +require "menu.inc.php"; + ?> +<div id="contents"> <h1>BatMUD Quests</h1> <div class="attnbox"> @@ -25,11 +28,6 @@ for full details. </div> -<div style="text-align: center;"> -<br /> -[<a href="<? echo $pageIndex ?>">Back to main page</a>] -<br /> -</div> <? //======================================================================== // Create quest data tables @@ -131,5 +129,6 @@ } echo "</td></tr></table>\n"; ?> +</div> </body> </html>
--- a/www/ss.php Fri Jul 08 02:17:00 2011 +0300 +++ b/www/ss.php Fri Jul 08 02:17:22 2011 +0300 @@ -2,28 +2,23 @@ require "config.inc.php"; require "common.inc.php"; -/* Page start - */ -printPageHeader($pageTitle." - Secret societies"); -//echo "<div><b>DEVELOPMENT VERSION</b></div>"; - $locTable = readLocationFiles(TRUE, "C", TRUE); parseLocFile("limbo", $locTable, TRUE, "C"); +/* Page start + */ +printPageHeader($pageTitle." - Secret societies"); -/* Header - */ +require "menu.inc.php"; + ?> +<div id="contents"> <h1>Secret societies of BatMUD</h1> -<div style="text-align: center;"> -[<a href="<? echo $pageIndex ?>">Back to main page</a>] -<br /><br /> -</div> <? /* Print list of societies */ if (count($locTable) > 0) { - /* Make a list */ + /* Make the list array */ foreach ($locTable as $key => $value) { if (count($value["coders"]) > 0) { foreach ($value["coders"] as $name) { @@ -73,5 +68,6 @@ echo "<p><b>No societies known!</b></p>\n"; } ?> +</div> </body> </html>