将页面部分jS代码转为JQuary代码

This commit is contained in:
sw 2014-06-20 11:16:08 +08:00
parent d0c9390e91
commit d2376eb0b1
2 changed files with 4 additions and 5 deletions

View File

@ -25,7 +25,6 @@
function show() function show()
{ {
$("#what_is_project_div").slideToggle(); $("#what_is_project_div").slideToggle();
} }
</script> </script>
</div> </div>

View File

@ -1,10 +1,10 @@
<script type="text/javascript"> <script type="text/javascript">
function switchTab(ProTag) { function switchTab(ProTag) {
var display_index = 3 - ProTag; var display_index = 3 - ProTag;
document.getElementById("tab" + ProTag).className = "selected"; $("#tab" + ProTag).attr("class","selected");
document.getElementById("tab" + display_index).className = ""; $("#tab" + display_index).attr("class","");
document.getElementById("content" + ProTag).style.display = ""; $("#content" + ProTag).show();
document.getElementById("content" + display_index).style.display = "none"; $("#content" + display_index).hide();
} }
</script> </script>