PHP Classes

File: public/js/ajax-loading.js

Recommend this page to a friend!
  Classes of saber tabatabaee   Laravel PHP Task Manager   public/js/ajax-loading.js   Download  
File: public/js/ajax-loading.js
Role: Auxiliary data
Content type: text/plain
Description: Auxiliary data
Class: Laravel PHP Task Manager
Application to manage project tasks
Author: By
Last change:
Date: 3 years ago
Size: 1,006 bytes
 

Contents

Class file image Download
$(document).ready(function() { var AjaxLoadingBar = { init: function () { this.bindUI(); }, bindUI: function () { var that = this; $.ajaxSetup({ beforeSend: function() { $(".overlay").fadeIn('slow'); $(".spinner").show(); // if ($("#loadingbar").length === 0) { // $("body").append("<div id='loadingbar'></div>") // $("#loadingbar").addClass("waiting").append($("<dt/><dd/>")); // $("#loadingbar").width((50 + Math.random() * 30) + "%"); // } }, complete : function() { setTimeout(function() { $(".overlay").fadeOut('slow'); $(".spinner").hide(); }, 500); // $("#loadingbar").width("101%").delay(200).fadeOut(400, function() { // $(this).remove(); // }); } }); } }; AjaxLoadingBar.init(); });