ollicle.com: Biggerlink – jQuery plugin
ollicle.com: Biggerlink – jQuery plugin
Biggerlink – jQuery plugin Purpose Demo Updated for jQuery 1.3 How to use it Download Thanks Purpose A jQuery plugin to make it really easy to enable the specified element/s to behave as a proxy for their first contained link. Uses additional css classes to provide the means for the specified element to visually reflect focus and hover states of it's contained link/s. More to read in my blog post: Bigger link: easier clicking with jQuery Requires jQuery version 1.3+ Tested successfully in: Firefox 3.x IE 6,7,8 Safari 3,4 Opera 9 Simple demo With links to more demos. View the source for the CSS, HTML and JavaScript. Basic demonstration Updated for jQuery 1.3 With the release of jQuery 1.3 I have revisited this plugin to improve my understanding of the new event object and fixed some bugs and added some features while I was at it. If you are stuck with jQuery version 1.2 try jquery.biggerlink version 1. How to use it Here are some typical configurations. Defaults Normally this plugin will need very little configuration - although you do need to point it at the element/s on which you wish it to act. HTML of an element which contains a link whose behaviour you wish the element to inherit. In this case theelements.
Fusion
jQuery
JavaScript in the document headWith JavaScript pop-ups Using JavaScript to open the link in a new window is one likely scenario where you will to want to prevent the link’s default action. HTML as above. (Note the added title attributes will be applied to the
elements by the plugin).
Fusion
jQuery
JavaScript. Setting follow to false ensures the link will not be followed by the browser as it would by default; Thus not interferring with the action os JavaScript pop-ups applied to the same link.As of version 2 of biggerlink there is now a new default value for follow of 'auto'. In the code above where biggerlink is bound next after the pop-up event setting follow to false in unnecessary. If the click event before biggerlink returns false biggerlink will not cause the link to be followed. Any other events bound to the link will be triggered normally. Multiple links in each biggerlink container By default biggerlink will force all clicked links in the specified container to trigger the first (master) link instead. Although click events bound to other links will fire as well as any applied to the master link. This is typically useful when the multiple links point to the same href. This version of biggerlink introduces a new setting otherstriggermaster (for want of a shorter name!). By default it is set to true. Setting it to false allows links following the first in the assigned container to be independent. Clicking them will not trigger the click events on the master link. Directly hovering or focusing an 'other' link with otherstriggermaster set to false will add an additional class to the biggerlink container - bl-hover2 by default. HTML. Note each li contains two links:
Fusion
Where Ollie works in Adelaide Google search
jQuery
The write less, do more, JavaScript library Google search
Find out more about everything Google search
JavaScript.Using custom classes By default the plugin applies classes to the target elements: hoverclass - class added to the parent element when hovering over it with you cursor or focusing a link it contains. By default this class is hover. clickableclass - class added to each selected element which contains at least one link. By default this class is hot. Particularly useful if you wish to make the element appear 'clickable' when the link behaviours are assigned to it. Version 2 introduces a couple more biggerclass - class added to all the contained elements, unless otherstriggermaster is false, in which case it is only applied to the first (master). hoverclass2 - If otherstriggermaster is set to false this additional class is added to the containing element when links other than the first are moused over or focused. CSS applied with this class can override the styles applied by hoverclass to provide visual hints that the function or destination of this link differs from the first. HTML. Nothing new here:
Fusion
jQuery
JavaScript. If by chance these classes conflict with other classes in your document they may be customised:Things not likely to work as expected Nesting assigned biggerlink elements. Using biggerlink alongside events bound with an inline onclick attribute. Middle or right button mouse clicks on the biggerlink area. Known issues Does not work with jQuery live events Form elements contained by a biggerlink element can become unclickable Download version 2 Uncompressed and commented: jquery.biggerlink.js Minimised: jquery.biggerlink.min.js Thanks Plugin by Oliver Boermans. Made easy by jQuery. The first version of this code was the product of a few Friday afternoons. During this time my employer, Fusion, allows me and my fellow Fusionites to work on the internal projects that interest us most. I’m sharing biggerlink in the hope that it can be further polished by people smarter than me; And to, in a small way, give back to others who have contributed to making jQuery brilliant. This page translated Belorussian translation
ollicle.com: Biggerlink – jQuery plugin的更多相关文章
- The ultimate jQuery Plugin List(终极jQuery插件列表)
下面的文章可能出自一位奥地利的作者, 列出很多jQuery的插件.类似的网站:http://jquerylist.com/原文地址: http://www.kollermedia.at/archiv ...
- JQuery plugin ---- simplePagination.js API
CSS Themes "light-theme" "dark-theme" "compact-theme" How To Use Step ...
- jQuery plugin: Autocomplete 参数及实例
官网:jQuery plugin: Autocomplete (注:此插件已经不再更新.它的继任者是jQuery UI的一部分,) 此插件依赖于 jquery 1.2.6 --- j ...
- Signs of a poorly written jQuery plugin 翻译 (Jquery插件开发注意事项,Jquey官方推荐)
原文链接:http://remysharp.com/2010/06/03/signs-of-a-poorly-written-jquery-plugin/ 原文作者:remy sharp So far ...
- JQuery Plugin 1 - Simple Plugin
1. How do you write a plugin in jQuery? You can extend the existing jQuery object by writing either ...
- [jQuery] 自做 jQuery Plugin - Part 1
有時候寫 jQuery 時,常會發現一些簡單的效果可以重複利用.只是每次用 Copy & Paste 大法似乎不是件好事,有沒有什麼方法可以讓我們把這些效果用到其他地方呢? 沒錯,就是用 jQ ...
- Element DOM Tree jQuery plugin – Firebug like functionality | RockingCode
Element DOM Tree jQuery plugin – Firebug like functionality | RockingCode Element DOM Tree jQuery pl ...
- HTML5 Video player jQuery plugin
<!DOCTYPE html> <html lang="en" > <head> <meta charset="utf-8&qu ...
- JQuery Plugin 开发
学习 JQuery 插件开发之后, 可以将自己平时常用的功能封装成插件, 便于在不同的项目之间使用. JQuery 官网上的 插件开发教程就很不错, 简单易懂. 参考网址: http://learn. ...
随机推荐
- 图片压缩上传 Android
图片压缩的话 想保持 图像清晰度,但是又想保持图片的大小在100k左右. 同时的话又不想自己写那些压缩的代码的话.那你就找对地方了. 提供一个思路. 先读取你的文件,然后读到bitmap里面进行尺寸裁 ...
- Eclipse开发工具学习之道:用Eclipse生成jar文件
很多人都不知道怎么在Eclipse下生成jar文件,或者生成了jar文件后又老是用不了,总是会收到 Exception in thread "main" java.lang.NoC ...
- css透明背景兼容方案
css透明是一个技术活,因为这里面涉及到了IE8及以下版本不兼容opacity这个css3属性,而filter:alpha(opacity=80)这个值则是不兼容IE6.网上比较流行的透明css是这样 ...
- C语言学习 —— 字符串的学习(一)
这是本人在学习 C语言有关 字符串内容 时的相关笔记 由于本人技术有限,如有错误,还望指正 C语言中数据类型中只有 字符型(char),而 char型 变量一次只能存储一个字符,在日常工作中经常需要定 ...
- Myeclipse普通工程转为Maven工程
在SVN导出的Maven项目,或以前不是用Maven管理的项目想要转换成Maven项目,但Myeclipse中右键Configure 找不到(eclipse可行)Convert to maven pr ...
- vs2013 MVC 无法确定要使用哪一版本的 ASP.NET Web Pages错误
在web.config文件<configuration>节点下添加 <appSettings> <add key="webPages:Version&q ...
- XCode破解真机调试
XCode破解真机调试 3.0 一.这样做以后能怎样 以device模式编译出app 可以再越狱后的设备上运行 二.要会点什么 命令行,也就是terminal.终端.控制台... vim 三.开始吧 ...
- poj1936---subsequence(判断子串)
#include<stdlib.h> #include<stdio.h> int main() { ],t[]; char *p1,*p2; while(scanf(" ...
- 老去的JEE,焕发生命
JEE的社区 JEE从出生到现在,十多年了.在软件领域,好听的说法,基本上就是Legacy系统了,不好听,那就是恐龙.曾经疯魔万千开发者的Springframework, Jboss 社区, Apac ...
- POJ 3111 K Best(最大化平均值)
题目链接:click here~~ [题目大意]有n个物品的重量和价值各自是Wi和Vi.从中选出K个物品使得单位重量的价值最大,输出物品的编号 [解题思路]:最大化平均值的经典.參见click her ...