JQuery syntax example $ (this). hide () demonstrates the jQueryhide () function to hide the current HTML element. $ (& Quot; # test & quot;). hide () demonstrates the jQueryhide () function to hide the elements of id & quot; test & quot. $ (& Quot; p & quot ;). hide () demonstrates the jQueryhide () function jQuery syntax instance $ (this ). hide () demonstrates the jQuery hide () function to hide the current HTML element. $ ("# Test"). hide () demonstrates the jQuery hide () function to hide the element id = "test. $ ("P"). hide () demonstrates the jQuery hide () function to hide all
Element. $ (". Test"). hide () demonstrates the jQuery hide () function to hide all the elements of class = "test. JQuery syntax is compiled for the selection of HTML elements. You can perform some operations on the elements. The basic syntax is: $ (selector ). the $ action () symbol defines the jQuery selector "Query" and "search" the action () of the HTML element jQuery to execute the operation example for the element $ (this ). hide ()-hide the current element $ ("p "). hide ()-hide all paragraphs $ ("p. test "). hide ()-hide all paragraphs of class = "test" $ ("# test "). hide ()-hide all element document readiness functions with id = "test". You may have noticed that all jQuery functions in our instance are in a document ready function: $ (document ). ready (function () {--- jQuery functions go here ----}); this prevents the document from running jQuery code before it is fully loaded (ready. If you run the function before the document is fully loaded, the operation may fail. The following two examples show how to hide a non-existent element to obtain the size of an incomplete loaded image.