Concepts of "$ function" in jQuery

Explain the concepts of "$ function" in jQuery with an example.

- The syntax of this function is tailor made and used for selecting the HTML elements and perform some actions on the elements.

Syntax:
$(selector).action()

- The $ sign is used to define/access jQuery.

- The (selector) is used to query or find the HTML elements.

- The action() is performed on the elements.

- There are a lot of anonymous functions in jquery.

Example:
$(document).ready(function() {});
$("a").click(function() {});
$.ajax(
{
   url: "someurl.php",
   success: function() {}
});
Why is jQuery better than javascript?
Why is jQuery better than javascript? - jQuery is great library for developing ajax based application..........
Explain how jQuery Works
Explain how jQuery Works
When can you use jQuery?
When can you use jQuery? - JQuery can be used to apply CSS, call functions on events.........
Post your comment