<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>The JavaScript Blog &#187; jQuery</title>
	<atom:link href="http://thejavascriptblog.com/category/frameworks/jquery/feed/" rel="self" type="application/rss+xml" />
	<link>http://thejavascriptblog.com</link>
	<description>Everything JavaScript</description>
	<lastBuildDate>Sat, 09 Jul 2011 19:16:00 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.1</generator>
		<item>
		<title>jQuery UI Close Dialog on Overlay Click</title>
		<link>http://thejavascriptblog.com/jquery-ui-close-dialog-on-overlay-click/</link>
		<comments>http://thejavascriptblog.com/jquery-ui-close-dialog-on-overlay-click/#comments</comments>
		<pubDate>Sat, 09 Jul 2011 19:16:00 +0000</pubDate>
		<dc:creator>Merrick Christensen</dc:creator>
				<category><![CDATA[Frameworks]]></category>
		<category><![CDATA[jQuery]]></category>
		<category><![CDATA[Snippets]]></category>

		<guid isPermaLink="false">http://thejavascriptblog.com/?p=111</guid>
		<description><![CDATA[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'); } });]]></description>
			<content:encoded><![CDATA[<p>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.</p>
<pre>
$('#el').dialog({
open: function(e){
          var self = this;
          $('.ui-widget-overlay').bind('click', function(){
            $(self).dialog('close');
          });
        },

        close: function(){
          $('.ui-widget-overlay').unbind('click');
        }
});
</pre>
]]></content:encoded>
			<wfw:commentRss>http://thejavascriptblog.com/jquery-ui-close-dialog-on-overlay-click/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>When Percents Just Don&#8217;t Cut It</title>
		<link>http://thejavascriptblog.com/when-percents-just-dont-cut-it/</link>
		<comments>http://thejavascriptblog.com/when-percents-just-dont-cut-it/#comments</comments>
		<pubDate>Wed, 02 Mar 2011 16:46:57 +0000</pubDate>
		<dc:creator>Merrick Christensen</dc:creator>
				<category><![CDATA[Extensions]]></category>
		<category><![CDATA[Frameworks]]></category>
		<category><![CDATA[jQuery]]></category>
		<category><![CDATA[Plugins]]></category>
		<category><![CDATA[Snippets]]></category>

		<guid isPermaLink="false">http://thejavascriptblog.com/?p=105</guid>
		<description><![CDATA[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() [...]]]></description>
			<content:encoded><![CDATA[<h2>The Code</h2>
<pre>
$.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()
	});

	container.resize(function(){
	       el.css({
	       width: calculateWidth(),
	       height: calculateHeight()
		});

	});
};
</pre>
<h2>Usage</h2>
<pre>
$('#dashboard').fill({
	margins : {
		x: (80 + $('#sidebar').width()),
		y: 100
	}
});
</pre>
<p>This snippet fills the entire window with the dashboard minus the sidebar and 100 pixel padding on the y axis.</p>
]]></content:encoded>
			<wfw:commentRss>http://thejavascriptblog.com/when-percents-just-dont-cut-it/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>The jQuery Comment Previewer</title>
		<link>http://thejavascriptblog.com/the-jquery-comment-previewer/</link>
		<comments>http://thejavascriptblog.com/the-jquery-comment-previewer/#comments</comments>
		<pubDate>Thu, 13 Aug 2009 07:08:07 +0000</pubDate>
		<dc:creator>Merrick Christensen</dc:creator>
				<category><![CDATA[Frameworks]]></category>
		<category><![CDATA[jQuery]]></category>

		<guid isPermaLink="false">http://thejavascriptblog.com/?p=26</guid>
		<description><![CDATA[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 [...]]]></description>
			<content:encoded><![CDATA[<p>This is a small piece of code that is mostly the brain child of the incredible <a href="http://davidwalsh.name/">David Walsh</a>. His version is written in MooTools and you can see it <a href="http://davidwalsh.name/comment-preview">here</a>. 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 then keyUp because the flashing Gravatar on each key stroke just got really annoying. While I prefer MooTools I did this in jQuery because:</p>
<ol>
<li><a href="http://davidwalsh.name/">David Walsh</a> already did an excellent MooTools version.</li>
<li>Depending on its popularity I might make this into a WordPress plugin. And since most themes and WordPress are already using jQuery I figured that was the largest market.</li>
<li>Some of his commenters were requesting a jQuery version.</li>
</ol>
<h2>Demo and Download</h2>
<p>You can see it in action <a href="http://thejavascriptblog.com/demos/comment_previewer/">here</a>.<br />
Download a zip <a href="http://thejavascriptblog.com/demos/comment_previewer/downloads/comment_previewer.zip">here</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://thejavascriptblog.com/the-jquery-comment-previewer/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>The Quotator &#8211; The JSON Driven HTML Rotator</title>
		<link>http://thejavascriptblog.com/the-quotator-the-json-driven-html-rotator/</link>
		<comments>http://thejavascriptblog.com/the-quotator-the-json-driven-html-rotator/#comments</comments>
		<pubDate>Thu, 06 Aug 2009 21:17:14 +0000</pubDate>
		<dc:creator>Merrick Christensen</dc:creator>
				<category><![CDATA[Classes]]></category>
		<category><![CDATA[Extensions]]></category>
		<category><![CDATA[Frameworks]]></category>
		<category><![CDATA[jQuery]]></category>
		<category><![CDATA[MooTools]]></category>
		<category><![CDATA[Plugins]]></category>

		<guid isPermaLink="false">http://thejavascriptblog.com/?p=12</guid>
		<description><![CDATA[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 [...]]]></description>
			<content:encoded><![CDATA[<p>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 set are speed (number), json (JSON file URL), and what quote you want to start from (number).</p>
<p>If you have any feature requests, questions, or issues please drop me a comment and I would love to help you out. Here are the details and usage for each of the particular frameworks.</p>
<h2>jQuery</h2>
<pre>
$('#container').quotator();
</pre>
<h2>MooTools</h2>
<pre>
var myQuotes = new Quotator('container');
</pre>
<h2>The JSON</h2>
<p>By default it looks for a file called quotes.js which is a simple JSON file that looks something like this:</p>
<pre>
{"quotes":
[{
"quote" : "Quote 1",
"author" : "Author 1"
},{
"quote" : "Quote 2",
"author" : "Author 2"
}]}
</pre>
<h2>Demo and Download</h2>
<p>You can see it in action <a href="http://www.thejavascriptblog.com/demos/quotator/" title="Quotator Demonstration">here.</a><br />
Download a zip for jQuery <a href="http://thejavascriptblog.com/demos/quotator/downloads/jquery.zip">here.</a><br />
Download a zip for MooTools <a href="http://thejavascriptblog.com/demos/quotator/downloads/mootools.zip">here.</a></p>
]]></content:encoded>
			<wfw:commentRss>http://thejavascriptblog.com/the-quotator-the-json-driven-html-rotator/feed/</wfw:commentRss>
		<slash:comments>25</slash:comments>
		</item>
	</channel>
</rss>

