:::: MENU ::::

Simple image mouseover through jQuery

Mouseover is common behavior for the images, required in any website across the pages. So it’s a good idea to keep this functionality in common script file. Simple jQuery code can make the life easier, just follow the below steps:

Step1: Add the jquery library, if not added or can be used google CDN hosted:

Step2: Add the below code within the script tag

Step3: Add the css class ‘rollover’, in which image you want mouseover

Step4: Add the images ‘normal’ & ‘mouseover’ in same location, ending with ‘imagename_off.gif’ & ‘imagename_on.gif’.

So, what do you think ?