I have seen a lot of overly complex solutions for this simple problem and none of them have been valid solutions, here is a snippet that accomplishes it in an unambiguous manner. $(‘#el’).dialog({ open: function(e){ var self = this; $(‘.ui-widget-overlay’).bind(‘click’, function(){ $(self).dialog(‘close’); }); }, close: function(){ $(‘.ui-widget-overlay’).unbind(‘click’); } });
The Code $.fn.fill = function(options){ var settings, container, el, calculateHeight, calculateWidth; settings = { fill: window, margins: { x: 0, y: 0 } }; if(options){ $.extend(settings, options); } container = $(settings.fill); el = $(this); calculateWidth = function(){ return (container.width() – settings.margins.x); }; calculateHeight = function(){ return (container.height() – settings.margins.y); } el.css({ width: calculateWidth(), height: calculateHeight() [...]
This is a small piece of code that is mostly the brain child of the incredible David Walsh. His version is written in MooTools and you can see it here. There are a few differences however, I removed some of the basic form validation, I set up a Gravatar function to be called onBlur rather [...]
Hopefully the plug-ins and classes I write are simple enough to figure out and manipulate. Its an extremely simple and customizable little testimonial rotator that also supports HTML. So yes your quotes can have links, logos or even avatars. It will support as many quotes or testimonials you may need. The options that can be [...]