开发者

jQuery: change icon to greyscale

开发者 https://www.devze.com 2022-12-13 12:41 出处:网络
I made a button widget in jQuery which displays an icon. Now when I set the button do disabled, I\'d like to have it greyed-开发者_开发问答out.

I made a button widget in jQuery which displays an icon.

Now when I set the button do disabled, I'd like to have it greyed-开发者_开发问答out.

Is there a jQuery function to do this?

Thanks


If you don't want to create another version of the image then you can try using CSS to reduce the opacity of the button so it appears faded, or overlay a semi-transparent grey DIV to give a greyed-out effect.


http://www.alistapart.com/articles/sprites2/

Sprites are your answer.

0

精彩评论

暂无评论...
验证码 换一张
取 消