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

jQuery EasyUI ProgressBar進(jìn)度條組件

 更新時(shí)間:2017年02月28日 17:18:52   作者:hai_cheng001  
這篇文章主要為大家詳細(xì)介紹了jQuery EasyUI ProgressBar進(jìn)度條組件的相關(guān)資料,具有一定的參考價(jià)值,感興趣的小伙伴們可以參考一下

ProgressBar(進(jìn)度條)組件,這個(gè)還是挺好玩的,我們?cè)谧约鹤鳇c(diǎn)什么的時(shí)候經(jīng)常能用到,比如上傳下載文件、導(dǎo)入導(dǎo)出文檔啊、載入網(wǎng)頁(yè)等等。

應(yīng)用場(chǎng)景很多,使用起來(lái)還很簡(jiǎn)單。

示例:

<!DOCTYPE html> 
<html> 
<head> 
<title>jQuery Easy UI</title> 
<meta charset="UTF-8" /> 
<script type="text/javascript" src="easyui/jquery.min.js"></script> 
<script type="text/javascript" src="easyui/jquery.easyui.min.js"></script> 
<script type="text/javascript" src="easyui/locale/easyui-lang-zh_CN.js" ></script> 
<link rel="stylesheet" type="text/css" href="easyui/themes/bootstrap/easyui.css" rel="external nofollow" /> 
<link rel="stylesheet" type="text/css" href="easyui/themes/icon.css" rel="external nofollow" /> 
<script> 
  $(function () { 
  //$.fn.progressbar.defaults.value = 30; 
   
  //想要修改進(jìn)度條的顏色去css文件中去修改 
  $('#box').progressbar({ 
    width : 200,    //設(shè)置進(jìn)度條寬度 默認(rèn)400 
    height : 15,    //設(shè)置進(jìn)度條高度 默認(rèn)22 
    value : 0,     //設(shè)置進(jìn)度條值 默認(rèn)0 
    text : '{value}%', //設(shè)置進(jìn)度條百分比模板 默認(rèn) {value}% 
     
    //在value改變的時(shí)候觸發(fā) 
    onChange : function (newValue, oldValue) { 
      console.log('新:' + newValue + ',舊:' + oldValue); 
    }, 
  }); 
  /* 
  setTimeout(function () { 
    $('#box').progressbar('setValue', 70); 
  }, 1000); 
   
  */ 
  setInterval(function () { 
    //getValue setValue 分別是返回當(dāng)前進(jìn)度值 和 設(shè)置一個(gè)進(jìn)度值 
    $('#box').progressbar('setValue', $('#box').progressbar('getValue') + 5); 
  }, 1000); 
  console.log($('#box').progressbar('options')); 
  //$('#box').progressbar('resize', 80); 沒(méi)啥大用 
}); 
</script> 
</head> 
<body style="margin:100px;"> 
  <!-- 
  <div class="easyui-progressbar" data-options="value:60" style="width:400px"></div> 
  --> 
  <div id="box" ></div> 
</body> 
</html> 

執(zhí)行效果:


點(diǎn)擊下載源代碼:jQuery ProgressBar進(jìn)度條組件

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

相關(guān)文章

最新評(píng)論