add color to attribute using jquery 1

add color to attribute using jquery

$(this).css('color', 'red');

Here is what the above code is Doing:
1. We’re selecting the element with the id of “my-element”
2. We’re changing the background color to blue
3. We’re changing the font color to red

Now, let’s see how we can do the same thing with jQuery:

Similar Posts