Examples
1- $('#tagid') selects the unique element with id="tagid"
2- $('p#tagid') selects a single paragraph with an ID of tagid
2- $('p#tagid') selects a single paragraph with an ID of tagid
2nd one is showing how the unique element
will be selected in case if more than one element
has been assigned the same ID, queries that use that ID will only select the first matched element in the DOM.
No comments:
Post a Comment