]."/> ].">
Home >Web Front-end >JS Tutorial >What does # mean in jQuery
jQuery中# is a form of jquery selector, matching the object with id in any html, [$("#idvalue")] selects the html document in this code, that is, [
].
The operating environment of this tutorial: Windows 7 system, Dell G3 computer, jquery version 3.2.1.
# is a form of jquery selector that matches any id object in HTML.
$("#idvalue")
: This code selects the html document, that is, <any id="idvalue"></any>
;
jQuery element selector and attribute selector allow you to select HTML elements by tag name, attribute name or content. Selectors allow you to operate on groups of HTML elements or on individual elements.
JQuery is another excellent Javascript library after prototype. It is a lightweight js library that is compatible with CSS3 and various browsers (IE 6.0, FF 1.5, Safari 2.0, Opera 9.0). jQuery2.0 and subsequent versions will no longer support IE6/7/8 browsers .
jQuery enables users to more easily process HTML (an application under Standard Universal Markup Language), events, implement animation effects, and easily provide AJAX interaction for websites.
Another big advantage of jQuery is that its documentation is very complete and its various applications are explained in detail. There are also many mature plug-ins to choose from. jQuery can keep the code and HTML content of the user's HTML page separated. In other words, there is no need to insert a bunch of js in the HTML to call the command. You only need to define the id.
Related free learning recommendations: javascript (video)
The above is the detailed content of What does # mean in jQuery. For more information, please follow other related articles on the PHP Chinese website!