Template:Kyoto/js
From 2012.igem.org
(Difference between revisions)
(32 intermediate revisions not shown) | |||
Line 3: | Line 3: | ||
<script type="text/javascript"> | <script type="text/javascript"> | ||
function showTab(tabname) { | function showTab(tabname) { | ||
- | var children = | + | var $children = $("#kyoto-tab-contents").children("div"); |
- | + | $children.css("display","none"); | |
- | + | ||
- | + | ||
- | + | ||
- | + | ||
document.getElementById(tabname).style.display = "block"; | document.getElementById(tabname).style.display = "block"; | ||
} | } | ||
- | function changeTab( | + | |
- | var tabs = $("#kyoto-tabs").children("li"); | + | function changeTab(tab) { |
- | + | var $tabs = $("#kyoto-tabs").children("li"); | |
- | + | $tabs.css("border-bottom","1px solid #c8c2b6"); | |
+ | tab.css("border-bottom","none"); | ||
} | } | ||
$(function() { | $(function() { | ||
- | + | setScroll($("#kyoto-menu")); | |
- | + | setScroll($(".kyoto-post-it")); | |
- | $("#kyoto-tabs").children("li").click(function() { | + | setScroll($("#goldenpost")); |
- | + | $("#kyoto-tabs").children("li").click(function() { changeTab($(this)); }); | |
- | + | ||
}); | }); | ||
</script> | </script> | ||
</html> | </html> |
Latest revision as of 01:17, 27 October 2012