微信公众号搜"智元新知"关注
微信扫一扫可直接关注哦!

Image Hover prefixsuffixsrcbtnOnlyfadefadeSpeed

程序名称:Image Hover prefixsuffixsrcbtnOnlyfadefadeSpeed

授权协议: 未知

操作系统: 未知

开发语言:

Image Hover prefixsuffixsrcbtnOnlyfadefadeSpeed 介绍

Overview

ImgHover is a simple way to use hovering image on your site.

You can use fade effect to switch hovering images as well.

Usage

If you want to provide hovering behavIoUr to all the images, you can write
simply like below;

`$(document).ready(function(){
$(‘img’).imghover();
});

`

When mouse-over this image, file “/your/path/original_o.gif” shows on the
element.

Bulk Setting

You can call this method on the elements other than images as well.

$(document).ready(function(){ $('div.image-container').imghover(); });

In this case, ImgHover provides the function to the images under ‘image-
container’ element.

Options

prefix

Create hovered image by original image name and prefix.

`$(‘img’).imghover({prefix: ‘hover/’});

`

In this case, “/your/path/hover/image1.gif” will be provided as hovered image.

Default value is null.

suffix

Create hovered image by original image name and suffix.

`$(‘img’).imghover({suffix: ‘-hovered’});

`

In this case, “/your/path/image1-hovered.gif” will be provided as hovered
image.

Default value is ‘o’. # for my colleagues ;-p

src

Specify hovered image.

Defautl value is null.

btnOnly

When ImgHover was called to container element(s), the function find only or
with anchor link. This option is useful to avoid empty gif, site logo and so
on.

Default value is true.

fade

You can use fade effect to switch images.

Default value is false.

fadeSpeed

The speed of fade effect.

Default value is 500.

Easy way to use

This plugin is very handy when you use this with
jGlycy.

Image Hover prefixsuffixsrcbtnOnlyfadefadeSpeed 官网

http://plugins.jquery.com/project/imghover

版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 [email protected] 举报,一经查实,本站将立刻删除。

相关推荐