zoukankan      html  css  js  c++  java
  • 界面数据发生变化时候刷新

    $('ul').listview('refresh');

    $("select#foo").selectmenu("refresh");

    $("select[name='projectTime']").selectmenu("disable"); //设置不可用
    $("select[name='otherTime']").selectmenu("enable");//取消不可用

    $("input[type='checkbox']").attr("checked",true).checkboxradio("refresh");

    $("input[type='radio']").attr("checked",true).checkboxradio("refresh");

    1.Textarea fields

    1
    2
    $('body').prepend('<textarea id="myTextArea"></textarea>');
    $('#myTextArea').textinput();

    2.Text input fields

    1
    2
    $('body').prepend('<input type="text" id="myTextField" />');
    $('#myTextField').textinput();

    3.Buttons

    1
    2
    $('body').append('<a href="" data-theme="e" id="myNewButton">testing</a>');
    $('#myNewButton').button();

    4.Combobox or select dropdowns

    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    <label for="sCountry">Country:</label>
    <select name="sCountry"id="sCountry">
    <option value="">Where You Live:</option>
    <option value="ad">Andorra</option>
    <option value="ae">United Arab Emirates</option>
    </select>
     
    var myselect = $("#sCountry");
    myselect[0].selectedIndex = 3;
    myselect.selectmenu('refresh');

    5.Listviews

    1
    2
    3
    4
    5
    6
    7
    <ul id="myList"data-role="listview"data-inset="true">
    <li>Acura</li>
    <li>Audi</li>
    <li>BMW</li>
    </ul>
     
    $('#mylist').listview('refresh');

    6.Slider control

    1
    2
    3
    4
    5
    6
    <div data-role="fieldcontain">
    <label for="slider-2">Input slider:</label>
    <input type="range"id="slider-2"value="25"min="0"max="100"/>
    </div>
     
    $('#slider-2').val(80).slider('refresh');

    7.Toggle switch

    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    <div data-role="fieldcontain">
    <label for="toggle">Flipswitch:</label>
    <select name="toggle"id="toggle"data-role="slider">
    <option value="off">Off</option>
    <option value="on">On</option>
    </select>
    </div>
     
    var myswitch = $("#toggle");
    myswitch[0].selectedIndex = 1;
    myswitch .slider("refresh");

    8.Radio buttons

    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    <div data-role="fieldcontain">
        <fieldset data-role="controlgroup"data-type="horizontal">
          <legend>Layout view:</legend>
              <input type="radio"name="radio-view"value="list"/>
              <labelfor="radio-view-a">List</label>
              <input type="radio"name="radio-view"value="grid"/>
              <labelfor="radio-view-b">Grid</label>
              <input type="radio"name="radio-view"value="gallery"/>
              <labelfor="radio-view-c">Gallery</label>
        </fieldset>
    </div>
     
    $("input[value=grid]").attr('checked',true).checkboxradio('refresh');

    9.Checkboxes

    1
    2
    3
    4
    5
    6
    7
    8
    9
    <div data-role="fieldcontain">
    <fieldset data-role="controlgroup">
    <legend>Agree to the terms:</legend>
    <input type="checkbox"name="checkbox-1"id="checkbox-1"class="custom"/>
    <label for="checkbox-1">I agree</label>
    </fieldset>
    </div>
     
    $('#checkbox-1').attr('checked',true).checkboxradio('refresh');
  • 相关阅读:
    oracle 静默安装
    浅析hybrid模式下地支付宝钱包和微信
    LeetCode96_Unique Binary Search Trees(求1到n这些节点能够组成多少种不同的二叉查找树) Java题解
    hdu 5411 CRB and Puzzle 矩阵高速幂
    Hadoop作业性能指标及參数调优实例 (三)Hadoop作业性能參数调优方法
    实现Android4.4系统设置分页滑动浏览功能
    oracle 数据库中数据导出到excel
    Nginx配置upstream实现负载均衡
    公司须要内部的地图服务,准备自己去开发可是成本太高,如今有没有专门为企业提供GIS地图开发的产品呀?大概价格多少?
    图片在内存中的占用的空间大小
  • 原文地址:https://www.cnblogs.com/yabbi/p/4120000.html
Copyright © 2011-2022 走看看