jQuery Loader – On-Demand, Lazy Load
Download
Demo
Loader is a jQuery plugin for dynamic loading of JavaScript’s, CSS’s and images. The current version is compatible with any modern browser, and some less so (IE6). Is in release candidate 1. Testing, use and comment!
$.Loader( url )
url – A string or array containing the URL to which the request is sent.
$.Loader( url, options )
url – A string or array containing the URL to which the request is sent.
options – A object with all options
$.Loader( url, success(element, selectors) )
url – A string or array containing the URL to which the request is sent.
success – A function to execute on url is loaded.
$.Loader( url, success(element, selectors), options )
url – A string or array containing the URL to which the request is sent.
success – A function to execute on url is loaded.
options – A object with all options.
$.Loader( options )
options – A object with all options and url.
* If not url: The options will be defined as default options.
$.Loader( options, success(element, selectors) )
options – A object with all options and url.
success – A function to execute when all url’s are loaded.
options:
url (String, Array or Object):
debug (boolean):
Default: false
Show load status in console.
base (object):
Default: {js:”,css:”,img:”}
* js: path base to javascripts
* css: path base to css’s
* img: path base to images
cache (boolean):
Default: true
async (only js) (boolean):
Default: false
global (only js) (boolean):
Default: true
complete (only js) (function):
Default: null
ifModified (only js) (boolean):
Default: false
scriptCharset (only js) (string):
Default: null
timeOut (only js) (integer):
Default: 60000