bootstrap-實現loading效果


可以使用bootstrap的模態框(modal.js),使用它我們可以做出loading效果。

 html

<!-- loading -->
<div class="modal fade" id="loading" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" data-backdrop='static'>
  <div class="modal-dialog" role="document">
    <div class="modal-content">
      <div class="modal-header">
        <h4 class="modal-title" id="myModalLabel">提示</h4>
      </div>
      <div class="modal-body">
        請稍候。。。<span id="result"></span>
      </div>
    </div>
  </div>
</div>

 

 

 js

 

//顯示
$('#loading').modal('show');
//影藏
$('#loading').modal('hide');

 


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM