English | 简体中文 | 繁體中文 | Русский язык | Français | Español | Português | Deutsch | 日本語 | 한국어 | Italiano | بالعربية
jQuery is a fast, lightweight, and feature-rich JavaScript library based on the principle of 'less code, more work'.
jQuery simplifies the traversal of HTML documents, event handling, animations, and AJAX interactions, thus enabling rapid web development.
The purpose of jQuery is to make it easier to use JavaScript on websites.
This tutorial will help you learn the latest jQuery basics from basic to advanced topics.
Each chapter of this tutorial includes many exercise examples, which you can try and test in our online editor to expand your learning scope. The purpose of these examples is to help you better understand the usage of jQuery.
$("document").ready(function(){ $("p").click(function(){ $(this).hide(); }); });Test and see‹/›
If you are not familiar with jQuery, you may wonder what makes jQuery so special.
jQuery simplifies many complex aspects of JavaScript, such as AJAX calls and DOM manipulation.
The jQuery library includes the following features:
HTML / DOM manipulation
CSS manipulation
Event handling
Effects and animations
AJAX support
Utilities (Utilities)
Plugins (Plugins)
Cross-browser support
Information:In JavaScript, you usually need to write several lines of code to select and manipulate elements in an HTML document, but with jQuery's powerful selector mechanism, you can traverse the DOM tree and select elements in a simple and effective way to perform any operation.
You can do more with jQuery:
jQuery can easily select elements
jQuery can easily change the style (CSS) and position of elements
jQuery can easily manipulate DOM elements and their properties
jQuery can easily create effects such as showing or hiding elements, sliding transitions, etc.
jQuery can easily create complex CSS animations with less code
jQuery can easily traverse the entire DOM tree to find any element
jQuery can easily perform multiple operations on elements with just one line of code
jQuery can easily get or set the size of HTML elements
The list does not end here, you can do many other interesting things with jQuery.
In the following chapters, you will learn about all of this in detail.
Before you start learning jQuery, you should have the following basic knowledge:
If you are a beginner, start with the basics and gradually progress by learning a little bit every day.
We recommend that you read this tutorial in the order listed in the left menu.
The reference section will provide detailed information about jQuery selectors, effects, properties, events, etc.