jQuery Plugins

2011.04.11

sausage.js
Sausage is a jQuery UI widget for contextual pagination. It complements long or infinite-scrolling pages by keeping the user informed of her location within the document.

Javascript-283 in Useful JavaScript and jQuery Tools, Libraries, Plugins

jQuery Waypoints
Waypoints is a small jQuery plugin that makes it easy to execute a function whenever you scroll to an element.

Javascript-234 in Useful JavaScript and jQuery Tools, Libraries, Plugins

Pietimer jQuery Plugin
Pietimer injects a canvas element into the page which has an ever reducing pie shaped timer.

Javascript-303 in Useful JavaScript and jQuery Tools, Libraries, Plugins

ImageLens: a jQuery plug-in for Lens Effect Image Zooming
You can use this jQuery plug-in to add lens style zooming effect to an image.

Javascript-306 in Useful JavaScript and jQuery Tools, Libraries, Plugins

Timeglider jQuery Plugin/Widget
Timeglider is a zooming, panning data-driven timeline — great for history projects, project planning or any other tasks where you’ll need to display a time frame.

Javascript-307 in Useful JavaScript and jQuery Tools, Libraries, Plugins

960 Grid on jQuery-Mobile
A port of a 960 grids to use in jQuery mobile. It aims to bring more flexibility to jQuery-mobile layouts and thus makes it easier to use on tablets. The code is available on Github under MIT license.

Javascript-130 in Useful JavaScript and jQuery Tools, Libraries, Plugins

diagonalFade jQuery plugin
A jQuery plugin allowing you to easily specify direction, fade-in, fade-out, and a host of other options to a grouping of elements.

Javascript-308 in Useful JavaScript and jQuery Tools, Libraries, Plugins

Wijmo jQuery UI Widgets
Wijmo is a complete kit of over 30 UI widgets with everything from interactive menus to rich charts. If you know jQuery, you know Wijmo. Complete with documentation and professional support, every widget is hand-crafted and includes premium themes.

Javascript-267 in Useful JavaScript and jQuery Tools, Libraries, Plugins

Lettering.js – A jQuery Plugin for Radical Web Typography
CSS does not offer a complete down-to-the-letter control. Here you’ll find kerning type, editorial design, manageable code and complete control — just a few examples of what can easily by done with Lettering.js.

Javascript-160 in Useful JavaScript and jQuery Tools, Libraries, Plugins

jslide
jslide is a jQuery plugin to create a simple slideshow of list elements, containing either images or other content.

Javascript-201 in Useful JavaScript and jQuery Tools, Libraries, Plugins

Isotope: A jQuery Plugin for Magical Layouts
An exquisite jQuery plugin for magical layouts. Enables filtering, sorting, and dynamic layouts. Isotope’s capabilities are designed to be used together cohesively. You can do it all — filter, sort, change layout modes, add items — and Isotope will handle it with ease.

Javascript-131 in Useful JavaScript and jQuery Tools, Libraries, Plugins

Better Check Boxes with jQuery and CSS
In this short tutorial, the authors will create a replacement for the default browser checkboxes in the form of a simple jQuery plugin.

Javascript-286 in Useful JavaScript and jQuery Tools, Libraries, Plugins

Thumbnails Navigation Gallery with jQuery
In this tutorial the authors are going to create an extraordinary gallery with scrollable thumbnails that slide out from a navigation. They are going to use jQuery and some CSS3 properties for the style.

Javascript-270 in Useful JavaScript and jQuery Tools, Libraries, Plugins

jQuery Quicktag
Quicktag is a tagging plugin for the jQuery JavaScript library.

DataTables (table plug-in for jQuery)
DataTables is a plug-in for the jQuery Javascript library. It is a highly flexible tool, based upon the foundations of progressive enhancement, which will add advanced interaction controls to any HTML table.

Javascript-262 in Useful JavaScript and jQuery Tools, Libraries, Plugins

jQuery Tags Input
This plugin will turn your boring tag list into a magical input that turns each tag into a style-able object with its own delete link. The plugin handles all the data — your form just sees a comma-delimited list of tags.

Javascript-274 in Useful JavaScript and jQuery Tools, Libraries, Plugins

jquery.timepickr.js
a jQuery library that enhances a date picker input area with a more convenient date selection.

Javascript-224 in Useful JavaScript and jQuery Tools, Libraries, Plugins


原文地址:http://www.smashingmagazine.com/2011/04/07/useful-javascript-and-jquery-tools-libraries-plugins/

 

Creative Radical Web Typography

New FancyMoves Jquery Product Slider

Jquery Space Gallery

Fancy Thumbnail Hover Effect

Jquery Inline Form Validation

Site Switcher

AnythingSlider

Jquery Tooltip Coda Bubble

Jquery Upload and Crop Image

jQuery Carts

Twitter-like login box

Polaroid Photo Viewer

jquery Hover Sub Tag Cloud

Graph Visualization

Show/Hide Jquery Panel

Drop Down with CSS and jQuery

Quick & Easy Zooming With jQuery – Zoomy

Horizontal Accordions

Flexible Rating


原文:http://www.topdesignmag.com/20-useful-jquery-plugins-every-developer-should-know-about/

 
    <a onclick="alert('Click event')" href="#">单击事件</a>
    当点击一个链接时,其触发了链接元素的单击事件,该事件则引发任何已绑定到该元素的单击事件上的函数的执行。这个时候会弹出消息“Click event"。click事件接着会向树的根方向传播,广播到父元素,然后接着是每个祖先元素直至document根节点,只要是它的某个后代元素上的单击事件被触发,事件就会传给它,这称之为事件冒泡(又称事件传播)

.bind() :
    $('a').bind('click', function() { alert("jQuery bind") });
    jQuery扫描文档找出所有的$('a')元素,并把alert函数绑定到每个元素的click事件上。

.live() :
    $('a').live('click', function() { alert("jQuery live") });
    jQuery把alert函数绑定到$(document)元素上,并使用'click'和'a'作为参数。任何时候只要有事件冒泡到document节点上,它就查看该事件是否是一个click事件,以及该事件的目标元素与'a'这一CSS选择器是否匹配,如果都是的话,则执行函数。
    live方法还可以被绑定到具体的元素(或“context”)而不是document上,像这样:
    $('a', $('#container')[0]).live(...);
    提示:$('#container')返回的是jQuery对象,$('#container')[0]是这个标签的DOM对象。
    live方法有一个非常大的缺点,那就是它仅能针对直接的CSS选择器做操作。

.delegate()
    $('#container').delegate('a', 'click', function() { alert("jQuery delegate") });
    jQuery扫描文档查找$('#container'),并使用click事件和'a'这一CSS选择器作为参数把alert函数绑定到$('#container')上。任何时候只要有事件冒泡到$('#container')上,它就查看该事件是否是click事件,以及该事件的目标元素是否与CCS选择器相匹配。如果两种检查的结果都为真的话,它就执行函数。
    这一过程与.live()类似,但是其把处理程序绑定到具体的元素而非document这一根上。但是$('a').live()等同于$(document).delegate('a')吗?不完全是。

为什么.delegate()要比.live()好用
    基于几个原因,人们通常更愿意选用jQuery的delegate方法而不是live方法。考虑下面的例子:
    $('a').live('click', function() { blah() });
    // 或者
    $(document).delegate('a', 'click', function() { blah() });

速度:
    后者实际上要快过前者,因为前者首先要扫描整个的文档查找所有的$('a')元素,把它们存成jQuery对象。尽管live函数仅需要把 'a' 作为串参数传递以用做之后的判断,但是$()函数并未“知道”被链接的方法将会是.live()。
    而另一方面,delegate方法仅需要查找并存储$(document)元素。
    一种寻求避开这一问题的方法是调用在$(document).ready()之外绑定的live,这样它就会立即执行。在这种方式下,其会在DOM获得填充之前运行,因此就不会查找元素或是创建jQuery对象了。

灵活性和链能力:
    live函数也挺令人费解的。想想看,它被链到$(‘a’)对象集上,但其实际上是在$(document)对象上发生作用。由于这个原因,它能够试图以一种吓死人的方式来把方法链到自身上。实际上,我想说的是,以$.live(‘a’,…)这一形式作为一种全局性的jQuery方法,live方法会更具意义一些。

仅支持CSS选择器:
    前面有讲过live方法有一个非常大的缺点,那就是它仅能针对直接的CSS选择器做操作,这使得它变得非常的不灵活。

为什么选择.live()或.delegate()而不是.bind() ?
    毕竟,bind看起来似乎更加的明确和直接,难道不是吗?嗯,有两个原因让我们更愿意选择delegate或live而不是bind:
    为了把处理程序附加到可能还未存在于DOM中的DOM元素之上。因为bind是直接把处理程序绑定到各个元素上,它不能把处理程序绑定到还未存在于页面中的元素之上。
    如果你运行了$(‘a’).bind(…),而后新的链接经由AJAX加入到了页面中,则你的bind处理程序对于这些新加入的链接来说是无效的。而另一方面live和delegate则是被绑定到另一个祖先节点上,因此其对于任何目前或是将来存在于该祖先元素之内的元素都是有效的。
   或者为了把处理程序附加到单个元素上或是一小组元素之上,监听后代元素上的事件而不是循环遍历并把同一个函数逐个附加到DOM中的100个元素上。把处理程序附加到一个(或是一小组)祖先元素上而不是直接把处理程序附加到页面中的所有元素上,这种做法带来了性能上的好处。

停止传播(阻止冒泡事件传递)
    通常情况下,我们可以通过使用这样的事件方法来终止处理函数的执行:
    $('a').bind('click', function(e) {
        e.preventDefault();    // 或者 e.stopPropagation();
});
    不过,当我们使用live或是delegate方法的时候,处理函数实际上并没有在运行,需要等到事件冒泡到处理程序实际绑定的元素上时函数才会运行。而到此时为止,我们的其他的来自.bind()的处理函数早已运行了。

参考:
http://article.yeeyan.org/view/213582/179910
http://www.alfajango.com/blog/the-difference-between-jquerys-bind-live-and-delegate/
 
之前在hostmonster上的服务到期了一直没有转到新的VPS上,昨晚折腾了一下把网站用Rails3重构了一下,原有的JavaScriptjQuery文档小抄可以正常访问了,qefqei.com(这就是你所要找的,这就是你所要做的)做了快三年了,一直以没时间为借口,更新甚少,很是惭愧!
 
function getSelectText() {
    return document.selection && document.selection.createRange().text || window.getSelection && window.getSelection() || document.getSelection && document.getSelection() || '';
}
支持IE6、Firefox和Chrome
原文:用JavaScript获取选中的文字
参考:获取鼠标选择的文本内容之JavaScript代码
参考:Use JavaScript and jQuery to Get User Selected Text, and then Do Something (Useful?) With It
 

Home Blog Delicious Github Flickr

© Miclle.Zheng . Powered by Forest Chalet