0% found this document useful (0 votes)
2 views

Imp JQuery

The document contains a series of questions and answers related to jQuery functionality. It covers topics such as element selection, hiding and showing elements, event handling, and manipulating CSS classes and text. Each question is followed by a corresponding answer that highlights key jQuery methods and their uses.
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
2 views

Imp JQuery

The document contains a series of questions and answers related to jQuery functionality. It covers topics such as element selection, hiding and showing elements, event handling, and manipulating CSS classes and text. Each question is followed by a corresponding answer that highlights key jQuery methods and their uses.
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 1

What does the $ symbol represent in jQuery?

Answer: b) A function

2. How do you select an element with the ID "myElement" in jQuery?

Answer: a) $("#myElement")

3. Which jQuery method is used to hide an HTML element?

Answer: b) .hide()

4. What does the .click() method do in jQuery?

Answer: c) Registers a function to be executed when an element is clicked

5. How do you add a CSS class to an element with jQuery?

Answer: a) $(".element").addClass("newClass")

6. Which jQuery function allows you to execute code when the document is
fully loaded?

Answer: b) .ready()

7. Which of the following methods in jQuery is used to make an HTML


element visible after it was hidden?

Answer: a) .show()

8. How can you change the text of an HTML element using jQuery?

Answer: b) $("#element").text("New Text")

9. Which jQuery method is used to get or set the value of an input field?

Answer: c) .val()

10. How can you append a new element to the end of an existing element using
jQuery?

Answer: a) $("#element").append("<div>New Element</div>")

You might also like