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 the

elements.

Fusion

jQuery

Google

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

Google

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

Google

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

Google

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的更多相关文章

  1. The ultimate jQuery Plugin List(终极jQuery插件列表)

    下面的文章可能出自一位奥地利的作者,  列出很多jQuery的插件.类似的网站:http://jquerylist.com/原文地址: http://www.kollermedia.at/archiv ...

  2. JQuery plugin ---- simplePagination.js API

    CSS Themes "light-theme" "dark-theme" "compact-theme" How To Use Step ...

  3. jQuery plugin: Autocomplete 参数及实例

    官网:jQuery plugin: Autocomplete          (注:此插件已经不再更新.它的继任者是jQuery UI的一部分,) 此插件依赖于 jquery 1.2.6 --- j ...

  4. 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 ...

  5. JQuery Plugin 1 - Simple Plugin

    1. How do you write a plugin in jQuery? You can extend the existing jQuery object by writing either ...

  6. [jQuery] 自做 jQuery Plugin - Part 1

    有時候寫 jQuery 時,常會發現一些簡單的效果可以重複利用.只是每次用 Copy & Paste 大法似乎不是件好事,有沒有什麼方法可以讓我們把這些效果用到其他地方呢? 沒錯,就是用 jQ ...

  7. Element DOM Tree jQuery plugin – Firebug like functionality | RockingCode

    Element DOM Tree jQuery plugin – Firebug like functionality | RockingCode Element DOM Tree jQuery pl ...

  8. HTML5 Video player jQuery plugin

    <!DOCTYPE html> <html lang="en" > <head> <meta charset="utf-8&qu ...

  9. JQuery Plugin 开发

    学习 JQuery 插件开发之后, 可以将自己平时常用的功能封装成插件, 便于在不同的项目之间使用. JQuery 官网上的 插件开发教程就很不错, 简单易懂. 参考网址: http://learn. ...

随机推荐

  1. 使用fastcgi_cache加速网站

    为了提高网站的性能缓存是一把利器,nginx中可以配置fastcig_cache来缓存不需要实时获取的数据实现动静分离,nginx.conf配置如下: http {     -     fastcgi ...

  2. 幻世(OurDream)2D图形引擎易语言汉化版更新提示

    幻世引擎的易语言汉化专版到目前为止已经累积了多个BUG,其中多个BUG是影响引擎功能使用的问题,我将会在近期发布修复所有问题的更新版本(此更新版本同时也将会支持最新的对加入的粒子系统的支持),敬请各位 ...

  3. 深入理解this对象

    最近一直在看js关于面向对象编程方面的东西,那么this肯定是需要一个被吃透 理解 同时灵活运用的对象 现在总结一下自己的学习成果: 我们可以用一句很形象的话来理解什么是this关键字? " ...

  4. Android 动画系列

    Android种最常用的动画: ~1~Tween动画,就是对场景里的对象不断的进行图像变化来产生动画效果(旋转.平移.放缩和渐变) Tweene Animations 主要类: Animation   ...

  5. hdu 2604Queuing dp+ 矩阵快速幂

    题目链接 给一个长度为n的字符串, 每个字符可以使f或m. 问你不包含子串fmf以及fff的字符串数量有多少. 令0表示mm结尾, 1表示mf, 2表示ff, 3表示fm. 那么 f(n+1, 0) ...

  6. 基于Web的系统测试方法

    基于Web的系统测试与传统的软件测试既有相同之处,也有不同的地方,对软件测试提出了新的挑战.基于Web的系统测试不但需要检查和验证是否按照设计的要求运行,而且还要评价系统在不同用户的浏览器端的显示是否 ...

  7. tail -f

    http://stackoverflow.com/questions/187587/looking-for-a-windows-equivalent-of-the-unix-tail-command ...

  8. C++箴言:避免构造或析构函数中调用虚函数

    如果你已经从另外一种语言如C#或者Java转向了C++,你会觉得,避免在类的构造函数或者析构函数中调用虚函数这一原则有点违背直觉.但是在C++中,违反这个原则会给你带来难以预料的后果和无尽的烦恼. 正 ...

  9. 嵌入式davinci电路元素基础和PWM模块

    1,DAC_OUT和DAC_OUTB是AD9912输出的差分信号. 2,电容器储存电荷的能力,常用的单位是F.uF.nF.pFUF大了好还是UF小了好,要根据电路自身需要而设计, 要看电路滤波是在高频 ...

  10. Android重启应用程序代码

    Intent i = getBaseContext().getPackageManager() .getLaunchIntentForPackage(getBaseContext().getPacka ...