欧美bbbwbbbw肥妇,免费乱码人妻系列日韩,一级黄片

jQuery過濾選擇器經(jīng)典應(yīng)用

 更新時(shí)間:2016年08月18日 10:24:12   作者:chen12370  
這篇文章主要為大家詳細(xì)介紹了jQuery過濾選擇器經(jīng)典應(yīng)用,具有一定的實(shí)用性,感興趣的小伙伴們可以參考一下

本文實(shí)例為大家分享了經(jīng)典的jQuery過濾選擇器應(yīng)用,供大家參考,具體內(nèi)容如下

<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <title>過濾選擇器</title>
  <style type="text/css">
    #txt_show {display:none; color:#00C;}
    #txt_hide {display:block; color:#F30;}
  </style>
 
  <script src="js/jquery-1.8.3.js"></script>
  <script language="JavaScript">
    $(document).ready(function () {
      $("[name=show]").click(function () {
        $("p:hidden").show();
      }) ;
      $("[name=hide]").click(function () {
        $("p:visible").hide() ;
      });
    });
 
  </script>
 
</head>
<body>
<p id="txt_hide">點(diǎn)擊按鈕,我會被隱藏哦~</p>
<p id="txt_show">隱藏的我,被顯示了,嘿嘿^^</p>
<input name="show" type="button" value="點(diǎn)擊顯示文字" />
<input name="hide" type="button" value="點(diǎn)擊隱藏文字" />
 
</body>
</html>

以上就是本文的全部內(nèi)容,希望對大家的學(xué)習(xí)有所幫助,也希望大家多多支持腳本之家。

相關(guān)文章

最新評論