in JQuery by
Q:
How to add and remove CSS classes to an element using jQuery?

1 Answer

0 votes
by
You can use the addClass() and removeClass() methods to do the same.

$("h1").addClass("myclass");

$("h1").removeClass("myclass");

Question: Can you write a jQuery code to select all links inside the paragraph?

Answer:

$('a:visible').css('text-transform', 'uppercase');

Related questions

0 votes
asked Nov 19, 2020 in JQuery by rajeshsharma
+1 vote
asked Jul 7, 2021 in CSS by rajeshsharma
...