What is jQuery ?


jQuery is a JavaScript library. It gets a set of defined methods by encapsulating native JavaScript functions.

jQuery greatly simplifies JavaScript programming. Look at the example below

Suppose there are two elements in the page below

<input type="text" id="txt" />
<button type="button" onclick="get_text();">Go</button>
After clicking the Go button, the user input in the text box will pop up, which can be written using the original JavaScript code.

Alert(document.getElementById('txt').value);
With jQuery, you can simply write

Alert($('#txt').val());
You can see that we use document.getElementById to get the element with the specified id. With jQuery, we only need to use $('#') to do it all.

The main idea of ​​jQuery is to achieve more functionality with less code.

The jQuery library contains the following features:

HTML element selection

HTML element operation

CSS operation

HTML event function

JavaScript effects and animations

HTML DOM traversal and modification

AJAX

Tip : In addition to this, Jquery also offers a large number of plugins.

Learn the conditions of jQuery


HTML (including css, the basic knowledge of web pages)

JavaScript (even though jQuery is simpler than JavaScript, the various syntax of jQuery comes from JavaScript)

PHP (jQuery belongs to the front-end technology, and the backend is extremely complementary and echoes each other)

Is jQuery suitable for all browsers? The


jQuery community knows that JS has a lot of compatibility issues in different browsers. Currently jQuery is compatible with all major browsers, including Internet Explorer 6!    

Let's first look at a jQuery instance. 



Last Updated: 2018-11-24 14:47:29 By Akshay

SHARE THIS

share_facebook share_twitter share_google_plus

Please Comment Here :