|
|
Line 26: |
Line 26: |
| </ul></div> | | </ul></div> |
| </body> | | </body> |
- | </html>
| |
| | | |
- |
| |
- | <html>
| |
- | <!-- JAVASCRIPTS -->
| |
- | <!-- *********** -->
| |
- |
| |
- |
| |
- |
| |
- | <!-- ie9.js (fixes all Internet Explorer browsers older than ie9) -->
| |
- | <!--[if lt IE 9]>
| |
- | <script src="http://ie7-js.googlecode.com/svn/version/2.1(beta4)/IE9.js"></script>
| |
- | <![endif]-->
| |
- |
| |
- | <!-- jQuery Tools (slider) -->
| |
- | <script src="http://cdn.jquerytools.org/1.2.5/full/jquery.tools.min.js"></script>
| |
- | <script>
| |
- | $(function() {
| |
- | // initialize scrollable
| |
- | $(".scrollable").scrollable().navigator();
| |
- | });
| |
- | </script>
| |
- |
| |
- | <!-- Navigation scroll follow -->
| |
- | <script type="text/javascript">
| |
- | var prevScrollPos = -1000;
| |
- | $(window).scroll(function () {
| |
- |
| |
- | <!-- here is added table of content fixing to screen : was all 35 with Title OutsideWhitebox-->
| |
- | var scrollPos = Math.floor($(window).scrollTop());
| |
- |
| |
- | if(Math.abs(prevScrollPos - scrollPos) <= 1){
| |
- | return "nuthin";
| |
- | }
| |
- |
| |
- |
| |
- | var toc_margin_from_top = $(".navigation").height() + 35;
| |
- | var scroll_pos_above_start_of_article = scrollPos < $(".whitebox.article").offset().top - 68;
| |
- | var toc_end_reached_bottom_of_article = scrollPos + toc_margin_from_top + $(".toc").height() > $(".whitebox.article").offset().top + $(".whitebox.article").height() - 35;
| |
- | var toc_margin_from_title = scrollPos < ($(".whitebox.article").offset().top );
| |
- |
| |
- |
| |
- |
| |
- | if(scroll_pos_above_start_of_article){
| |
- | $(".toc").offset({top: $(".whitebox.article").offset().top + 68});
| |
- | } else if(toc_end_reached_bottom_of_article){
| |
- | $(".toc").offset({top: $(".whitebox.article").offset().top + $(".whitebox.article").height() - $(".toc").height() - 35});
| |
- | } else if(toc_margin_from_title){
| |
- | $(".toc").offset({top: $(".whitebox.article").offset().top + 68});
| |
- | } else {
| |
- | $(".toc").offset({top: scrollPos + toc_margin_from_top});
| |
- | }
| |
- | <!-- new attempt to fix menubar (jakob) -->
| |
- |
| |
- | var scroll_pos_above_menubar = scrollPos < 250;
| |
- |
| |
- | if(scroll_pos_above_menubar){
| |
- | $(".navigation").offset({top: 250 });
| |
- | } else {
| |
- | $(".navigation").offset({top: scrollPos});
| |
- | }
| |
- |
| |
- | //if (scroll_pos_below_start_of_article){ //&& (scrollPos < $(document).height() - $(".navigation")[0].height() - 70)) {
| |
- | // $(".toc").addClass("stickBelowNavigation");
| |
- | //} else {
| |
- | // $(".toc").removeClass("stickBelowNavigation");
| |
- | //}
| |
- | });
| |
- | </script>
| |
- |
| |
- | <!-- MathJax (LaTeX for the web) -->
| |
- | <script type="text/x-mathjax-config">
| |
- | MathJax.Hub.Config({tex2jax: {inlineMath: [['$','$'], ['\\(','\\)']]}});
| |
- | MathJax.Hub.Config({
| |
- | TeX: {
| |
- | equationNumbers: { autoNumber: "AMS" }
| |
- | }
| |
- | });
| |
- | </script>
| |
- | <script type="text/javascript" src="http://cdn.mathjax.org/mathjax/latest/MathJax.js?config=TeX-AMS-MML_HTMLorMML"></script>
| |
- |
| |
- | <!-- Drop Down navigation -->
| |
- | <script type="text/javascript">
| |
- | $(document).ready(
| |
- | function(){
| |
- | $("ul.subnav").parent().find("> a").append("<span> ▼</span>");
| |
- | $("ul.topnav li").hover(
| |
- | function() {
| |
- | // Hover over
| |
- | $(this).parent().find("ul.subnav").hide();
| |
- | $(this).find("ul.subnav").show();
| |
- | // Hover out
| |
- | $(this).hover(
| |
- | function() {
| |
- | },
| |
- | function(){
| |
- | $(this).find("ul.subnav").hide();
| |
- | }
| |
- | );
| |
- | },
| |
- | function(){
| |
- | $(this).find("ul.subnav").hide();
| |
- | }
| |
- |
| |
- | );
| |
- | }
| |
- | );
| |
- | </script>
| |
- |
| |
- | <!-- iGem wiki hacks -->
| |
- | <!-- Remove all empty <p> tags -->
| |
- | <script type="text/javascript">
| |
- | $(document).ready(function() {
| |
- | $("p").filter( function() {
| |
- | return $.trim($(this).html()) == '';
| |
- | }).remove();
| |
- | });
| |
- | </script>
| |
- |
| |
- | <!-- Remove "team" from the menubar -->
| |
- | <script type="text/javascript">
| |
- | $(document).ready(function() {
| |
- | $("menubar > ul > li:last-child").remove();
| |
- | });
| |
- | </script>
| |
- |
| |
- | <!-- If Empty heading -> Then remove it -->
| |
- | <script type="text/javascript">
| |
- | $(document).ready(function() {
| |
- | if ("" == "</html>{{{1}}}<html>") {
| |
- | $("#heading").remove();
| |
- | }
| |
- | });
| |
- | </script>
| |
- | <script type="text/javascript">
| |
- | $(document).ready(function(){
| |
- | $("div.thumbinner > a img").slimbox({/* Put custom options here */}, function(el) {
| |
- | url = el.src;
| |
- | if (url.indexOf('thumb') != -1) {
| |
- | url = url.substring(0, url.lastIndexOf('/'));
| |
- | url = url.replace('/thumb/', '/');
| |
- | }
| |
- | description = $(el).parents("div.thumbinner").children("div.thumbcaption").text();
| |
- | return [url, description];
| |
- | }, function(el) {
| |
- | return (this == el);
| |
- | });
| |
- | });
| |
- | </script>
| |
| </html> | | </html> |