Team:Stanford-Brown/Templates/Main

From 2012.igem.org

(Difference between revisions)
Line 45: Line 45:
popupWindow = window.open(url,'popUpWindow','innerHeight=600,innerWidth=800,left=(screen.availwidth-width)/2,top=(screen.availheight-height)/2,resizable=no,scrollbars=no,toolbar=no,menubar=no,location=no,directories=no,status=no')
popupWindow = window.open(url,'popUpWindow','innerHeight=600,innerWidth=800,left=(screen.availwidth-width)/2,top=(screen.availheight-height)/2,resizable=no,scrollbars=no,toolbar=no,menubar=no,location=no,directories=no,status=no')
}
}
 +
</script>
 +
<script type="text/javascript">
 +
(function($) {
 +
/*
 +
jquery.twitter.js v1.5
 +
Last updated: 08 July 2009
 +
 +
Created by Damien du Toit
 +
http://coda.co.za/blog/2008/10/26/jquery-plugin-for-twitter
 +
 +
Licensed under a Creative Commons Attribution-Non-Commercial 3.0 Unported License
 +
http://creativecommons.org/licenses/by-nc/3.0/
 +
*/
 +
 +
$.fn.getTwitter = function(options) {
 +
 +
$.fn.getTwitter.defaults = {
 +
userName: null,
 +
numTweets: 1,
 +
loaderText: "Loading tweet...",
 +
slideIn: true,
 +
slideDuration: 750,
 +
showHeading: true,
 +
headingText: "Latest Tweets",
 +
showProfileLink: true,
 +
showTimestamp: true
 +
};
 +
 +
var o = $.extend({}, $.fn.getTwitter.defaults, options);
 +
 +
return this.each(function() {
 +
var c = $(this);
 +
 +
// hide container element, remove alternative content, and add class
 +
c.hide().empty().addClass("twitted");
 +
 +
// add heading to container element
 +
if (o.showHeading) {
 +
c.append("<h2>"+o.headingText+"</h2>");
 +
}
 +
 +
// add Twitter profile link to container element
 +
if (o.showProfileLink) {
 +
var profileLinkHTML = "<p class=\"profileLink\"><a href=\"http://twitter.com/"+o.userName+"\">http://twitter.com/"+o.userName+"</a></p>";
 +
c.append(profileLinkHTML);
 +
}
 +
 +
// add twitter list to container element
 +
var twitterListHTML = "<ul id=\"twitter_update_list\"><li></li></ul>";
 +
c.append(twitterListHTML);
 +
 +
var tl = $("#twitter_update_list");
 +
 +
// hide twitter list
 +
tl.hide();
 +
 +
// add preLoader to container element
 +
var preLoaderHTML = $("<p class=\"preLoader\">"+o.loaderText+"</p>");
 +
c.append(preLoaderHTML);
 +
 +
// show container element
 +
c.show();
 +
 +
$.getScript("http://twitter.com/javascripts/blogger.js");
 +
$.getScript("http://twitter.com/statuses/user_timeline/"+o.userName+".json?callback=twitterCallback2&count="+o.numTweets, function() {
 +
// remove preLoader from container element
 +
$(preLoaderHTML).remove();
 +
 +
// remove timestamp and move to title of list item
 +
if (!o.showTimestamp) {
 +
tl.find("li").each(function() {
 +
var timestampHTML = $(this).children("a");
 +
var timestamp = timestampHTML.html();
 +
timestampHTML.remove();
 +
$(this).attr("title", timestamp);
 +
});
 +
}
 +
 +
// show twitter list
 +
if (o.slideIn) {
 +
var tlHeight = tl.data("originalHeight");
 +
 +
// get the original height
 +
if (!tlHeight) {
 +
tlHeight = tl.show().height();
 +
tl.data("originalHeight", tlHeight);
 +
tl.hide().css({height: 0});
 +
}
 +
 +
tl.show().animate({height: tlHeight}, o.slideDuration);
 +
}
 +
else {
 +
tl.show();
 +
}
 +
 +
// add unique class to first list item
 +
tl.find("li:first").addClass("firstTweet");
 +
 +
// add unique class to last list item
 +
tl.find("li:last").addClass("lastTweet");
 +
});
 +
});
 +
};
 +
})(jQuery);
</script>
</script>
<script type="text/javascript">
<script type="text/javascript">
Line 313: Line 417:
<link href='http://fonts.googleapis.com/css?family=Ubuntu:regular,bold&subset=latin' rel='stylesheet' type='text/css'>
<link href='http://fonts.googleapis.com/css?family=Ubuntu:regular,bold&subset=latin' rel='stylesheet' type='text/css'>
 +
        <style>
 +
span.reference{
 +
position:fixed;
 +
left:10px;
 +
bottom:10px;
 +
font-size:12px;
 +
}
 +
span.reference a{
 +
color:#aaa;
 +
text-transform:uppercase;
 +
text-decoration:none;
 +
text-shadow:1px 1px 1px #000;
 +
margin-right:30px;
 +
}
 +
span.reference a:hover{
 +
color:#ddd;
 +
}
 +
ul.sdt_menu{
 +
margin-top:150px;
 +
}
 +
</style>
<link rel="stylesheet" type="text/css" href="https://2012.igem.org/Team:Stanford-Brown/Templates/css?action=raw&ctype=text/css" />
<link rel="stylesheet" type="text/css" href="https://2012.igem.org/Team:Stanford-Brown/Templates/css?action=raw&ctype=text/css" />
</head>
</head>
<body>
<body>
-
<div class="logo">
+
<div style="margin-left: auto; margin-right: auto; margin-top:-15px; z-index:-10; text-align: center;">
<a href="/Team:Stanford-Brown" style="text-decoration: none !important;">
<a href="/Team:Stanford-Brown" style="text-decoration: none !important;">
<img src="https://static.igem.org/mediawiki/2012/a/ae/SBHeader.gif">
<img src="https://static.igem.org/mediawiki/2012/a/ae/SBHeader.gif">
Line 324: Line 449:
-
<div id="header">
+
<div id="header" style="height:100px; padding: 0px 0px 0px 0px; margin-bottom:0px">
  <ul id="sdt_menu" class="sdt_menu">
  <ul id="sdt_menu" class="sdt_menu">
<li>
<li>

Revision as of 01:02, 26 September 2012