6
Reply

Which command will give a version of jQuery?

    alert( ' jQuery version is: ' + $().jquery);

    alert( 'Your are jQuery version is: ' + $.fn.jquery ); alert( 'Your are jQuery version is: ' + jQuery.fn.jquery) alert( 'Your are jQuery version is: ' + $().jquery) alert( 'Your are jQuery version is: ' + $()['jquery']) alert( 'Your are jQuery version is: ' + $()['jquery']) /*this will give result in Developers Console*/ console.log($());

    You can use this command: if (typeof jQuery != 'undefined') { // jQuery is loaded => print the versionalert(jQuery.fn.jquery); }It would check for jQuery, if defined, then it would alert the version. From: http://stackoverflow.com/questions/6973941/how-to-check-what-version-of-jquery-is-loaded

    You can use this command: if (typeof jQuery != 'undefined') { // jQuery is loaded => print the versionalert(jQuery.fn.jquery); }It would check for jQuery, if defined, then it would alert the version. From: http://stackoverflow.com/questions/6973941/how-to-check-what-version-of-jquery-is-loaded

    $.fn.jquery returns JQuery version

    The command $.ui.version returns jQuery UI version.