Browse Source

Un-inline some crap

spaghetti 8 years ago
parent
commit
fd9aaf820c
3 changed files with 6 additions and 13 deletions
  1. 1
    1
      design/publicheader.php
  2. 1
    10
      sections/login/login.php
  3. 4
    2
      static/functions/script_start.js

+ 1
- 1
design/publicheader.php View File

@@ -23,7 +23,7 @@ define('FOOTER_FILE',SERVER_ROOT.'/design/publicfooter.php');
23 23
 <?
24 24
   }
25 25
   $img = array_diff(scandir(SERVER_ROOT.'/misc/bg', 1), array('.', '..')); ?>
26
-  <style> #content { background-image: url(<? echo("'/misc/bg/" . $img[rand(0,count($img)-1)] . "'"); ?>); }</style>
26
+  <meta id="bg_data" bg="<?=$img[rand(0,count($img)-1)]?>">
27 27
 </head>
28 28
 <body>
29 29
 <div id="head">

+ 1
- 10
sections/login/login.php View File

@@ -50,13 +50,4 @@ if ($Attempts > 0) {
50 50
   Forgot your password? <a href="login.php?act=recover" class="tooltip" title="Recover your password" style="text-decoration: underline;">Reset it here!</a>
51 51
 <?
52 52
 }
53
-?>
54
-<script type="text/javascript">
55
-cookie.set('cookie_test', 1, 1);
56
-if (cookie.get('cookie_test') != null) {
57
-  cookie.del('cookie_test');
58
-} else {
59
-  $('#no-cookies').gshow();
60
-}
61
-</script>
62
-<? View::show_footer(); ?>
53
+View::show_footer(); ?>

+ 4
- 2
static/functions/script_start.js View File

@@ -362,5 +362,7 @@ $.fn.extend({
362 362
   }
363 363
 });
364 364
 
365
-var authkey = document.head.children.auth_holder.attributes.authkey.value;
366
-var userid = parseInt(document.head.children.auth_holder.attributes.userid.value);
365
+if (document.head.children.auth_holder) {
366
+  var authkey = document.head.children.auth_holder.attributes.authkey.value;
367
+  var userid = parseInt(document.head.children.auth_holder.attributes.userid.value);
368
+}

Loading…
Cancel
Save