martinbshp martinbshp - 1 year ago 76
jQuery Question

How do I add aditional class on hover in jQuery

I have several circles with a css class of rating-circle and I want to add an additional class. Here is the code I'm using.

$(function () {

//change class on hover

$('.rating-circle').hover( function() {

What did I miss?
Thank you.

Answer Source

you forgot the dot


Small advice: Use some developer tool when you are working in frontEnd, and those minor mistakes are really easy to fix :)

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download