Ignore:
Timestamp:
04/19/13 13:00:56 (12 years ago)
Author:
tbretz
Message:
Use some more jquery features; load local version of jquery.
Location:
trunk/FACT++/www/showlog
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/FACT++/www/showlog/index.css

    r15375 r15376  
    11.up {
    2     cursor:pointer;
    32    padding:0 5px 4px 7px;
    43    position:fixed;
    54    top:0;
    65    right:0;
    7     text-decoration:underline;
    8     color:navy;
    96    background-color:#ebe7e6;
    107}
    118
    129.dn {
    13     cursor:pointer;
    1410    padding:0 5px 4px 7px;
    1511    padding-top:0px;
     
    1713    bottom:0;
    1814    right:0;
    19     text-decoration:underline;
    20     color:navy;
    2115    background-color:#ebe7e6;
    2216}
     
    2418#nav {
    2519    position:fixed;
    26     right:80px;
     20    right:90px;
    2721    top:0;
    2822    background-color:#ebe7e6;
  • trunk/FACT++/www/showlog/index.php

    r15375 r15376  
    351351$dir  = basename(dirname($filename));
    352352$name = basename($filename);
    353 
    354353?>
     354
    355355<!DOCTYPE HTML>
    356356<html>
     
    362362<meta charset="UTF-8">
    363363<title><?php print($dir." - ".$name);?></title>
    364 <link rel="stylesheet" type="text/css" href="showlog.css" />
    365 <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.6.1/jquery.min.js" type="text/javascript"></script>
     364<link rel="stylesheet" type="text/css" href="index.css" />
     365<script src="jquery-2.0.0.min.js" type="text/javascript"></script>
    366366<script>
    367 function scroll(top)
    368 {
    369    document.getElementById(top?'top':'bottom').scrollIntoView(top);
    370 }
    371 $(document).ready(function() {
    372         $("#nav li:has(ul)").hover(function(){
    373                 $(this).find("ul").slideDown(200);
    374         }, function(){
    375                 $(this).find("ul").hide();
    376         });
     367$(function(){
     368   $("#nav li:has(ul)").hover(function(){
     369      $(this).find("ul").slideDown(200);
     370   }, function(){
     371      $(this).find("ul").hide();
     372   });
    377373});
    378374</script>
    379375</head>
    380 <body onload="setTimeout(function(){scroll(false);},1);">
    381 <span onclick="scroll(true);" class="up">go to top &uarr;</span>
     376<body onload="if (location.hash.length==0) location.hash = '#bottom';">
     377<a class="up" href="#top">go to top &uarr;</a>
    382378<span id="nav">
    383379   <ul>
     
    411407</span>
    412408</span>
    413 <span onclick="scroll(false);" class="dn">go to bottom &darr;</span>
     409<a class="dn" href="#bottom">go to bottom &darr;</a>
    414410
    415411
     
    423419
    424420</pre>
    425 <span id="bottom"></span>
     421<div id="bottom"></div>
    426422</body>
    427423</html>
Note: See TracChangeset for help on using the changeset viewer.