summaryrefslogtreecommitdiffstats
path: root/pages/home.php
diff options
context:
space:
mode:
Diffstat (limited to 'pages/home.php')
-rw-r--r--pages/home.php20
1 files changed, 3 insertions, 17 deletions
diff --git a/pages/home.php b/pages/home.php
index 31ea756..544b3fe 100644
--- a/pages/home.php
+++ b/pages/home.php
@@ -219,37 +219,23 @@ function displayMaze($motd, $mapType) {
$r = "<div id=\"yms-$mapType\" class='hidden-maps'>";
$r .= " <div class='wrapper'>";
-
$r .= " <div style='text-align: center;'>";
$r .= " <div style='display:inline-block;margin: 0 auto;text-align: left;'>";
$r .= " <a href='javascript:requestSol(\"$mapID\");'><strong>Load your best solution</strong></a><br />";
- //TMP
-
- $mapObj = new map(getMapCode($mapID), $mapID);
- $mapJSON = json_encode($mapObj);
- $r .= "<div id='innerMapDsp_$mapID'>";
- $r .= "</div>";
+ $r .= "<div id='innerMapDsp_$mapID'>\n";
+ $r .= "</div>\n";
$r .= "<script>";
- $r .= "document.getElementById('innerMapDsp_$mapID').innerHTML = mapAsHTML(decryptJSON('$mapJSON'));";
+ $r .= "displayMap($mapID, 'innerMapDsp_$mapID', false, '$mysolution', '$mymoves');";
$r .= "</script>";
-
-
//$r .= DisplayMap($map, $mapID);
$r .= " </div></div>";
-
$r .= " <div style='padding-top: 20px;'>";
$r .= $topscorediv;
$r .= ' </div>';
-
$r .= ' </div>';
$r .= '</div>';
-
- $mapSolDiv = "<script>
- loadSol(\"$mapID:$mysolution\", \"$mymoves\");
- </script>";
- $r .= $mapSolDiv;
//Clear our floatingness
$r .= '<div style="clear: both"></div>';