Difference between revisions of "Team:CPU CHINA/Team"

Line 199: Line 199:
  
 
<div id="photo1" style="position:relative;top:150px;margin-left:5%;background:url(https://static.igem.org/mediawiki/2018/6/62/T--CPU_CHINA--team-DSC00344.png);background-repeat:no-repeat;background-size:cover;">
 
<div id="photo1" style="position:relative;top:150px;margin-left:5%;background:url(https://static.igem.org/mediawiki/2018/6/62/T--CPU_CHINA--team-DSC00344.png);background-repeat:no-repeat;background-size:cover;">
 +
 +
<div class="myButton" style="background-color:yellow;position:relative;top:200px;left:200px;width:5%;height:100px;">
 +
  <button id="1" type="button" class="myButton" onmouseover="showText(this.id)" onmouseout="hideText(this.id)" onclick="window.location.href=('')"></button>
 +
  <div id="Txt1" class="Txt">Hello, my name is Yiyang Zhu.
 +
  </div>
 +
</div>
 +
 
</body>
 
</body>
  
 
<script type="text/javascript">
 
<script type="text/javascript">
 +
/**********************************悬浮照片*************************************/
 +
function showText(id){
 +
$("#Txt").css("height","50px");
 +
$("#Txt").css("border","1px solid black");
 +
$("#Txt"+id).show();
 +
}
 +
function hideText(id){
 +
$("#Txt"+id).hide();
 +
        $("#Txt").css("height","");
 +
$("#Txt").css("border","1px solid black");
 +
}
 +
 +
 
$(document).ready(function(){
 
$(document).ready(function(){
 
     setVideo();
 
     setVideo();
Line 229: Line 249:
 
   
 
   
 
   parent.appendChild(child);
 
   parent.appendChild(child);
 +
}
 +
 +
/****************************填充照片上的按钮********************************/
 +
function setButton(){
 +
  var parent=document.getElementById("mw-content-text");
 +
  var child1=document.getElementById("1");
 +
  /*var child2=document.getElementById("2");
 +
  var child3=document.getElementById("3");
 +
  var child4=document.getElementById("4");
 +
  var child5=document.getElementById("5");
 +
  var child6=document.getElementById("6");
 +
  var child7=document.getElementById("7");
 +
  var child8=document.getElementById("8");
 +
  var child9=document.getElementById("9");
 +
  var child10=document.getElementById("10");
 +
  var child11=document.getElementById("11");
 +
  var child12=document.getElementById("12");*/
 +
 +
  parent.appendChild(child1);
 
}
 
}
 
</script>
 
</script>
 
</html>
 
</html>

Revision as of 09:03, 24 August 2018

Hello, my name is Yiyang Zhu.