jQuery imgDesc DescriptionRequirementsFeaturesUsage 介绍
Description
This plugin is written with the develpment of PageTalks, accidently. As
PageTalks is based on jQuery Libary, jQuery code is required.
Requirements
- jQuery Libary, just downlaod fromjQuery Offical Site
- imgDesc script file(oops……)
- a little kNowledge on xhtml and js
Features
This plugin will automatically take title attribute in IMG tag as the
description of the image. If IMG is not wrapped by a Anchor tag, the plugin
will wrap it with one. This plugin currently support two parameters, all of
which are optional.
- autohide if the plugin should automatically hide the description and show it when mouSEOver. Default “yes”
- text Customize the value of description. Default value is the title attribut of IMG tag
Usage
Load jQuery Libary
You can directly add the following code in <head> tag:<script type="text/javascript" src="jquery..js"></script>
Load imgDesc Plugin
<script type="text/javascript" src="jquery.imgdesc.js"></script>
Assing the target object
follow the jQuery code style:$("img").imgDesc();You can, of course , apply some change, customizing the way it show up and the value of description:$("img").imgDesc({autohide: "yes", text : "This is a sample text!"});
jQuery imgDesc DescriptionRequirementsFeaturesUsage 官网
http://plugins.jquery.com/project/imgDesc
版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 [email protected] 举报,一经查实,本站将立刻删除。