--------------------------------------------------------------------------------------------
【PHP】
--------------------------------------------------------------------------------------------
http://www.w3school.com.cn/jquery/jquery_ref_events.asp
性别默认选择第一个:
<script>
function add(){
$('input[ name=sex ]').get(0).checked=ture;
}
</script>
<strong>
============================================================================================================================
<!DOCTYPE html> 2 <html> 3 <body> 4 5 <h1>我的第一段 JavaScript</h1> 6 7 <p id="demo"> 8 JavaScript 能改变 HTML 元素的内容。 9 </p> 10 11 <script> 12 function myFunction() 13 { 14 x=document.getElementById("demo"); // 找到元素 15 x.innerHTML="Hello JavaScript!"; // 改变内容 16 17 } 18 </script> 19 20 <button type="button" onclick="myFunction()">点击这里</button> 21 22 </body> 23 </html>
=============================================================================================================================
001 ---------------------------------------------------------------------------->
002 ---------------------------------------------------------------------------->
003 ---------------------------------------------------------------------------->
004 ---------------------------------------------------------------------------->
005 ---------------------------------------------------------------------------->
006 ---------------------------------------------------------------------------->
007 ---------------------------------------------------------------------------->
008 ---------------------------------------------------------------------------->
009 ---------------------------------------------------------------------------->
010 ---------------------------------------------------------------------------->
011 ---------------------------------------------------------------------------->
012 ---------------------------------------------------------------------------->
013 ---------------------------------------------------------------------------->
014 ---------------------------------------------------------------------------->
015 ---------------------------------------------------------------------------->
016 ---------------------------------------------------------------------------->
017 ---------------------------------------------------------------------------->
018 ---------------------------------------------------------------------------->
019 ---------------------------------------------------------------------------->
000 ---------------------------------------------------------------------------->
000 ---------------------------------------------------------------------------->
000 ---------------------------------------------------------------------------->
000 ---------------------------------------------------------------------------->