JQUERY

<html>
<head>
<script type="text/javascript" src="jquery.js"></script>
</head>
<body>
	<ul>
    <li>list item 1</li>
    <li>list item 2</li>
    <li>list item 3</li>
    <li>list item 4</li>
    <li>list item 5</li>
</ul>
<table>
  <tr style="display:none"><td>Value 1</td></tr>
  <tr><td>Value 2</td></tr>
</table>
<a>click</a>
</body>

<script  type="text/javascript">
$(document).ready(function(){
$("li").click(function(){
$(this).hide();
});

$("a").click(function(){
//$("li:first").html("123");
//$("tr:visible").html("ha");
$("li:hidden").show();
})
});
</script>
</html>

  ====

<html>
<head>
<meta http-equiv="content-type" content="text/html;charset=utf-8">    
<script type="text/javascript" src="jquery.js"></script>
</head>
<body>
        <div id="div1">1
        </div>
        <div id="div2">2</div>  
        <div id="div3">3</div>


<a>dianji</a>
</body>
<script type="text/javascript">
$(document).ready(function(){
$("a").click(function(){
$("div:first").html("wo");
})

});
</script>
</html> 

  

http://www.cnblogs.com/happyhippy/archive/2008/11/14/1333922.html

 

http://www.cnblogs.com/zhangziqiu/archive/2009/05/05/jQuery-Learn-4.html

 

<html>
<head>
<script type="text/javascript" src="jquery.js"></script>
<title>this is a title</title>
</head>
<body>
<p id = '12'>
this is the first~
</p>
<p id='23' class='331'>
this is the second~
</p>
<a class="i">iiu </a>

</body>
<script type="text/javascript">
/*$("#12").append("<p>hello</p>");
$(".331").html("331class");*/
$("p,a").append("shabi");
//$("*").append("*");
//$("body p");
</script>
</html>

posted @ 2014-10-15 17:59  啊阿强  阅读(210)  评论(0编辑  收藏  举报