PIXNET Logo登入

拉不拉多的夢幻世界

跳到主文

程式設計 Perl Python Linux小技巧 Shell Script 水族 孔雀魚 水草

部落格全站分類:數位生活

  • 相簿
  • 部落格
  • 留言
  • 名片
  • 7月 20 週二 201014:04
  • JQuery JSON 簡例

記錄一下 用法
很基本的JSON 用法 :重點在於Server 丟給 Client的資料格式 
與Client 如何取出值
XXX.htm
(繼續閱讀...)
文章標籤

yuanann 發表在 痞客邦 留言(0) 人氣(3,277)

  • 個人分類:JQuery
▲top
  • 7月 02 週五 201015:01
  • JQuery 控制text (Disabled)

記錄一下用法
用法的關鍵就是 attr 和 disabled 而以 ^^
 
<html>
<head>
 <title>JQuery control the text button </title>
 <script src="jquery.js" type="text/javascript"></script>
(繼續閱讀...)
文章標籤

yuanann 發表在 痞客邦 留言(0) 人氣(2,702)

  • 個人分類:JQuery
▲top
  • 3月 04 週四 201011:03
  • JQuery-檢查元素是否存在

以下代碼是利用jquery 來檢查某一元素是否存在 記錄一下 ^^
 
<html>
<head>
 <script src="jquery.js" type="text/javascript"></script>
 
 <script>
 $(document).ready(function(){
 
  
  if ($("#div_id").length)  ////if ($("#div_id")) 也可以
  {
   alert("do something");
  }
 
 });
 
 </script>
</head>
 
<body>
<div id="div_id"></divs>
(繼續閱讀...)
文章標籤

yuanann 發表在 痞客邦 留言(0) 人氣(1,585)

  • 個人分類:JQuery
▲top
  • 12月 25 週五 200917:04
  • JQuery-sample- this 用法

學習記錄
使用this 對元素進行處理動作
 
<html>
<head>
<title>Jquery-Sample-this </title>
<script type="text/javascript" src="./jquery.js"></script>
<script type="text/javascript">
function click()
{
    $('#div_picture').show();
}
function move()
{
    $('#div_picture').hide();
}
$(document).ready(function() {
    
    $('#div_picture').hide();
    
    $('.picture').click(function () {   
    url_id = $(this).attr("id");
    pictre_url = $(this).attr('value');
    $('#picture_id').attr('src', pictre_url)
    
    $(this).bind('click',click);
    $(this).bind('mouseout',move);
    });   
   
});
</script>
</head>
<body align="left">
<div id="show_picture_0" value="http://sstatic.net/so/img/logo.png" > show picture </div>
<div id="show_picture_1" value="http://imageshack.us/images/greylogo.png" > abcd </div>
<div id="div_picture" ><img id="picture_id" src=""></div  >
</body>
</html>
(繼續閱讀...)
文章標籤

yuanann 發表在 痞客邦 留言(0) 人氣(1,785)

  • 個人分類:JQuery
▲top
  • 12月 04 週五 200917:51
  • JQuery-偵測browser 種類

目前支援 safari, opera, msie, mozilla  應該夠用了  ^^
範例如下
<HTML>
 <HEAD>
 <script src="jquery.js"> </script>
  <TITLE> rolling image </TITLE>
 </HEAD>
 <BODY>
<div onclick="check_browser()" >Check Browser</div>
<script>
    function check_browser()
    {
        //support : safari, opera, msie, mozilla
        if($.browser.msie){
            alert("IE");
            return IE ;
        }
        
        if($.browser.mozilla){
            alert("mozilla");
            return mozilla ;
        }
    }
</script>
 </BODY>
</HTML>
(繼續閱讀...)
文章標籤

yuanann 發表在 痞客邦 留言(0) 人氣(655)

  • 個人分類:JQuery
▲top
  • 12月 04 週五 200917:17
  • JQuery-css用法

css 是用來設定樣式的
在JQuery 中 用法如下
 
<div id="abc" color="blue">div test</div>
(繼續閱讀...)
文章標籤

yuanann 發表在 痞客邦 留言(0) 人氣(2,392)

  • 個人分類:JQuery
▲top
1

BloggerAds

誰來我家

參觀人氣

  • 本日人氣:
  • 累積人氣:

近期文章

  • 最近在執行的計劃
  • 防火牆設定
  • 好久沒更新
  • 在Mac OS 儲存目前畫面
  • 程式碼管理工具
  • mac 好用工具
  • 好用服務
  • 好久沒更新了!!
  • JQuery JSON 簡例
  • JQuery 控制text (Disabled)

文章分類

  • mac tool (2)
  • JQuery (6)
  • PHP (6)
  • Python (15)
  • Shell Script (10)
  • 資安文章 (9)
  • Perl (29)
  • 電腦軟體(Linux) (20)
  • 電腦軟體(Win) (2)
  • 水族相關 (4)
  • 心情留言 (3)
  • Linux (26)
  • 未分類文章 (1)

公益廣告

推推王