summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPatrick Davison <snapwilliam@gmail.com>2012-12-26 12:44:09 -0800
committerPatrick Davison <snapwilliam@gmail.com>2012-12-26 12:44:09 -0800
commita802a419b5a3ce7a70ece8465dad777daefcbfa5 (patch)
tree8713c5638e32bd5f988c5c9a2c2ebe87722315ef
parent9c19883cda818b25bf9b5fe5ad1e39af6b28c957 (diff)
downloadpathery-a802a419b5a3ce7a70ece8465dad777daefcbfa5.tar.xz
SoundManager1/2 moved to a function in Globe.
-rw-r--r--globe.php45
-rw-r--r--pages/home.php40
2 files changed, 44 insertions, 41 deletions
diff --git a/globe.php b/globe.php
index 9e13d99..32285fc 100644
--- a/globe.php
+++ b/globe.php
@@ -13,6 +13,45 @@ $mydomain = "http://www.pathery.com/";
//include_once("./includes/header.php");
+
+function soundManager1() {
+return '
+ <div>
+<script src="sounds/script/soundmanager.js"></script>
+<script type="text/javascript">soundManagerInit();</script>
+ </div>
+ ';
+}
+
+function soundManager2() {
+return "
+<script src='sounds/script/soundmanager2-nodebug-jsmin.js'></script>
+<script>
+soundManager.setup({
+ url: '/sounds/swf/',
+ flashVersion: 9, // optional: shiny features (default = 8)
+ useFlashBlock: false, // optionally, enable when you're ready to dive in/**
+ onready: function() {
+ // Ready to use; soundManager.createSound() etc. can now be called.
+ soundManager.createSound({id: 'achieve',url: '/sounds/achieve.mp3',autoLoad: true,volume: 50});
+ soundManager.createSound({id: 'ufoblip', url: '/sounds/ufoblip.mp3',autoLoad: true,volume: 50});
+ soundManager.createSound({id: 'bling', url: '/sounds/bling.mp3',autoLoad: true,volume: 50});
+ soundManager.createSound({id: 'blingb', url: '/sounds/blingb.mp3',autoLoad: true,volume: 50});
+ soundManager.createSound({id: 'charm',url: '/sounds/charm.mp3',autoLoad: true,volume: 50});
+ soundManager.createSound({id: 'blip',url: '/sounds/blip.mp3',autoLoad: true,volume: 50});
+ soundManager.createSound({id: 'cap',url: '/sounds/cap.mp3'});
+ soundManager.createSound({id: 'click',url: '/sounds/click.mp3'});
+ soundManager.createSound({id: 'sc',url: '/sounds/transmission.mp3'});
+ soundManager.createSound({id: 'hologram',url: '/sounds/hologram.mp3'});
+ }
+});
+</script>
+";
+}
+
+
+
+
function sql_clean($string) {
if (get_magic_quotes_gpc()) {
$string = stripslashes($string);
@@ -66,11 +105,6 @@ function CookieLogin() {
header("Location: $mydomain");
}
-
-
-
-
-
Function DoLogin($Username, $Password, $RememberMe = False, $EN = False) {
If ($EN == False) {
@@ -113,7 +147,6 @@ Function DoLogin($Username, $Password, $RememberMe = False, $EN = False) {
}
}
-
Function CheckAuth($page) {
//TODO:
if ($_SESSION['Accepted'] == 1) {
diff --git a/pages/home.php b/pages/home.php
index ac2518f..7a197aa 100644
--- a/pages/home.php
+++ b/pages/home.php
@@ -44,39 +44,9 @@ if (getCookie('pref_mute') != 'true') {
?>
<?
-$soundManager1 = '
- <div>
-<script src="sounds/script/soundmanager.js"></script>
-<script type="text/javascript">soundManagerInit();</script>
- </div>
- ';
-$soundManager2 = "
-<script src='sounds/script/soundmanager2-nodebug-jsmin.js'></script>
-<script>
-soundManager.setup({
- url: '/sounds/swf/',
- flashVersion: 9, // optional: shiny features (default = 8)
- useFlashBlock: false, // optionally, enable when you're ready to dive in/**
- onready: function() {
- // Ready to use; soundManager.createSound() etc. can now be called.
- soundManager.createSound({id: 'achieve',url: '/sounds/achieve.mp3',autoLoad: true,volume: 50});
- soundManager.createSound({id: 'ufoblip', url: '/sounds/ufoblip.mp3',autoLoad: true,volume: 50});
- soundManager.createSound({id: 'bling', url: '/sounds/bling.mp3',autoLoad: true,volume: 50});
- soundManager.createSound({id: 'blingb', url: '/sounds/blingb.mp3',autoLoad: true,volume: 50});
- soundManager.createSound({id: 'charm',url: '/sounds/charm.mp3',autoLoad: true,volume: 50});
- soundManager.createSound({id: 'blip',url: '/sounds/blip.mp3',autoLoad: true,volume: 50});
- soundManager.createSound({id: 'cap',url: '/sounds/cap.mp3'});
- soundManager.createSound({id: 'click',url: '/sounds/click.mp3'});
- soundManager.createSound({id: 'sc',url: '/sounds/transmission.mp3'});
- soundManager.createSound({id: 'hologram',url: '/sounds/hologram.mp3'});
- }
-});
-</script>
-";
-
-//echo $soundManager1;
-echo $soundManager2;
+//echo soundManager1();
+echo soundManager2();
?>
@@ -281,8 +251,8 @@ function displayMaze($motd, $mapType) {
$timerem = strtotime("tomorrow") - strtotime("now");
?>
- <div style='text-align: center; margin-top: 5px; position:fixed; bottom:20px; left:20px;'>
- <span id="countdown">New maps</span>
+ <div>
+ <span id="countdown" title="This time is relative to your computer's clock">Loading...</span>
</div>
<script type="text/javascript">
var countdownInt = self.setInterval(countdown, 1000);
@@ -313,7 +283,7 @@ $timerem = strtotime("tomorrow") - strtotime("now");
var stamp = hours + ":" + minutes;
//if (hours < 1 && minutes < 5)
stamp = stamp + ":" + seconds
- stamp = 'New maps ' + formatedTomorrow + '<br />Time remaining: ' + stamp;
+ stamp = 'New maps: ' + formatedTomorrow + '<br />Time remaining: ' + stamp;
document.getElementById("countdown").innerHTML = stamp;
if (totalSeconds <= 1 && userConfirm == true) {