<?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>Daily Resources for Web Designers &#38; Developers by Andy Sowards &#187; Javascript</title>
	<atom:link href="http://www.andysowards.com/blog/category/javascript/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.andysowards.com/blog</link>
	<description>Inspiration &#38; Resources for Creatives</description>
	<lastBuildDate>Thu, 09 Feb 2012 05:26:53 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	
		<item>
		<title>Top 5 Responsive Website Designs on the Web</title>
		<link>http://www.andysowards.com/blog/2012/top-5-responsive-website-designs-on-the-web/</link>
		<comments>http://www.andysowards.com/blog/2012/top-5-responsive-website-designs-on-the-web/#comments</comments>
		<pubDate>Wed, 01 Feb 2012 05:06:47 +0000</pubDate>
		<dc:creator>Jules</dc:creator>
				<category><![CDATA[architecture]]></category>
		<category><![CDATA[Code]]></category>
		<category><![CDATA[Design]]></category>
		<category><![CDATA[Development]]></category>
		<category><![CDATA[freelance]]></category>
		<category><![CDATA[Inspiration]]></category>
		<category><![CDATA[Javascript]]></category>
		<category><![CDATA[jQuery]]></category>
		<category><![CDATA[Mobile]]></category>
		<category><![CDATA[programming]]></category>
		<category><![CDATA[2011]]></category>
		<category><![CDATA[2012]]></category>
		<category><![CDATA[awesome]]></category>
		<category><![CDATA[beautiful]]></category>
		<category><![CDATA[best]]></category>
		<category><![CDATA[code]]></category>
		<category><![CDATA[collection]]></category>
		<category><![CDATA[creative]]></category>
		<category><![CDATA[CSS]]></category>
		<category><![CDATA[css3]]></category>
		<category><![CDATA[enhancement]]></category>
		<category><![CDATA[epic]]></category>
		<category><![CDATA[example]]></category>
		<category><![CDATA[Examples]]></category>
		<category><![CDATA[future]]></category>
		<category><![CDATA[great]]></category>
		<category><![CDATA[html]]></category>
		<category><![CDATA[html/css]]></category>
		<category><![CDATA[html5]]></category>
		<category><![CDATA[inspirational]]></category>
		<category><![CDATA[ipad]]></category>
		<category><![CDATA[iphone]]></category>
		<category><![CDATA[media]]></category>
		<category><![CDATA[mobile]]></category>
		<category><![CDATA[mobile-design]]></category>
		<category><![CDATA[mobile-optimization]]></category>
		<category><![CDATA[mobile-website]]></category>
		<category><![CDATA[operating-system]]></category>
		<category><![CDATA[optimize]]></category>
		<category><![CDATA[OS]]></category>
		<category><![CDATA[progressive]]></category>
		<category><![CDATA[resolution]]></category>
		<category><![CDATA[responsive]]></category>
		<category><![CDATA[responsive-design-view]]></category>
		<category><![CDATA[sdk]]></category>
		<category><![CDATA[smartphone]]></category>
		<category><![CDATA[stylesheet]]></category>
		<category><![CDATA[the-best]]></category>
		<category><![CDATA[top-5]]></category>
		<category><![CDATA[ui]]></category>
		<category><![CDATA[unique]]></category>
		<category><![CDATA[user]]></category>
		<category><![CDATA[user-experience]]></category>
		<category><![CDATA[user-interface]]></category>
		<category><![CDATA[ux]]></category>
		<category><![CDATA[view]]></category>
		<category><![CDATA[web-design]]></category>
		<category><![CDATA[webdesign]]></category>
		<category><![CDATA[website]]></category>
		<category><![CDATA[website-design]]></category>

		<guid isPermaLink="false">http://www.andysowards.com/blog/?p=7878</guid>
		<description><![CDATA[<p><a href='http://rss.buysellads.com/click.php?z=1265932&k=796ff8632dc2a5b0a7fd0971b688b49f&a=7878&c=1771441912' target='_blank' rel='nofollow'>
				<img src='http://rss.buysellads.com/img.php?z=1265932&k=796ff8632dc2a5b0a7fd0971b688b49f&a=7878&c=1771441912' border='0' alt='' /></a></p><p><a href='http://buysellads.com/buy/sitedetails/pubkey/796ff8632dc2a5b0a7fd0971b688b49f/zone/1265932' target='_blank'>Advertise here with BSA</a></p><br />Tweet Responsive Web Design is one of the most talked about trends in Web Design today, and will continue to remain a hot topic for as long as Smartphones and Tablets continue their domination in the handheld device industry. Research<br /><br /><a href="http://www.andysowards.com/blog/2012/top-5-responsive-website-designs-on-the-web/"><span class="button">Read More &#187;</span></a>]]></description>
			<content:encoded><![CDATA[<p><a href='http://rss.buysellads.com/click.php?z=1265932&k=796ff8632dc2a5b0a7fd0971b688b49f&a=7878&c=1732916402' target='_blank' rel='nofollow'>
				<img src='http://rss.buysellads.com/img.php?z=1265932&k=796ff8632dc2a5b0a7fd0971b688b49f&a=7878&c=1732916402' border='0' alt='' /></a></p><p><a href='http://buysellads.com/buy/sitedetails/pubkey/796ff8632dc2a5b0a7fd0971b688b49f/zone/1265932' target='_blank'>Advertise here with BSA</a></p><br /><div id="tweetbutton7878" class="tw_button" style=""><a href="http://twitter.com/share?url=http%3A%2F%2Fwww.andysowards.com%2Fblog%2F2012%2Ftop-5-responsive-website-designs-on-the-web%2F&amp;via=andysowards&amp;text=Top%205%20Responsive%20Website%20Designs%20on%20the%20Web&amp;related=&amp;lang=en&amp;count=horizontal&amp;counturl=http%3A%2F%2Fwww.andysowards.com%2Fblog%2F2012%2Ftop-5-responsive-website-designs-on-the-web%2F" class="twitter-share-button"  style="width:55px;height:22px;background:transparent url('http://www.andysowards.com/blog/wp-content/plugins/wp-tweet-button/tweetn.png') no-repeat  0 0;text-align:left;text-indent:-9999px;display:block;">Tweet</a></div><div class="alignright"><div class="g-plusone" data-href="http://www.andysowards.com/blog/2012/top-5-responsive-website-designs-on-the-web/" size="tall" count="true"></div></div><div class="fblike_button" style="margin: 10px 0;"><iframe src="http://www.facebook.com/plugins/like.php?href=http%3A%2F%2Fwww.andysowards.com%2Fblog%2F2012%2Ftop-5-responsive-website-designs-on-the-web%2F&amp;layout=standard&amp;show_faces=true&amp;width=450&amp;action=like&amp;colorscheme=light" scrolling="no" frameborder="0" allowTransparency="true" style="border:none; overflow:hidden; width:450px; height:25px"></iframe></div>
<p>Responsive Web Design is one of the most talked about trends in Web Design today, and will continue to remain a hot topic for as long as Smartphones and Tablets continue their domination in the handheld device industry. Research shows that the percentage of users accessing the internet through a handheld device is increasing exponentially, so if you haven&#8217;t considered the use of responsive design in your projects, it might be a good time to start exploring the techniques behind it.  </p>
<p>Responsive Web Design is a term first coined by <a href="http://ethanmarcotte.com/" target="_blank">Ethan Marcotte</a>, which went viral after a blog post on <a href="http://www.alistapart.com/" target="_blank">A List Apart</a> back in 2010. Essentially, responsive web design refers to a websites ability to respond to the browser size in which it is viewed to enhance a users experience and ensure maximum exposure for the content itself. This will mean that the text is legible without having to zoom in and images are resized contextually  allowing them to fit the browser screen without the need to scroll horizontally. Many design elements become invisible or hidden when viewed on a smaller browser size, which allows the user to get access to what they visited for  the content itself.  </p>
<p>In a sense, responsive web design is reminiscent of the old &#8216;text-based&#8217; websites that we used to see of yesteryear, which primarily used to accommodate users on dial-up modems and slower internet connections to ensure faster page loading times. These days, whilst a responsive design does focus on the content, it also allows for some design elements to be incorporated to ensure consistency across all browsers  which is essential for any brand strategy. </p>
<p>Responsive web design is still in its infancy however, and as with any new design technology, it takes time to be assimilated by the design world as a whole. For the Designer, it&#8217;s still very much a playground of trialling and testing new techniques &#8211;  as the full potential of responsive web design is as yet uncharted. </p>
<p>Many designers have embraced the challenge and possibilities that responsive design presents  and you should too! Below are my Top 5 Responsive Web Designs for your viewing pleasure and inspiration&#8230; </p>
<h2>1. <a href="http://forefathersgroup.com/" target="_blank">Forefathers Group</a></h2>
<p><a href="http://forefathersgroup.com/" target="_blank"><img src="http://www.andysowards.com/blog/assets/forefathers-group.jpg" alt="" title="forefathers-group" width="600" height="340" class="alignnone size-full wp-image-7882" /></a></p>
<h2>2. <a href="http://sasquatchfestival.com/" target="_blank">Sasquatch Music Festival</a></h2>
<p><a href="http://sasquatchfestival.com/" target="_blank"><img src="http://www.andysowards.com/blog/assets/sasquatch-music-festival.jpg" alt="" title="sasquatch-music-festival" width="600" height="340" class="alignnone size-full wp-image-7883" /></a></p>
<h2>3. <a href="http://www.benhandzo.com/" target="_blank">Ben Handzo Photography</a></h2>
<p><a href="http://www.benhandzo.com/" target="_blank"><img src="http://www.andysowards.com/blog/assets/ben-handzo-photography.jpg" alt="" title="ben-handzo-photography" width="600" height="340" class="alignnone size-full wp-image-7879" /></a></p>
<h2>4. <a href="http://www.illyissimo.com/" target="_blank">Illy Issimo</a></h2>
<p><a href="http://www.illyissimo.com/" target="_blank"><img src="http://www.andysowards.com/blog/assets/illy-issimo.jpg" alt="" title="illy-issimo" width="600" height="340" class="alignnone size-full wp-image-7881" /></a></p>
<h2>5. <a href="http://www.deren.me/" target="_blank">Deren Keskin</a></h2>
<p><a href="http://www.deren.me/" target="_blank"><img src="http://www.andysowards.com/blog/assets/deren-keskin.jpg" alt="" title="deren-keskin" width="600" height="340" class="alignnone size-full wp-image-7880" /></a><br />
<h3 class='related_post_title'>If you like this, You&#8217;ll love These.</h3>
<ul class='related_post'>
<li><a href='http://www.andysowards.com/blog/2009/daily-links-253/' title='#WDNDL For 7/08/2009 – Packaging, Logos, Login/Contact Page Inspirations &amp; MORE! '>#WDNDL For 7/08/2009 – Packaging, Logos, Login/Contact Page Inspirations &#038; MORE! </a></li>
<li><a href='http://www.andysowards.com/blog/2009/daily-links-145/' title='AndySowards.com :: Web Development Nerdy Daily Links For 2/20/2009'>AndySowards.com :: Web Development Nerdy Daily Links For 2/20/2009</a></li>
<li><a href='http://www.andysowards.com/blog/2008/daily-links-38/' title='AndySowards.com :: Web Development Nerdy Daily Links For 10/23/2008'>AndySowards.com :: Web Development Nerdy Daily Links For 10/23/2008</a></li>
<li><a href='http://www.andysowards.com/blog/2009/daily-links-247/' title='#WDNDL For 6/24/2009 – CSS3, jQuery Plugins, WP Guides, Interviews &amp; Web Interfaces(UX/UI)!'>#WDNDL For 6/24/2009 – CSS3, jQuery Plugins, WP Guides, Interviews &#038; Web Interfaces(UX/UI)!</a></li>
<li><a href='http://www.andysowards.com/blog/2009/daily-links-174/' title='Web Development Nerdy Daily Links For 3/21/2009 &#8211; HUGE POST!'>Web Development Nerdy Daily Links For 3/21/2009 &#8211; HUGE POST!</a></li>
<li><a href='http://www.andysowards.com/blog/2010/wdndl-for-2262010-%e2%80%93-inspiration-user-interface-logos-cssjqueryajax-tutorials-geek-news/' title='#WDNDL For 2/26/2010 – Inspiration, User Interface, Logos, CSS/jQuery/AJAX Tutorials &amp; Geek News!'>#WDNDL For 2/26/2010 – Inspiration, User Interface, Logos, CSS/jQuery/AJAX Tutorials &#038; Geek News!</a></li>
</ul>
<div class="fblike_button" style="margin: 10px 0;"><iframe src="http://www.facebook.com/plugins/like.php?href=http%3A%2F%2Fwww.andysowards.com%2Fblog%2F2012%2Ftop-5-responsive-website-designs-on-the-web%2F&amp;layout=standard&amp;show_faces=true&amp;width=450&amp;action=like&amp;colorscheme=light" scrolling="no" frameborder="0" allowTransparency="true" style="border:none; overflow:hidden; width:450px; height:25px"></iframe></div>
]]></content:encoded>
			<wfw:commentRss>http://www.andysowards.com/blog/2012/top-5-responsive-website-designs-on-the-web/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How To Redirect Visitors To Another Site Or Page &#8211; Different Techniques &amp; Explanations for Beginners</title>
		<link>http://www.andysowards.com/blog/2011/how-to-redirect-visitors-to-another-site-or-page-different-techniques-explanations-for-beginners/</link>
		<comments>http://www.andysowards.com/blog/2011/how-to-redirect-visitors-to-another-site-or-page-different-techniques-explanations-for-beginners/#comments</comments>
		<pubDate>Wed, 28 Dec 2011 13:02:00 +0000</pubDate>
		<dc:creator>Pixel Crayon</dc:creator>
				<category><![CDATA[apache]]></category>
		<category><![CDATA[Computer Science]]></category>
		<category><![CDATA[geek]]></category>
		<category><![CDATA[Javascript]]></category>
		<category><![CDATA[programming]]></category>
		<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[actionscript']]></category>
		<category><![CDATA[asp]]></category>
		<category><![CDATA[asp.net]]></category>
		<category><![CDATA[bounce]]></category>
		<category><![CDATA[browser]]></category>
		<category><![CDATA[code]]></category>
		<category><![CDATA[directory]]></category>
		<category><![CDATA[domain]]></category>
		<category><![CDATA[easy]]></category>
		<category><![CDATA[example]]></category>
		<category><![CDATA[flash]]></category>
		<category><![CDATA[head]]></category>
		<category><![CDATA[header]]></category>
		<category><![CDATA[howto]]></category>
		<category><![CDATA[java]]></category>
		<category><![CDATA[jQuery]]></category>
		<category><![CDATA[js]]></category>
		<category><![CDATA[language]]></category>
		<category><![CDATA[location]]></category>
		<category><![CDATA[move]]></category>
		<category><![CDATA[path]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[quick]]></category>
		<category><![CDATA[redirect]]></category>
		<category><![CDATA[redirect-url]]></category>
		<category><![CDATA[redirection]]></category>
		<category><![CDATA[relocate]]></category>
		<category><![CDATA[script]]></category>
		<category><![CDATA[server]]></category>
		<category><![CDATA[side]]></category>
		<category><![CDATA[site]]></category>
		<category><![CDATA[snippet]]></category>
		<category><![CDATA[technique]]></category>
		<category><![CDATA[tutorial]]></category>
		<category><![CDATA[unix]]></category>
		<category><![CDATA[url]]></category>

		<guid isPermaLink="false">http://www.andysowards.com/blog/?p=7172</guid>
		<description><![CDATA[<p><a href='http://rss.buysellads.com/click.php?z=1265932&k=796ff8632dc2a5b0a7fd0971b688b49f&a=7172&c=1557143946' target='_blank' rel='nofollow'>
				<img src='http://rss.buysellads.com/img.php?z=1265932&k=796ff8632dc2a5b0a7fd0971b688b49f&a=7172&c=1557143946' border='0' alt='' /></a></p><p><a href='http://buysellads.com/buy/sitedetails/pubkey/796ff8632dc2a5b0a7fd0971b688b49f/zone/1265932' target='_blank'>Advertise here with BSA</a></p><br />Tweet Redirecting web pages is an oft used term in search engine optimization. In fact, it is important for all webmasters carrying out search engine optimization of their sites to learn about redirecting web pages. Redirecting a page holds much<br /><br /><a href="http://www.andysowards.com/blog/2011/how-to-redirect-visitors-to-another-site-or-page-different-techniques-explanations-for-beginners/"><span class="button">Read More &#187;</span></a>]]></description>
			<content:encoded><![CDATA[<p><a href='http://rss.buysellads.com/click.php?z=1265932&k=796ff8632dc2a5b0a7fd0971b688b49f&a=7172&c=1247136111' target='_blank' rel='nofollow'>
				<img src='http://rss.buysellads.com/img.php?z=1265932&k=796ff8632dc2a5b0a7fd0971b688b49f&a=7172&c=1247136111' border='0' alt='' /></a></p><p><a href='http://buysellads.com/buy/sitedetails/pubkey/796ff8632dc2a5b0a7fd0971b688b49f/zone/1265932' target='_blank'>Advertise here with BSA</a></p><br /><div id="tweetbutton7172" class="tw_button" style=""><a href="http://twitter.com/share?url=http%3A%2F%2Fwww.andysowards.com%2Fblog%2F2011%2Fhow-to-redirect-visitors-to-another-site-or-page-different-techniques-explanations-for-beginners%2F&amp;via=andysowards&amp;text=How%20To%20Redirect%20Visitors%20To%20Another%20Site%20Or%20Page%20%26%238211%3B%20Different%20Techniques%20%26%23038%3B%20Explanations...%20&amp;related=&amp;lang=en&amp;count=horizontal&amp;counturl=http%3A%2F%2Fwww.andysowards.com%2Fblog%2F2011%2Fhow-to-redirect-visitors-to-another-site-or-page-different-techniques-explanations-for-beginners%2F" class="twitter-share-button"  style="width:55px;height:22px;background:transparent url('http://www.andysowards.com/blog/wp-content/plugins/wp-tweet-button/tweetn.png') no-repeat  0 0;text-align:left;text-indent:-9999px;display:block;">Tweet</a></div><div class="alignright"><div class="g-plusone" data-href="http://www.andysowards.com/blog/2011/how-to-redirect-visitors-to-another-site-or-page-different-techniques-explanations-for-beginners/" size="tall" count="true"></div></div><div class="fblike_button" style="margin: 10px 0;"><iframe src="http://www.facebook.com/plugins/like.php?href=http%3A%2F%2Fwww.andysowards.com%2Fblog%2F2011%2Fhow-to-redirect-visitors-to-another-site-or-page-different-techniques-explanations-for-beginners%2F&amp;layout=standard&amp;show_faces=true&amp;width=450&amp;action=like&amp;colorscheme=light" scrolling="no" frameborder="0" allowTransparency="true" style="border:none; overflow:hidden; width:450px; height:25px"></iframe></div>
<p>Redirecting web pages is an oft used term in search engine optimization. In fact, it is important for all webmasters carrying out search engine optimization of their sites to learn about redirecting web pages. Redirecting a page holds much importance in SEO. This is because inbound links to a web page are considered by search engine ranking algorithms while ranking websites. Therefore, one must know what it is meant by redirecting a page and what are the different techniques of redirecting a page. </p>
<p><img src="http://www.andysowards.com/blog/assets/shutterstock_17681647.jpg" alt="" title="shutterstock_17681647" width="500" height="335" class="alignnone size-full wp-image-7174" /><br />
<em><a href="http://www.shutterstock.com/cat.mhtml?lang=en&#038;search_source=search_form&#038;version=llv1&#038;anyorall=all&#038;safesearch=1&#038;searchterm=redirect&#038;search_group=&#038;orient=&#038;search_cat=&#038;searchtermx=&#038;photographer_name=&#038;people_gender=&#038;people_age=&#038;people_ethnicity=&#038;people_number=&#038;commercial_ok=&#038;color=&#038;show_color_wheel=1#id=17681647&#038;src=32807530a112e5bb174166f6ddd4b4b8-1-94" target="_blank">Redirect Image</a> Via Shutterstock</em></p>
<h2>What is meant by redirecting a page? </h2>
<p>Whenever a web browser or search engine crawler  requests a page at a particular URL on any web site, the web server on which that site is hosted tries to locate the page at that URL so that it can return the corresponding HTML to the requester. Now if that web page exists then the server returns the HTML needed to render that page . It also returns a 200 HTTP status in the header of the response. With this status, the requesting browser or crawler gets the message that the page was found and its HTML was returned. </p>
<p>Sometimes some web pages need to be deleted or moved to a new location. In such a case, a webmaster has two options. First, he can all all future requests for the old web page to be returned to a 404 HTTP status that indicates that the page could not be found. Second, he can ask the browser or search engine crawler to request the page using a new URL. There is a temporary redirect as well as a permanent redirect. </p>
<h2>Advantages of redirecting web pages </h2>
<p>1. First of all, a redirect lets a site to inform visitors that the page or entire site has been moved to a different web address. It also tells the visitors that the redirection process is automatic and the new address is displayed on the browser. </p>
<p>2. With the help of a permanent redirect, one can perform actions like switching domains, redirecting a part of the website to a new domain or redirecting a folder on your site to a new folder. </p>
<h2>Different techniques to redirect a web page </h2>
<p>There are different techniques available for redirecting a web page. Some of these techniques are discussed here in detail. </p>
<h3>1. Browser side redirection using Javascript</h3>
<p>JavaScript can be used to redirect web pages. This technique is useful as it makes the redirection conditioned. This is how drop down menus are created. You can also redirect a page without a condition. This is used to cloak the content. By cloaking the content, it will still be interpreted by the search engines as they can penetrate through the JavaScript and at the same time users will be swiftly redirected. Redirecting a page using JavaScript is more instant than &#8216;instant&#8217; meta-refresh redirection if the code is placed in the header because meta-refresh waits for the page to load first. These days search engines know how to look for redirection in Javascript. Therefore, you can choose to encrypt the script or load it from a remote file as per your convenience. </p>
<p><code>/* example */<br />
window.location = "http://www.google.com/";<br />
</code></p>
<h3>2. Browser side redirection using HTML </h3>
<p>You can use HTML to redirect a page. Here you can use  the meta-refresh tag to redirect a page immediately or after a period of time. However, one thing that should be borne in mind is that some search engines penalize pages that use page redirection technique with short  delays. This is because it could appear as a cloaking attempt. Cloaking means that human users are redirected too quickly to read the page. However, this technique can be useful to redirect to a different site of yours or directly to a sponsors page, with your referral code after 350 seconds. The idea behind this is that a surfer has your site in a stack of windows or tabs and as he closes them he will stop at the new page and look at it. </p>
<p><code>/* example */<br />
&lt;meta http-equiv="REFRESH" content="0;url=http://www.the-domain-you-want-to-redirect-to.com"&gt;<br />
</code></p>
<h3>3. Browser side redirection using Flash</h3>
<p>If you are comfortable working with Flash, then browser side redirection using Flash will be pretty easy for you. To create an instant redirect, you can make your own flash movie with one frame that has a single transparent area in it. Now you need to paste the relevant code into the actionscript pane for that frame. In case you want to redirect after a period of time, you can make a movie of the appropriate length and paste the code into the actionscript pane of the last frame.</p>
<p><code>/* example */<br />
var url:String = "http://www.google.com"<br />
var urlRequest:URLRequest = new URLRequest(url);<br />
navigateToURL(urlRequest, "_blank");<br />
</code> </p>
<h3>4. Server side page redirection using PHP </h3>
<p>This technique can be useful if you want to redirect to a different page depending on the outcome of a script. With the help of this technique and appropriate skills, you can  redirect to a joke page on a Sunday, political news on a Monday, Books review on a Tuesday and so on. However, one thing that you should keep in mind is that you must call the function before any text or HTML is sent to the browser. Redirect will fail with an error message if you call the function after the redirect. </p>
<p><code>/* example */<br />
header("Location: http://domain.com/");<br />
</code> </p>
<h3>5. Hidden Browser side redirection using Iframe and JavaScript </h3>
<p>When it comes to search engine optimization some people are too wary of search engines finding their pages are redirected. If you are one of those then this is a good method for you. All you need to do is to  put an iframe in the page you want to redirect from. After this, in the source attribute of the iframe, put the url of the page you wish to redirect to.</p>
<p>When you do this, the browser loads the new page into the iframe. Then the page is executed in framebreaker and the new page is displayed in place of the one that was originally loading.  Thus you can quickly redirect a page using this Javascript technique </p>
<h3>6. Server side redirection using .htaccess 301 on Unix servers </h3>
<p>Result Code 301 is the only way to redirect to a new page which is properly supported by search engines. It is also known as permanent redirect. With this, Google not only transfers  all the traffic but also any page rank to the new page. The .htaccess files are simple text files that contain instructions for the server on your site. You can either have one such file in every directory where it is needed or a single file in the document root directory for the entire site. In case you already have a .htaccess file in your directory then you can simply add any redirects to the top of the file.</p>
<p><code>/* example */<br />
Options +FollowSymLinks<br />
RewriteEngine on<br />
RewriteRule (.*) http://www.newdomain.com/$1 [R=301,L]<br />
</code> </p>
<h3>7. Page redirection from any point in a PHP script</h3>
<p>The PHP script gives you an option of redirecting your page at any given interval. You may utilize this technique if in case you stumble upon the awkward header which the script may produce sporadically.  </p>
<p><code>/* example */<br />
header("Location: http://domain.com/");<br />
exit;<br />
</code> </p>
<h3>8. Server side redirection using ASP and ASP.net on windows servers</h3>
<p>The only way to redirect to a new page which is properly supported by search engines is Result code 301. And it is known as the permanent redirect. It will make sure that Google transfers not only all the  traffic but also any page rank to the new page. </p>
<p><code>/* example */<br />
/* ASP */<br />
Response.Status="301 Moved Permanently"<br />
Response.AddHeader "Location","http://www.new-url.com/"</p>
<p>/* ASP.NET */</p>
<p>private void Page_Load(object sender, System.EventArgs e)<br />
{<br />
Response.Status = "301 Moved Permanently";<br />
Response.AddHeader("Location","http://www.new-url.com");<br />
}</p>
<p></code></p>
<p>These are some of the good techniques that you can use to redirect your web pages. Make sure that you use the right code.<br />
<h3 class='related_post_title'>If you like this, You&#8217;ll love These.</h3>
<ul class='related_post'>
<li><a href='http://www.andysowards.com/blog/2011/how-to-use-rss-to-display-the-latest-updates-on-your-website-from-other-websites/' title='How To Use RSS To Display The Latest Updates On Your Website From Other Websites '>How To Use RSS To Display The Latest Updates On Your Website From Other Websites </a></li>
<li><a href='http://www.andysowards.com/blog/2008/daily-links-64/' title='AndySowards.com :: Web Development Nerdy Daily Links For 11/20/2008'>AndySowards.com :: Web Development Nerdy Daily Links For 11/20/2008</a></li>
<li><a href='http://www.andysowards.com/blog/2008/daily-links-3/' title='AndySowards.com :: Web Development Nerdy Daily Links'>AndySowards.com :: Web Development Nerdy Daily Links</a></li>
<li><a href='http://www.andysowards.com/blog/2008/daily-links-44/' title='AndySowards.com :: Web Development Nerdy Daily Links For 10/31/2008'>AndySowards.com :: Web Development Nerdy Daily Links For 10/31/2008</a></li>
<li><a href='http://www.andysowards.com/blog/2008/daily-links-26/' title='AndySowards.com :: Web Development Nerdy Daily Links For 10/08/2008'>AndySowards.com :: Web Development Nerdy Daily Links For 10/08/2008</a></li>
<li><a href='http://www.andysowards.com/blog/2009/daily-links-163/' title='Web Development Nerdy Daily Links For 3/10/2009'>Web Development Nerdy Daily Links For 3/10/2009</a></li>
</ul>
<div class="fblike_button" style="margin: 10px 0;"><iframe src="http://www.facebook.com/plugins/like.php?href=http%3A%2F%2Fwww.andysowards.com%2Fblog%2F2011%2Fhow-to-redirect-visitors-to-another-site-or-page-different-techniques-explanations-for-beginners%2F&amp;layout=standard&amp;show_faces=true&amp;width=450&amp;action=like&amp;colorscheme=light" scrolling="no" frameborder="0" allowTransparency="true" style="border:none; overflow:hidden; width:450px; height:25px"></iframe></div>
]]></content:encoded>
			<wfw:commentRss>http://www.andysowards.com/blog/2011/how-to-redirect-visitors-to-another-site-or-page-different-techniques-explanations-for-beginners/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>jQuery 1.3 with PHP &#8211; Free Chapter Download!</title>
		<link>http://www.andysowards.com/blog/2010/jquery-1-3-with-php-free-chapter-download/</link>
		<comments>http://www.andysowards.com/blog/2010/jquery-1-3-with-php-free-chapter-download/#comments</comments>
		<pubDate>Wed, 27 Jan 2010 05:19:28 +0000</pubDate>
		<dc:creator>Andy Sowards</dc:creator>
				<category><![CDATA[freebies]]></category>
		<category><![CDATA[Javascript]]></category>
		<category><![CDATA[jQuery]]></category>
		<category><![CDATA[popular]]></category>
		<category><![CDATA[programming]]></category>
		<category><![CDATA[Reviews]]></category>
		<category><![CDATA[1.3]]></category>
		<category><![CDATA[1.4]]></category>
		<category><![CDATA[book]]></category>
		<category><![CDATA[chapter]]></category>
		<category><![CDATA[download]]></category>
		<category><![CDATA[framework]]></category>
		<category><![CDATA[free]]></category>
		<category><![CDATA[freebie]]></category>
		<category><![CDATA[packt]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[preview]]></category>
		<category><![CDATA[publishing]]></category>
		<category><![CDATA[read]]></category>
		<category><![CDATA[review]]></category>

		<guid isPermaLink="false">http://www.andysowards.com/blog/?p=2546</guid>
		<description><![CDATA[<p><a href='http://rss.buysellads.com/click.php?z=1265932&k=796ff8632dc2a5b0a7fd0971b688b49f&a=2546&c=1903632728' target='_blank' rel='nofollow'>
				<img src='http://rss.buysellads.com/img.php?z=1265932&k=796ff8632dc2a5b0a7fd0971b688b49f&a=2546&c=1903632728' border='0' alt='' /></a></p><p><a href='http://buysellads.com/buy/sitedetails/pubkey/796ff8632dc2a5b0a7fd0971b688b49f/zone/1265932' target='_blank'>Advertise here with BSA</a></p><br />Tweet As some of you know I have recently been read Learning jQuery 1.3 Book from Packt Publishing and will be posting an in depth review of the content from start to finish very soon, so stay tuned! I realize<br /><br /><a href="http://www.andysowards.com/blog/2010/jquery-1-3-with-php-free-chapter-download/"><span class="button">Read More &#187;</span></a>]]></description>
			<content:encoded><![CDATA[<p><a href='http://rss.buysellads.com/click.php?z=1265932&k=796ff8632dc2a5b0a7fd0971b688b49f&a=2546&c=1508241238' target='_blank' rel='nofollow'>
				<img src='http://rss.buysellads.com/img.php?z=1265932&k=796ff8632dc2a5b0a7fd0971b688b49f&a=2546&c=1508241238' border='0' alt='' /></a></p><p><a href='http://buysellads.com/buy/sitedetails/pubkey/796ff8632dc2a5b0a7fd0971b688b49f/zone/1265932' target='_blank'>Advertise here with BSA</a></p><br /><div id="tweetbutton2546" class="tw_button" style=""><a href="http://twitter.com/share?url=http%3A%2F%2Fwww.andysowards.com%2Fblog%2F2010%2Fjquery-1-3-with-php-free-chapter-download%2F&amp;via=andysowards&amp;text=jQuery%201.3%20with%20PHP%20%26%238211%3B%20Free%20Chapter%20Download%21&amp;related=&amp;lang=en&amp;count=horizontal&amp;counturl=http%3A%2F%2Fwww.andysowards.com%2Fblog%2F2010%2Fjquery-1-3-with-php-free-chapter-download%2F" class="twitter-share-button"  style="width:55px;height:22px;background:transparent url('http://www.andysowards.com/blog/wp-content/plugins/wp-tweet-button/tweetn.png') no-repeat  0 0;text-align:left;text-indent:-9999px;display:block;">Tweet</a></div><div class="alignright"><div class="g-plusone" data-href="http://www.andysowards.com/blog/2010/jquery-1-3-with-php-free-chapter-download/" size="tall" count="true"></div></div><div class="fblike_button" style="margin: 10px 0;"><iframe src="http://www.facebook.com/plugins/like.php?href=http%3A%2F%2Fwww.andysowards.com%2Fblog%2F2010%2Fjquery-1-3-with-php-free-chapter-download%2F&amp;layout=standard&amp;show_faces=true&amp;width=450&amp;action=like&amp;colorscheme=light" scrolling="no" frameborder="0" allowTransparency="true" style="border:none; overflow:hidden; width:450px; height:25px"></iframe></div>
<p><a href="http://www.packtpub.com/jquery-1-3-with-php/mid/121109cltpgi?utm_source=andysowards.com&#038;utm_medium=affiliate&#038;utm_content=blog&#038;utm_campaign=mdb_001439"><img src="http://www.andysowards.com/blog/wp-content/uploads/2010/01/jquery-with-php.jpg" alt="P7290071-540-jquery-1.3-book-post" class="aligncenter size-full wp-image-1578" /></a></p>
<p>As some of you know I have recently been read <a href="http://www.packtpub.com/learning-jquery-1.3/mid/240609o1fp7w?utm_source=andysowards.com%2Fblog&#038;utm_medium=affiliate&#038;utm_content=blog&#038;utm_campaign=mdb_000083" target="_blank">Learning jQuery 1.3 Book from Packt Publishing</a> and will be posting an in depth review of the content from start to finish very soon, so stay tuned!</p>
<p>I realize that jQuery 1.4 is already out and the Buzz around it is pretty high &#8211; however, if you are new to jQuery &#8211; You shouldn&#8217;t worry about jumping into the latest and greatest version. You should instead focus on learning the basic concepts of jQuery, and using them correctly, and once you are up to speed, then by all means jump into 1.4. but learning the foundation of jQuery from the ground up will save you a lot of time and frustration!</p>
<p>In the meantime, I have also been reading <a href="http://www.packtpub.com/jquery-1-3-with-php/mid/121109cltpgi?utm_source=andysowards.com&#038;utm_medium=affiliate&#038;utm_content=blog&#038;utm_campaign=mdb_001439" target="_blank">jQuery 1.3 with PHP</a> and will be posting a review to that book as well very soon. If you can&#8217;t wait for the review then check out “Chapter 9: Data Tables” Yourself!! </p>
<p>You can get your hands on the free Chapter 9 download <a href="http://www.packtpub.com/files/6989-php-and-jquery-sample-chapter-9-data-tables.pdf" target="_blank">here</a>.</p>
<p>From what I have read of &#8220;jQuery 1.3 with PHP&#8221; it is an Excellent resource for those who want to go all out and create a very nice web application on your own. This is a great read for those looking to &#8216;tie it all together&#8217; and build a nice web app quickly and easily.</p>
<p>Its definitely <a href="http://www.packtpub.com/jquery-1-3-with-php/mid/121109cltpgi?utm_source=andysowards.com&#038;utm_medium=affiliate&#038;utm_content=blog&#038;utm_campaign=mdb_001439" target="_blank">worth picking up</a> because you can learn a lot of good techniques for more efficient and clean code!</p>
<p>Stay tuned and <a href="http://www.andysowards.com/blog/feed" target="_blank">Subscribe to the feed</a> so that you won&#8217;t miss the awesome FULL review of the book!<br />
<h3 class='related_post_title'>If you like this, You&#8217;ll love These.</h3>
<ul class='related_post'>
<li><a href='http://www.andysowards.com/blog/2008/daily-links-26/' title='AndySowards.com :: Web Development Nerdy Daily Links For 10/08/2008'>AndySowards.com :: Web Development Nerdy Daily Links For 10/08/2008</a></li>
<li><a href='http://www.andysowards.com/blog/2009/how-to-add-flair-to-your-actions-with-jquery-%e2%80%93-part-3-%e2%80%93-javascript-tutorial/' title='How to Add Flair to your Actions with jQuery – Part 3 – Javascript Tutorial'>How to Add Flair to your Actions with jQuery – Part 3 – Javascript Tutorial</a></li>
<li><a href='http://www.andysowards.com/blog/2009/daily-links-145/' title='AndySowards.com :: Web Development Nerdy Daily Links For 2/20/2009'>AndySowards.com :: Web Development Nerdy Daily Links For 2/20/2009</a></li>
<li><a href='http://www.andysowards.com/blog/2008/daily-links-38/' title='AndySowards.com :: Web Development Nerdy Daily Links For 10/23/2008'>AndySowards.com :: Web Development Nerdy Daily Links For 10/23/2008</a></li>
<li><a href='http://www.andysowards.com/blog/2010/links-for-2010-01-13/' title='#WDNDL For 01/14/2010 – Tech News, jQuery Tips, Photoshop Tutorials, &amp; Inspirations!'>#WDNDL For 01/14/2010 – Tech News, jQuery Tips, Photoshop Tutorials, &#038; Inspirations!</a></li>
<li><a href='http://www.andysowards.com/blog/2009/links-for-2009-08-04/' title='#WDNDL For 8/5/2009 – Design Inspiration &amp; Tips, Photoshop Freebies, &amp; jQuery Plugins! '>#WDNDL For 8/5/2009 – Design Inspiration &#038; Tips, Photoshop Freebies, &#038; jQuery Plugins! </a></li>
</ul>
<div class="fblike_button" style="margin: 10px 0;"><iframe src="http://www.facebook.com/plugins/like.php?href=http%3A%2F%2Fwww.andysowards.com%2Fblog%2F2010%2Fjquery-1-3-with-php-free-chapter-download%2F&amp;layout=standard&amp;show_faces=true&amp;width=450&amp;action=like&amp;colorscheme=light" scrolling="no" frameborder="0" allowTransparency="true" style="border:none; overflow:hidden; width:450px; height:25px"></iframe></div>
]]></content:encoded>
			<wfw:commentRss>http://www.andysowards.com/blog/2010/jquery-1-3-with-php-free-chapter-download/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>How to Add Flair to your Actions with jQuery – Part 3 – Javascript Tutorial</title>
		<link>http://www.andysowards.com/blog/2009/how-to-add-flair-to-your-actions-with-jquery-%e2%80%93-part-3-%e2%80%93-javascript-tutorial/</link>
		<comments>http://www.andysowards.com/blog/2009/how-to-add-flair-to-your-actions-with-jquery-%e2%80%93-part-3-%e2%80%93-javascript-tutorial/#comments</comments>
		<pubDate>Thu, 22 Oct 2009 23:02:38 +0000</pubDate>
		<dc:creator>Packt Publishing</dc:creator>
				<category><![CDATA[Javascript]]></category>
		<category><![CDATA[jQuery]]></category>
		<category><![CDATA[popular]]></category>
		<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[1.3]]></category>
		<category><![CDATA[add]]></category>
		<category><![CDATA[adding]]></category>
		<category><![CDATA[article]]></category>
		<category><![CDATA[book]]></category>
		<category><![CDATA[Design]]></category>
		<category><![CDATA[development]]></category>
		<category><![CDATA[elements]]></category>
		<category><![CDATA[flair]]></category>
		<category><![CDATA[flare]]></category>
		<category><![CDATA[java]]></category>
		<category><![CDATA[jquery1.3]]></category>
		<category><![CDATA[js]]></category>
		<category><![CDATA[learning]]></category>
		<category><![CDATA[packt]]></category>
		<category><![CDATA[part]]></category>
		<category><![CDATA[part3]]></category>
		<category><![CDATA[programming]]></category>
		<category><![CDATA[publishing]]></category>
		<category><![CDATA[script]]></category>
		<category><![CDATA[scripts]]></category>
		<category><![CDATA[series]]></category>
		<category><![CDATA[teach]]></category>
		<category><![CDATA[tips]]></category>
		<category><![CDATA[tricks]]></category>
		<category><![CDATA[tutorial]]></category>
		<category><![CDATA[web]]></category>
		<category><![CDATA[with]]></category>
		<category><![CDATA[working]]></category>

		<guid isPermaLink="false">http://www.andysowards.com/blog/?p=2095</guid>
		<description><![CDATA[<p><a href='http://rss.buysellads.com/click.php?z=1265932&k=796ff8632dc2a5b0a7fd0971b688b49f&a=2095&c=2069641908' target='_blank' rel='nofollow'>
				<img src='http://rss.buysellads.com/img.php?z=1265932&k=796ff8632dc2a5b0a7fd0971b688b49f&a=2095&c=2069641908' border='0' alt='' /></a></p><p><a href='http://buysellads.com/buy/sitedetails/pubkey/796ff8632dc2a5b0a7fd0971b688b49f/zone/1265932' target='_blank'>Advertise here with BSA</a></p><br />Tweet Welcome back to part 3 of Adding Flair to your Actions with jQuery! If you missed Part 2, go ahead and read that first, or just move ahead! Simultaneous versus queued effects The .animate() method, as we&#8217;ve just discovered,<br /><br /><a href="http://www.andysowards.com/blog/2009/how-to-add-flair-to-your-actions-with-jquery-%e2%80%93-part-3-%e2%80%93-javascript-tutorial/"><span class="button">Read More &#187;</span></a>]]></description>
			<content:encoded><![CDATA[<p><a href='http://rss.buysellads.com/click.php?z=1265932&k=796ff8632dc2a5b0a7fd0971b688b49f&a=2095&c=143019491' target='_blank' rel='nofollow'>
				<img src='http://rss.buysellads.com/img.php?z=1265932&k=796ff8632dc2a5b0a7fd0971b688b49f&a=2095&c=143019491' border='0' alt='' /></a></p><p><a href='http://buysellads.com/buy/sitedetails/pubkey/796ff8632dc2a5b0a7fd0971b688b49f/zone/1265932' target='_blank'>Advertise here with BSA</a></p><br /><div id="tweetbutton2095" class="tw_button" style=""><a href="http://twitter.com/share?url=http%3A%2F%2Fwww.andysowards.com%2Fblog%2F2009%2Fhow-to-add-flair-to-your-actions-with-jquery-%25e2%2580%2593-part-3-%25e2%2580%2593-javascript-tutorial%2F&amp;via=andysowards&amp;text=How%20to%20Add%20Flair%20to%20your%20Actions%20with%20jQuery%20%E2%80%93%20Part%203%20%E2%80%93%20Javascript%20Tutorial&amp;related=&amp;lang=en&amp;count=horizontal&amp;counturl=http%3A%2F%2Fwww.andysowards.com%2Fblog%2F2009%2Fhow-to-add-flair-to-your-actions-with-jquery-%25e2%2580%2593-part-3-%25e2%2580%2593-javascript-tutorial%2F" class="twitter-share-button"  style="width:55px;height:22px;background:transparent url('http://www.andysowards.com/blog/wp-content/plugins/wp-tweet-button/tweetn.png') no-repeat  0 0;text-align:left;text-indent:-9999px;display:block;">Tweet</a></div><div class="alignright"><div class="g-plusone" data-href="http://www.andysowards.com/blog/2009/how-to-add-flair-to-your-actions-with-jquery-%e2%80%93-part-3-%e2%80%93-javascript-tutorial/" size="tall" count="true"></div></div><div class="fblike_button" style="margin: 10px 0;"><iframe src="http://www.facebook.com/plugins/like.php?href=http%3A%2F%2Fwww.andysowards.com%2Fblog%2F2009%2Fhow-to-add-flair-to-your-actions-with-jquery-%25e2%2580%2593-part-3-%25e2%2580%2593-javascript-tutorial%2F&amp;layout=standard&amp;show_faces=true&amp;width=450&amp;action=like&amp;colorscheme=light" scrolling="no" frameborder="0" allowTransparency="true" style="border:none; overflow:hidden; width:450px; height:25px"></iframe></div>
<p>Welcome back to part 3 of Adding Flair to your Actions with jQuery! If you missed <a href="http://www.andysowards.com/blog/tutorials/how-to-add-flair-to-your-actions-with-jquery-part-2-javascript-tutorial/">Part 2</a>, go ahead and read that first, or just move ahead!</p>
<h2>Simultaneous versus queued effects </h2>
<p>The <i>.animate() </i> method, as we&#8217;ve just discovered, is very useful for creating simultaneous effects in a particular set of elements. There may be times, however, when we want to <b>queue </b> our effects, having them occur one after the other. </p>
<h2>Working with a single set of elements </h2>
<p>When applying multiple effects to the same set of elements, <b>queuing </b> is easily achieved by chaining those effects. To demonstrate this queuing, we&#8217;ll again move the <b>Text Size </b> box to the right, increase its height and increase its border width. This time, however, we perform the three effects sequentially, simply by placing each in its own <i>.animate() </i> method and chaining the three together: </p>
<pre style="margin-left: 20px;">$(document).ready(function() { <br/>  $('div.label').click(function() { <br/>    var paraWidth = $('div.speech p').outerWidth(); <br/>    var $switcher = $(this).parent(); <br/>    var switcherWidth = $switcher.outerWidth(); <br/>    $switcher <br/> <span style="font-weight: bold;">.animate({left: paraWidth - switcherWidth}, </span> <br style="font-weight: bold;"/> <span style="font-weight: bold;">                                            'slow') </span> <br style="font-weight: bold;"/> <span style="font-weight: bold;">      .animate({height: '+=20px'}, 'slow') </span> <br style="font-weight: bold;"/> <span style="font-weight: bold;">      .animate({borderWidth: '5px'}, 'slow'); </span> <br/>  }); <br/>}); <br/> </pre>
<p>Chaining permits us to keep all three <i>.animate() </i> methods on the same line, but here we have indented them and put each on its own line for greater readability. </p>
<p>We can queue any of the jQuery effect methods, not just <i>.animate() </i>, by chaining them. We can, for example, queue effects on in the following order: </p>
<ol>
<li>Fade its opacity to .5 with <i>.fadeTo() </i>. </li>
<li>Move it to the right with <i>.animate() </i>. </li>
<li>Fade it back in to full opacity with <i>.fadeTo() </i>. </li>
<li>Hide it with <i>.slideUp() </i>. </li>
<li>Show it once more with <i>.slideDown() </i>. </li>
</ol>
<p>All we need to do is chain the effects in the same order in our code: </p>
<pre style="margin-left: 20px;">$(document).ready(function() { <br/>    $('div.label').click(function() { <br/>      var paraWidth = $('div.speech p').outerWidth(); <br/>      var $switcher = $(this).parent(); <br/>      var switcherWidth = $switcher.outerWidth(); <br/>      $switcher <br/> <span style="font-weight: bold;">.fadeTo('fast',0.5) </span> <br style="font-weight: bold;"/> <span style="font-weight: bold;">        .animate({ </span> <br style="font-weight: bold;"/> <span style="font-weight: bold;">          'left': paraWidth - switcherWidth </span> <br style="font-weight: bold;"/> <span style="font-weight: bold;">        }, 'slow') </span> <br style="font-weight: bold;"/> <span style="font-weight: bold;">        .fadeTo('slow',1.0) </span> <br style="font-weight: bold;"/> <span style="font-weight: bold;">        .slideUp('slow') </span> <br style="font-weight: bold;"/> <span style="font-weight: bold;">        .slideDown('slow'); </span> <br/>    }); <br/>}); <br/> </pre>
<p>But what if we want to move the to the right at the same time as it fades to half opacity? If the two animations were occurring at the same speed, we could simply combine them into a single <i>.animate() </i> method. But in this example, the fade is using the <i>&#8216;fast&#8217; </i> speed while the move to the right is using the <i>&#8216;slow&#8217; </i> speed. Here is where the second form of the <i>.animate() </i> method comes in handy: </p>
<pre style="margin-left: 20px;">$(document).ready(function() { <br/>    $('div.label').click(function() { <br/>      var paraWidth = $('div.speech p').outerWidth(); <br/>      var $switcher = $(this).parent(); <br/>      var switcherWidth = $switcher.outerWidth(); <br/>      $switcher <br/>        .fadeTo('fast',0.5) <br/> <span style="font-weight: bold;">.animate({ </span> <br style="font-weight: bold;"/> <span style="font-weight: bold;">          'left': paraWidth - switcherWidth </span> <br style="font-weight: bold;"/> <span style="font-weight: bold;">        }, {duration: 'slow', queue: false}) </span> <br/>        .fadeTo('slow',1.0) <br/>        .slideUp('slow') <br/>        .slideDown('slow'); <br/>    }); <br/>}); <br/> </pre>
<p>The second argument, an options map, provides the <i>queue </i> option, which when set to <i>false </i> makes the animation start simultaneously with the previous one. </p>
<p>One final observation about queuing effects on a single set of elements is that queuing does not automatically apply to other, non-effect methods such as <i>.css() </i>. So let&#8217;s suppose we wanted to change the background color of to red after the <i>.slideUp() </i> but before the <i>slideDown() </i>. We could try doing it like this: </p>
<pre style="margin-left: 20px;">$(document).ready(function() { <br/>$('div.label').click(function() { <br/>      var paraWidth = $('div.speech p').outerWidth(); <br/>      var $switcher = $(this).parent(); <br/>      var switcherWidth = $switcher.outerWidth(); <br/>      $switcher <br/>        .fadeTo('fast',0.5) <br/>        .animate({ <br/>          'left' paraWidth - switcherWidth <br/>        }, 'slow') <br/>        .fadeTo('slow',1.0) <br/>        .slideUp('slow') <br/> <span style="font-weight: bold;">.css('backgroundColor','#f00') </span> <br/>        .slideDown('slow'); <br/>      }); <br/>}); <br/> </pre>
<p>However, even though the background-changing code is placed at the correct position in the chain, it occurs immediately upon the click. </p>
<p>One way we can add non-effect methods to the queue is to use the appropriately named <i>.queue() </i> method. Here is what it would look like in our example: </p>
<pre style="margin-left: 20px;">$(document).ready(function() { <br/>    $('div.label').click(function() { <br/>      var paraWidth = $('div.speech p').outerWidth(); <br/>      var $switcher = $(this).parent(); <br/>      var switcherWidth = $switcher.outerWidth(); <br/>      $switcher <br/>        .fadeTo('fast',0.5) <br/>        .animate({ <br/>          'left': paraWidth - switcherWidth <br/>        }, 'slow') <br/>        .fadeTo('slow',1.0) <br/>        .slideUp('slow') <br/> <span style="font-weight: bold;">.queue(function() { </span> <br style="font-weight: bold;"/> <span style="font-weight: bold;">          $switcher </span> <br style="font-weight: bold;"/> <span style="font-weight: bold;">            .css('backgroundColor', '#f00') </span> <br style="font-weight: bold;"/> <span style="font-weight: bold;">            .dequeue(); </span> <br/>        }) <br/>        .slideDown('slow'); <br/>    }); <br/>}); <br/> </pre>
<p>When given a <b>callback function </b>, as it is here, the <i>.queue() </i> method adds the function to the queue of effects for the matched elements. Within the function, we set the background color to red and then add the corollary <i>.dequeue() </i> method. Including this <i>.dequeue() </i> method allows the animation queue to pick up where it left off and complete the chain with the following <i>.slideDown(&#8216;slow&#8217;) </i> line. If we hadn&#8217;t used .dequeue(), the animation would have stopped. </p>
<p style="margin-left: 20px; margin-right: 20px;"> <em>More information and examples for .queue() and .dequeue() are available at <a href="http://docs.jquery.com/Effects" target="_blank">http://docs.jquery.com/Effects </a>. </em> </p>
<p>We&#8217;ll discover another way to queue non-effect methods as we examine effects with multiple sets of elements. </p>
<h2>Working with multiple sets of elements </h2>
<p>Unlike with a single set of elements, when we apply effects to different sets, they occur at virtually the same time. To see these simultaneous effects in action, we&#8217;ll slide one paragraph down while sliding another paragraph up. First, we&#8217;ll add the remaining portion of the Gettysburg Address to the HTML, dividing it into two separate paragraphs: </p>
<pre style="margin-left: 20px;">
<div id="switcher"> <br/>
<div class="label">Text Size </div>

 <br/> <button id="switcher-default">Default </button> <br/> <button id="switcher-large">Bigger </button> <br/> <button id="switcher-small">Smaller </button> <br/> </div>

 <br/>
<div class="speech"> <br/>

Fourscore and seven years ago our fathers brought forth <br/>     on this continent a new nation, conceived in liberty, and <br/>     dedicated to the proposition that all men are created <br/>     equal. <br/> 

 <br/>

Now we are engaged in a great civil war, testing whether <br/>     that nation, or any nation so conceived and so dedicated, <br/>     can long endure. We are met on a great battlefield of <br/>     that war. We have come to dedicate a portion of that <br/>     field as a final resting-place for those who here gave <br/>     their lives that the nation might live. It is altogether <br/>     fitting and proper that we should do this. But, in a <br/>     larger sense, we cannot dedicate, we cannot consecrate, <br/>     we cannot hallow, this ground. <br/> 

 <br/> <a href="#" class="more">read more </a> <br/> <span style="font-weight: bold;">

The brave men, living and dead, who struggled </span> <br style="font-weight: bold;"/> <span style="font-weight: bold;">     here have consecrated it, far above our poor </span> <br style="font-weight: bold;"/> <span style="font-weight: bold;">     power to add or detract. The world will little </span> <br style="font-weight: bold;"/> <span style="font-weight: bold;">     note, nor long remember, what we say here, but it </span> <br style="font-weight: bold;"/> <span style="font-weight: bold;">     can never forget what they did here. It is for us </span> <br style="font-weight: bold;"/> <span style="font-weight: bold;">     the living, rather, to be dedicated here to the </span> <br style="font-weight: bold;"/> <span style="font-weight: bold;">     unfinished work which they who fought here have </span> <br style="font-weight: bold;"/> <span style="font-weight: bold;">     thus far so nobly advanced. </span> <br style="font-weight: bold;"/> <span style="font-weight: bold;"> 

 </span> <br style="font-weight: bold;"/> <span style="font-weight: bold;">

It is rather for us to be here dedicated to the </span> <br style="font-weight: bold;"/> <span style="font-weight: bold;">     great task remaining before us—that from </span> <br style="font-weight: bold;"/> <span style="font-weight: bold;">     these honored dead we take increased devotion to </span> <br style="font-weight: bold;"/> <span style="font-weight: bold;">     that cause for which they gave the last full </span> <br style="font-weight: bold;"/> <span style="font-weight: bold;">     measure of devotion—that we here highly </span> <br style="font-weight: bold;"/> <span style="font-weight: bold;">     resolve that these dead shall not have died in </span> <br style="font-weight: bold;"/> <span style="font-weight: bold;">     vain—that this nation, under God, shall </span> <br style="font-weight: bold;"/> <span style="font-weight: bold;">     have a new birth of freedom and that government </span> <br style="font-weight: bold;"/> <span style="font-weight: bold;">     of the people, by the people, for the people, </span> <br style="font-weight: bold;"/> <span style="font-weight: bold;">     shall not perish from the earth. </span> <br style="font-weight: bold;"/> <span style="font-weight: bold;"> 

 </span> <br/> </div>

 <br/> </pre>
<p>Next, to help us see what&#8217;s happening during the effect, we&#8217;ll give the third paragraph a 1-pixel border and the fourth paragraph a gray background. We&#8217;ll also hide the fourth paragraph when the DOM is ready: </p>
<pre style="margin-left: 20px;">$(document).ready(function() { <br/>  $('p:eq(2)').css('border', '1px solid #333'); <br/>  $('p:eq(3)').css('backgroundColor', '#ccc').hide(); <br/>}); <br/> </pre>
<p>Finally, we&#8217;ll add the <i>.click() </i> method to the third paragraph so that when it is clicked, the third paragraph will slide up (and out of view), while the fourth paragraph slides down (and into view): </p>
<pre style="margin-left: 20px;">$(document).ready(function() { <br/>$('p:eq(2)') <br/>    .css('border', '1px solid #333') <br/> <span style="font-weight: bold;">.click(function() { </span> <br style="font-weight: bold;"/> <span style="font-weight: bold;">      $(this).slideUp('slow') </span> <br style="font-weight: bold;"/> <span style="font-weight: bold;">        .next().slideDown('slow'); </span> <br style="font-weight: bold;"/> <span style="font-weight: bold;">    }); </span> <br/>  $('p:eq(3)').css('backgroundColor', '#ccc').hide(); <br/>}); <br/> </pre>
<p>A screenshot of these two effects in mid-slide confirms that they do, indeed, occur virtually simultaneously: </p>
<p style="text-align: center;"> <img src="http://www.packtpub.com/files/images/jquery_article1_image09.png"/> </p>
<p>The third paragraph, which started visible, is halfway through sliding up at the same time as the fourth paragraph, which started hidden, is halfway through sliding down. </p>
<h2>Callbacks </h2>
<p>In order to allow queuing effects on different elements, jQuery provides a <b>callback function </b> for each effect method. As we have seen with event handlers and with the <i>.queue() </i> method, callbacks are simply functions passed as method arguments. In the case of effects, they appear as the last argument of the method. </p>
<p>If we use a callback to queue the two slide effects, we can have the fourth paragraph slide down before the third paragraph slides up. Let&#8217;s first look at how to set up the <i>.slideDown() </i> method with the callback: </p>
<pre style="margin-left: 20px;">$(document).ready(function() { <br/>  $('p:eq(2)') <br/>    .css('border', '1px solid #333') <br/>    .click(function() { <br/> <span style="font-weight: bold;">$(this).next().slideDown('slow',function() { </span> <br style="font-weight: bold;"/> <span style="font-weight: bold;">        // code here executes after 3rd paragraph's </span> <br style="font-weight: bold;"/> <span style="font-weight: bold;">        // slide down has ended </span> <br style="font-weight: bold;"/> <span style="font-weight: bold;">    }); </span> <br/>  }); <br/>  $('p:eq(3)').css('backgroundColor', '#ccc').hide(); <br/> }); <br/> </pre>
<p>We do need to be careful here, however, about what is actually going to slide up. The context has changed for <i>$(this) </i> because the callback is inside the <i>.slideDown() </i> method. Here, <i>$(this) </i> is no longer the third paragraph, as it was at the point of the <i>.click() </i> method; rather, since the <i>.slideDown() </i> method is attached to <i>$(this).next() </i>, everything within that method now sees <i>$(this) </i> as the next sibling, or the fourth paragraph. Therefore, if we put <i>$(this).slideUp(&#8216;slow&#8217;) </i> inside the callback, we would end up hiding the same paragraph that we had just made visible. </p>
<p>A simple way to keep the reference of <i>$(this) </i> stable is to store it in a variable right away within the <i>.click() </i> method, like <i>var $thirdPara = $(this) </i>. </p>
<p>Now <i>$thirdPara </i> will refer to the third paragraph, both outside and inside the callback. Here is what the code looks like using our new variable: </p>
<pre style="margin-left: 20px;">$(document).ready(function() { <br/> <span style="font-weight: bold;">var $thirdPara = $('p:eq(2)'); </span> <br/>  $thirdPara <br/>    .css('border', '1px solid #333') <br/> <span style="font-weight: bold;">.click(function() { </span> <br/>      $(this).next().slideDown('slow',function() { <br/> <span style="font-weight: bold;">$thirdPara.slideUp('slow'); </span> <br/>      }); <br/>    }); <br/>  $('p:eq(3)').css('backgroundColor', '#ccc').hide(); <br/>}); <br/> </pre>
<p>Using <i>$thirdPara </i> inside the <i>.slideDown() </i> callback relies on the properties of <b>closures </b>. </p>
<p>This time a snapshot halfway through the effects will reveal that both the third and the fourth paragraphs are visible; the fourth has finished sliding down and the third is about to begin sliding up: </p>
<p style="text-align: center;"> <img src="http://www.packtpub.com/files/images/jquery_article1_image10.png"/> </p>
<p>Now that we&#8217;ve discussed callbacks, we can return to the code from earlier in this article in which we queued a background-color change near the end of a series of effects. Instead of using the <i>.queue() </i> method, as we did earlier, we can simply use a callback function: </p>
<pre style="margin-left: 20px;">$(document).ready(function() { <br/>  $('div.label').click(function() { <br/>    var paraWidth = $('div.speech p').outerWidth(); <br/>    var $switcher = $(this).parent(); <br/>    var switcherWidth = $switcher.outerWidth(); <br/>    $switcher <br/>      .fadeTo('slow',0.5) <br/>      .animate({ <br/>        'left': paraWidth - switcherWidth <br/>      }, 'slow') <br/>      .fadeTo('slow',1.0) <br/> <span style="font-weight: bold;">.slideUp('slow', function() { </span> <br style="font-weight: bold;"/> <span style="font-weight: bold;">        $switcher </span> <br style="font-weight: bold;"/> <span style="font-weight: bold;">          .css('backgroundColor', '#f00'); </span> <br/>      }) <br/>      .slideDown('slow'); <br/>  }); <br/>}); <br/> </pre>
<p>Here again, the background color of changes to red after it slides up, and before it slides back down. </p>
<h2>In a nutshell </h2>
<p>With all the variations to consider when applying effects, it can become difficult to remember whether the effects will occur simultaneously or sequentially. A brief outline might help: </p>
<ol>
<li>Effects on a single set of elements are: <br/>&#8211; <i>simultaneous </i> when applied as multiple properties in a single <i>.animate( </i>) method. <br/> &#8212; <i>queued </i> when applied in a chain of methods, unless the queue option is set to <i>false </i>. </li>
<li>Effects on multiple sets of elements are: <br/> &#8212; <i>simultaneous </i> by default <br/> &#8212; <i>queued </i> when applied within the callback of another effect or within the callback of the <i>.queue() </i> method </li>
</ol>
<h1>Summary </h1>
<p>By using effect methods that we have explored in this article, we should now be able to incrementally increase and decrease text size by using either the <i>.css( </i>) or the <i>.animate() </i> method. We should also be able to apply various effects to gradually hide and show page elements in different ways and also to animate elements, simultaneously or sequentially, in a number of ways. </p>
<p> <br/> <br/>  <!-- end part 3 --><br />
<hr size="1" noshade="noshade" color="#ff9933"/> <br/>
<div class="header">Learning jQuery 1.3 </div>
<div style="line-height: 0.4em;">&#160; </div>
<table cellspacing="0" cellpadding="0" width="100%">
<tbody>
<tr>
<td width="99" valign="top"> <a href="http://www.packtpub.com/learning-jquery-1.3/book/mid/240609o1fp7w" target="_blank"> <img height="123" width="99" border="0" src="http://images.packtpub.com/images/100x123/1847196705.png" alt="Learning jQuery 1.3" class="left" title="Learning jQuery 1.3"/> </a> </td>
<td valign="top">
<ul>
<li>Better Interaction Design and Web Development with Simple JavaScript Techniques </li>
<li>An introduction to jQuery that requires minimal programming experience </li>
<li>Detailed solutions to specific client-side problems </li>
<li>For web designers to create interactive elements for their designs </li>
<li>For developers to create the best user interface for their web applications </li>
<li>Packed with great examples, code, and clear explanations </li>
<li>Revised and updated version of the first book to help you learn jQuery </li>
</ul>
<p>&#160;&#160; <a href="http://www.packtpub.com/learning-jquery-1.3/book/mid/240609o1fp7w" target="_blank">http://www.packtpub.com/learning-jquery-1.3/book </a> </td>
</tr>
</tbody>
</table>
<p> <br/><br />
<hr size="1" noshade="noshade" color="#ff9933"/> <br/> <br/><br />
<h3 class='related_post_title'>If you like this, You&#8217;ll love These.</h3>
<ul class='related_post'>
<li><a href='http://www.andysowards.com/blog/2009/links-for-2009-11-19/' title='#WDNDL For 11/20/2009 – More JavaScript and CSS! Tech News &#8211; PLUS Inspiration!'>#WDNDL For 11/20/2009 – More JavaScript and CSS! Tech News &#8211; PLUS Inspiration!</a></li>
<li><a href='http://www.andysowards.com/blog/2009/links-for-2009-10-22/' title='#WDNDL For 10/23/2009 – Halloween Edition! Plus Photoshop &amp; jQuery Tips!'>#WDNDL For 10/23/2009 – Halloween Edition! Plus Photoshop &#038; jQuery Tips!</a></li>
<li><a href='http://www.andysowards.com/blog/2009/links-for-2009-08-04/' title='#WDNDL For 8/5/2009 – Design Inspiration &amp; Tips, Photoshop Freebies, &amp; jQuery Plugins! '>#WDNDL For 8/5/2009 – Design Inspiration &#038; Tips, Photoshop Freebies, &#038; jQuery Plugins! </a></li>
<li><a href='http://www.andysowards.com/blog/2009/daily-links-244/' title='#WDNDL For 6/17/2009 – WordPress, jQuery &amp; Inspiration(3D, WP, etc.)!'>#WDNDL For 6/17/2009 – WordPress, jQuery &#038; Inspiration(3D, WP, etc.)!</a></li>
<li><a href='http://www.andysowards.com/blog/2008/daily-links-38/' title='AndySowards.com :: Web Development Nerdy Daily Links For 10/23/2008'>AndySowards.com :: Web Development Nerdy Daily Links For 10/23/2008</a></li>
<li><a href='http://www.andysowards.com/blog/2010/wdndl-for-4510-%e2%80%93-freelancing-advice-inspirations-freebies-jquery-php-oop-tips/' title='#WDNDL for 4/5/10 – Freelancing Advice, Inspirations, Freebies, jQuery, PHP &amp; OOP Tips! '>#WDNDL for 4/5/10 – Freelancing Advice, Inspirations, Freebies, jQuery, PHP &#038; OOP Tips! </a></li>
</ul>
<div class="fblike_button" style="margin: 10px 0;"><iframe src="http://www.facebook.com/plugins/like.php?href=http%3A%2F%2Fwww.andysowards.com%2Fblog%2F2009%2Fhow-to-add-flair-to-your-actions-with-jquery-%25e2%2580%2593-part-3-%25e2%2580%2593-javascript-tutorial%2F&amp;layout=standard&amp;show_faces=true&amp;width=450&amp;action=like&amp;colorscheme=light" scrolling="no" frameborder="0" allowTransparency="true" style="border:none; overflow:hidden; width:450px; height:25px"></iframe></div>
]]></content:encoded>
			<wfw:commentRss>http://www.andysowards.com/blog/2009/how-to-add-flair-to-your-actions-with-jquery-%e2%80%93-part-3-%e2%80%93-javascript-tutorial/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>How to Add Flair to your Actions with jQuery &#8211; Part 2 &#8211; Javascript Tutorial</title>
		<link>http://www.andysowards.com/blog/2009/how-to-add-flair-to-your-actions-with-jquery-part-2-javascript-tutorial/</link>
		<comments>http://www.andysowards.com/blog/2009/how-to-add-flair-to-your-actions-with-jquery-part-2-javascript-tutorial/#comments</comments>
		<pubDate>Sat, 10 Oct 2009 01:03:43 +0000</pubDate>
		<dc:creator>Packt Publishing</dc:creator>
				<category><![CDATA[Javascript]]></category>
		<category><![CDATA[jQuery]]></category>
		<category><![CDATA[popular]]></category>
		<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[2]]></category>
		<category><![CDATA[add]]></category>
		<category><![CDATA[adding]]></category>
		<category><![CDATA[flair]]></category>
		<category><![CDATA[howto]]></category>
		<category><![CDATA[js]]></category>
		<category><![CDATA[packt]]></category>
		<category><![CDATA[packtpub]]></category>
		<category><![CDATA[packtub]]></category>
		<category><![CDATA[part]]></category>
		<category><![CDATA[part2]]></category>
		<category><![CDATA[tutorial]]></category>

		<guid isPermaLink="false">http://www.andysowards.com/blog/?p=2003</guid>
		<description><![CDATA[<p><a href='http://rss.buysellads.com/click.php?z=1265932&k=796ff8632dc2a5b0a7fd0971b688b49f&a=2003&c=982729838' target='_blank' rel='nofollow'>
				<img src='http://rss.buysellads.com/img.php?z=1265932&k=796ff8632dc2a5b0a7fd0971b688b49f&a=2003&c=982729838' border='0' alt='' /></a></p><p><a href='http://buysellads.com/buy/sitedetails/pubkey/796ff8632dc2a5b0a7fd0971b688b49f/zone/1265932' target='_blank'>Advertise here with BSA</a></p><br />Tweet Welcome back to part 2 of Adding Flair to your Actions with jQuery! If you missed Part 1, go ahead and read that first, or just move ahead! Basic hide and show The basic .hide() and .show() methods, without<br /><br /><a href="http://www.andysowards.com/blog/2009/how-to-add-flair-to-your-actions-with-jquery-part-2-javascript-tutorial/"><span class="button">Read More &#187;</span></a>]]></description>
			<content:encoded><![CDATA[<p><a href='http://rss.buysellads.com/click.php?z=1265932&k=796ff8632dc2a5b0a7fd0971b688b49f&a=2003&c=1986295365' target='_blank' rel='nofollow'>
				<img src='http://rss.buysellads.com/img.php?z=1265932&k=796ff8632dc2a5b0a7fd0971b688b49f&a=2003&c=1986295365' border='0' alt='' /></a></p><p><a href='http://buysellads.com/buy/sitedetails/pubkey/796ff8632dc2a5b0a7fd0971b688b49f/zone/1265932' target='_blank'>Advertise here with BSA</a></p><br /><div id="tweetbutton2003" class="tw_button" style=""><a href="http://twitter.com/share?url=http%3A%2F%2Fwww.andysowards.com%2Fblog%2F2009%2Fhow-to-add-flair-to-your-actions-with-jquery-part-2-javascript-tutorial%2F&amp;via=andysowards&amp;text=How%20to%20Add%20Flair%20to%20your%20Actions%20with%20jQuery%20%26%238211%3B%20Part%202%20%26%238211%3B%20Javascript%20Tutorial&amp;related=&amp;lang=en&amp;count=horizontal&amp;counturl=http%3A%2F%2Fwww.andysowards.com%2Fblog%2F2009%2Fhow-to-add-flair-to-your-actions-with-jquery-part-2-javascript-tutorial%2F" class="twitter-share-button"  style="width:55px;height:22px;background:transparent url('http://www.andysowards.com/blog/wp-content/plugins/wp-tweet-button/tweetn.png') no-repeat  0 0;text-align:left;text-indent:-9999px;display:block;">Tweet</a></div><div class="alignright"><div class="g-plusone" data-href="http://www.andysowards.com/blog/2009/how-to-add-flair-to-your-actions-with-jquery-part-2-javascript-tutorial/" size="tall" count="true"></div></div><div class="fblike_button" style="margin: 10px 0;"><iframe src="http://www.facebook.com/plugins/like.php?href=http%3A%2F%2Fwww.andysowards.com%2Fblog%2F2009%2Fhow-to-add-flair-to-your-actions-with-jquery-part-2-javascript-tutorial%2F&amp;layout=standard&amp;show_faces=true&amp;width=450&amp;action=like&amp;colorscheme=light" scrolling="no" frameborder="0" allowTransparency="true" style="border:none; overflow:hidden; width:450px; height:25px"></iframe></div>
<p>Welcome back to part 2 of Adding Flair to your Actions with jQuery! If you missed <a href="http://www.andysowards.com/blog/tutorials/how-to-add-flair-to-your-actions-with-jquery-part-1-javascript-tutorial/">Part 1</a>, go ahead and read that first, or just move ahead!</p>
<h1>Basic hide and show </h1>
<p>The basic <i>.hide() </i> and <i>.show() </i> methods, without any parameters, can be thought of as smart shorthand methods for <i>.css(&#8216;display&#8217;,'string&#8217;) </i>, where <i>&#8216;string&#8217; </i> is the appropriate display value. The effect, as might be expected, is that the matched set of elements will be immediately hidden or shown, with no animation. </p>
<p>The <i>.hide() </i> method sets the <b>inline style attribute </b> of the matched set of elements to <i>display:none </i>. The smart part here is that it remembers the value of the <i>display </i> property&#8212;typically <i>block </i> or <i>inline </i>&#8212;before it was changed to <i>none </i>. Conversely, the <i>.show() </i> method restores the matched set of elements to whatever visible display property they had before <i>display:none </i> was applied. </p>
<p style="margin-left: 20px; margin-right: 20px;"> <em>For more information about the display property and how its values are visually represented in a web page, visit the Mozilla Developer Center at https://developer.mozilla.org/en/CSS/display/ and view examples at <a href="https://developer.mozilla.org/samples/cssref/display.html" target="_blank">https://developer.mozilla.org/samples/cssref/display.html</a>. </em> </p>
<p>This feature of <i>.show() </i> and <i>.hide() </i> is especially helpful when hiding elements whose default display property is overridden in a stylesheet. For example, the   element has the property <i>display:block </i> by default, but we might want to change it to <i>display:inline </i> for a horizontal menu. Fortunately, using the <i>.show() </i> method on a hidden element such as one of these   tags would not merely reset it to its default <i>display:block </i>, because that would put the   on its own line. Instead, the element is restored to its previous <i>display:inline </i> state, thus preserving the horizontal design. </p>
<p>A quick demonstration of these two methods can be set up by adding a second paragraph and a &#8220;read more&#8221; link after the first paragraph in the example HTML: </p>
<p> <br/>
<pre style="margin-left: 20px;">
<div id="switcher">
<div class="label">Text Size </div>

 <br/> <button id="switcher-default">Default </button> <br/> <button id="switcher-large">Bigger </button> <br/> <button id="switcher-small">Smaller </button> <br/> <br/> </div>
</pre>
<div class="speech"> <br/>
<p>Fourscore and seven years ago our fathers brought forth <br/>     on this continent a new nation, conceived in liberty, <br/>     and dedicated to the proposition that all men are created <br/>     equal. </p>
<p> <br/> </div>
<p> <br/>
<div class="speech"> <br/>
<p>Fourscore and seven years ago our fathers brought forth <br/>     on this continent a new nation, conceived in liberty, <br/>     and dedicated to the proposition that all men are <br/>     created equal. <br/> </p>
<p> <br/>
<p>Now we are engaged in a great civil war, testing whether <br/>     that nation, or any nation so conceived and so dedicated, <br/>     can long endure. We are met on a great battlefield of <br/>     that war. We have come to dedicate a portion of that <br/>     field as a final resting-place for those who here gave <br/>     their lives that the nation might live. It is altogether <br/>     fitting and proper that we should do this. But, in a <br/>     larger sense, we cannot dedicate, we cannot consecrate, <br/>     we cannot hallow, this ground. <br/> </p>
<p> <br/> <span style="font-weight: bold;"> <a href="#" class="more">read more </a> </span> <br/> </div>
<p> <br/>
<p>When the DOM is ready, the second paragraph is hidden: </p>
<pre style="margin-left: 20px;">$(document).ready(function() { <br/>  $('p:eq(1)').hide(); <br/>}); <br/> </pre>
<p>And the speech looks like the following screenshot: </p>
<p style="text-align: center;"> <img src="http://www.packtpub.com/files/images/jquery_article1_image03.png"/> </p>
<p>Then, when the user clicks on <b>read more </b> at the end of the first paragraph, that link is hidden and the second paragraph is shown: </p>
<pre style="margin-left: 20px;">$(document).ready(function() { <br/>  $('p:eq(1)').hide(); <br/> <span style="font-weight: bold;">$('a.more').click(function() { </span> <br style="font-weight: bold;"/> <span style="font-weight: bold;">    $('p:eq(1)').show(); </span> <br style="font-weight: bold;"/> <span style="font-weight: bold;">    $(this).hide(); </span> <br style="font-weight: bold;"/> <span style="font-weight: bold;">    return false; </span> <br style="font-weight: bold;"/> <span style="font-weight: bold;">  }); </span> <br/>}); <br/> </pre>
<p>Note the use of return false to keep the link from activating its default action. Now the speech looks like this: </p>
<p style="text-align: center;"> <img src="http://www.packtpub.com/files/images/jquery_article1_image04.png"/> </p>
<p>The <i>.hide() </i> and <i>.show() </i> methods are quick and useful, but they aren&#8217;t very flashy. To add some flair, we can give them a speed. </p>
<h2>Effects and speed </h2>
<p>When we include a <b>speed </b> (or, more precisely, a <b>duration </b>) with <i>.show() </i> or <i>.hide() </i>, it becomes animated&#8212;occurring over a specified period of time. The <i>.hide(&#8216;speed&#8217;) </i> method, for example, decreases an element&#8217;s height, width, and opacity simultaneously until all three reach zero, at which point the CSS rule <i>display:none </i> is applied. The <i>.show(&#8216;speed&#8217;) </i> method will increase the element&#8217;s height from top to bottom, width from left to right, and opacity from 0 to 1 until its contents are completely visible. </p>
<h2>Speeding in </h2>
<p>With any jQuery effect, we can use one of three preset speeds: <i>&#8216;slow&#8217; </i>, <i>&#8216;normal&#8217; </i>, and <i>&#8216;fast&#8217; </i>. Using <i>.show(&#8216;slow&#8217;) </i> makes the show effect complete in .6 seconds, <i>.show(&#8216;normal&#8217;) </i> in .4 seconds, and <i>.show(&#8216;fast&#8217;) </i> in .2 seconds. For even greater precision we can specify a number of milliseconds, for example <i>.show(850) </i>. Unlike the speed names, the numbers are not wrapped in quotation marks. </p>
<p>Let&#8217;s include a speed in our example when showing the second paragraph of Lincoln&#8217;s <b>Gettysburg Address </b>: </p>
<pre style="margin-left: 20px;">$(document).ready(function() { <br/>  $('p:eq(1)').hide(); <br/>  $('a.more').click(function() { <br/> <span style="font-weight: bold;">$('p:eq(1)').show('slow'); </span> <br/>    $(this).hide(); <br/>    return false; <br/>  }); <br/>}); <br/> </pre>
<p>When we capture the paragraph&#8217;s appearance at roughly halfway through the effect, we see something like the following: </p>
<p style="text-align: center;"> <img src="http://www.packtpub.com/files/images/jquery_article1_image05.png"/> </p>
<h2>Fading in and fading out </h2>
<p>While the animated <i>.show() </i> and <i>.hide() </i> methods are certainly flashy, they may at times be too much of a good thing. Fortunately, jQuery offers a couple other pre-built animations for a more subtle effect. For example, to have the whole paragraph appear just by gradually increasing the opacity, we can use <i>.fadeIn(&#8216;slow&#8217;) </i> instead: </p>
<pre style="margin-left: 20px;">$(document).ready(function() { <br/>  $('p:eq(1)').hide(); <br/>  $('a.more').click(function() { <br/> <span style="font-weight: bold;">$('p:eq(1)').fadeIn('slow'); </span> <br/>    $(this).hide(); <br/>    return false; <br/>  }); <br/>}); <br/> </pre>
<p>This time when we capture the paragraph&#8217;s appearance halfway, it&#8217;s seen as: </p>
<p style="text-align: center;"> <img src="http://www.packtpub.com/files/images/jquery_article1_image06.png"/> </p>
<p>The difference here is that the <i>.fadeIn() </i> effect starts by setting the dimensions of the paragraph so that the contents can simply fade into it. To gradually decrease the opacity we can use <i>.fadeOut() </i>. </p>
<hr size="1" noshade="noshade" color="#ff9933"/> <br/>
<div class="header">Learning jQuery 1.3 </div>
<div style="line-height: 0.4em;">&#160; </div>
<table cellspacing="0" cellpadding="0" width="100%">
<tbody>
<tr>
<td width="99" valign="top"> <a href="http://www.packtpub.com/learning-jquery-1.3/book/mid/240609o1fp7w" target="_blank"> <img height="123" width="99" border="0" src="http://images.packtpub.com/images/100x123/1847196705.png" alt="Learning jQuery 1.3" class="left" title="Learning jQuery 1.3"/> </a> </td>
<td valign="top">
<ul>
<li>Better Interaction Design and Web Development with Simple JavaScript Techniques </li>
<li>An introduction to jQuery that requires minimal programming experience </li>
<li>Detailed solutions to specific client-side problems </li>
<li>For web designers to create interactive elements for their designs </li>
<li>For developers to create the best user interface for their web applications </li>
<li>Packed with great examples, code, and clear explanations </li>
<li>Revised and updated version of the first book to help you learn jQuery </li>
</ul>
<p>&#160;&#160; <a href="http://www.packtpub.com/learning-jquery-1.3/book/mid/240609o1fp7w" target="_blank">http://www.packtpub.com/learning-jquery-1.3/book </a> </td>
</tr>
</tbody>
</table>
<p> <br/><br />
<hr size="1" noshade="noshade" color="#ff9933"/> <br/> <br/><br />
<h1>Compound effects </h1>
<p>Sometimes we have a need to toggle the visibility of elements, rather than displaying them once as we did in the previous example. Toggling can be achieved by first checking the visibility of the matched elements and then attaching the appropriate method. Using the fade effects again, we can modify the example script to look like this: </p>
<pre style="margin-left: 20px;">$(document).ready(function() { <br/>  var $firstPara = $('p:eq(1)'); <br/>  $firstPara.hide(); <br/>  $('a.more').click(function() { <br/>    if ($firstPara.is(':hidden')) { <br/>      $firstPara.fadeIn('slow'); <br/>      $(this).text('read less'); <br/>    } else { <br/>      $firstPara.fadeOut('slow'); <br/>      $(this).text('read more'); <br/>    } <br/>    return false; <br/>  }); <br/>}); <br/> </pre>
<p>As we did earlier in the article, we&#8217;re <b>caching </b> our selector here to avoid repeated DOM traversal. Notice, too, that we&#8217;re no longer hiding the clicked link; instead, we&#8217;re changing the its text. </p>
<p>Using an <i>if else </i> statement is a perfectly reasonable way to toggle elements&#8217; visibility. But with jQuery&#8217;s <b>compound effects </b> we can leave the conditionals out of it (although, in this example, we still need one for the link text). jQuery provides a <i>.toggle() </i>method, which acts like <i>.show() </i> and <i>.hide() </i>, and like them, can be used with a speed argument or without. The other compound method is <i>.slideToggle() </i>, which shows or hides elements by gradually increasing or decreasing their height. Here is what the script looks like when we use the <i>.slideToggle() </i> method: </p>
<pre style="margin-left: 20px;">$(document).ready(function() { <br/>var $firstPara = $('p:eq(1)'); <br/>  $firstPara.hide(); <br/>  $('a.more').click(function() { <br/> <span style="font-weight: bold;">$firstPara.slideToggle('slow'); </span> <br style="font-weight: bold;"/> <span style="font-weight: bold;">    var $link = $(this); </span> <br style="font-weight: bold;"/> <span style="font-weight: bold;">    if ( $link.text() == "read more" ) { </span> <br style="font-weight: bold;"/> <span style="font-weight: bold;">      $link.text('read less'); </span> <br style="font-weight: bold;"/> <span style="font-weight: bold;">    } else { </span> <br style="font-weight: bold;"/> <span style="font-weight: bold;">      $link.text('read more'); </span> <br style="font-weight: bold;"/> <span style="font-weight: bold;">    } </span> <br/>    return false; <br/>  }); <br/>}); <br/> </pre>
<p>This time <i>$(this) </i> would have been repeated, so we&#8217;re storing it in the $link variable for performance and readability. Also, the conditional statement checks for the text of the link rather than the visibility of the second paragraph, since we&#8217;re only using it to change the text. </p>
<h1>Creating custom animations </h1>
<p>In addition to the pre-built effect methods, jQuery provides a powerful <i>.animate() </i> method that allows us to create our own <b>custom animations </b> with fine-grained control. The <i>.animate() </i> method comes in two forms. The first takes up to four arguments: </p>
<ol>
<li>A <b>map </b> of style properties and values&#8212;similar to the <i>.css() </i> map discussed earlier in this article </li>
<li>An optional <b>speed </b>&#8212;which can be one of the preset strings or a number of milliseconds </li>
<li>An optional <b>easing type </b>&#8212;an advanced option </li>
<li>An optional callback function&#8212;which will be discussed later in this article </li>
</ol>
<p>All together, the four arguments look like this: </p>
<pre style="margin-left: 20px;">.animate({property1: 'value1', property2: 'value2'}, <br/>  speed, easing, function() { <br/>    alert('The animation is finished.'); <br/>  } <br/>); <br/> </pre>
<p>The second form takes two arguments, a <strong>map </strong> of properties and a map of options. </p>
<pre style="margin-left: 20px;">.animate({properties}, {options}) <br/> </pre>
<p>In effect, the second argument wraps up the second through fourth arguments of the first form into another map, and adds two more options to the mix. When we adjust the line breaks for readability, the second form looks like this: </p>
<pre style="margin-left: 20px;">.animate({ <br/>  property1: 'value1', <br/>  property2: 'value2' <br/>}, { <br/>  duration: 'value', <br/>  easing: 'value', <br/>  complete: function() { <br/>    alert('The animation is finished.'); <br/>  }, <br/>  queue: boolean, <br/>  step: callback <br/>}); <br/> </pre>
<p>For now we&#8217;ll use the first form of the <i>.animate() </i> method, but we&#8217;ll return to the second form later in the article when we discuss queuing effects. </p>
<h2>Toggling the fade </h2>
<p>When we discussed compound effects, did you notice that not all methods have a corresponding method for toggling? That&#8217;s right: while the sliding methods include <i>.slideToggle() </i>, there is no corresponding <i>.fadeToggle() </i> to go along with <i>.fadeIn() </i> and <i>.fadeOut() </i>! The good news is that we can use the <i>.animate() </i> method to easily make our own toggling fade animation. Here we&#8217;ll replace the <i>.slideToggle() </i> line of the previous example with our custom animation: </p>
<pre style="margin-left: 20px;">$(document).ready(function() { <br/>  $('p:eq(1)').hide(); <br/>  $('a.more').click(function() { <br/> <span style="font-weight: bold;"> $('p:eq(1)').animate({opacity: 'toggle'}, 'slow'); </span> <br/>    var $link = $(this); <br/>    if ( $link.text() == "read more" ) { <br/>      $link.text('read less'); <br/>    } else { <br/>      $link.text('read more'); <br/>    } <br/>    return false; <br/>  }); <br/>}); <br/> </pre>
<p>As the example illustrates, the <i>.animate() </i> method provides convenient shorthand values for CSS properties &#8212; <i>&#8216;show&#8217; </i>, <i>&#8216;hide&#8217; </i>, and <i>&#8216;toggle&#8217; </i> &#8212; to ease the way when the shorthand <em>methods </em> aren&#8217;t quite right for the particular task. </p>
<h2>Animating multiple properties </h2>
<p>With the <i>.animate() </i> method, we can modify any combination of properties simultaneously. For example, to create a simultaneous sliding and fading effect when toggling the second paragraph, we simply add the <i>height </i> property-value pair to <i>.animate() </i>&#8216;s properties map: </p>
<pre style="margin-left: 20px;">$(document).ready(function() { <br/>  $('p:eq(1)').hide(); <br/>  $('a.more').click(function() { <br/> <span style="font-weight: bold;">$('p:eq(1)').animate({ </span> <br style="font-weight: bold;"/> <span style="font-weight: bold;">      opacity: 'toggle', </span> <br style="font-weight: bold;"/> <span style="font-weight: bold;">      height: 'toggle' </span> <br style="font-weight: bold;"/> <span style="font-weight: bold;">    }, </span> <br style="font-weight: bold;"/> <span style="font-weight: bold;">    'slow'); </span> <br/>    var $link = $(this); <br/>    if ( $link.text() == "read more" ) { <br/>      $link.text('read less'); <br/>    } else { <br/>      $link.text('read more'); <br/>    } <br/>    return false; <br/>  }); <br/>}); <br/> </pre>
<p>Additionally, we have not only the style properties used for the shorthand effect methods at our disposal, but also other properties such as: <i>left </i>, <i>top </i>, <i>fontSize </i>, <i>margin </i>, <i>padding </i>, and <i>borderWidth </i>. Recall the script to change the text size of the speech paragraphs. We can animate the increase or decrease in size by simply substituting the <i>.animate() </i> method for the <i>.css() </i> method: </p>
<pre style="margin-left: 20px;">$(document).ready(function() { <br/>  var $speech = $('div.speech'); <br/>  var defaultSize = $speech.css('fontSize'); <br/>  $('#switcher button').click(function() { <br/>    var num = parseFloat( $speech.css('fontSize'), 10 ); <br/>    switch (this.id) { <br/>      case 'switcher-large': <br/>        num *= 1.4; <br/>        break; <br/>      case 'switcher-small': <br/>        num /= 1.4; <br/>        break; <br/>      default: <br/>        num = parseFloat(defaultSize, 10); <br/>    } <br/>    $speech.animate({fontSize: num + 'px'}, <br/>                                    'slow'); <br/>  }); <br/>}); <br/> </pre>
<p>The extra properties allow us to create much more complex effects, too. We can, for example, move an item from the left side of the page to the right while increasing its height by 20 pixels and changing its border width to 5 pixels. </p>
<p>So, let&#8217;s do that with the   box. Here is what it looks like before we animate it: </p>
<p style="text-align: center;"> <img src="http://www.packtpub.com/files/images/jquery_article1_image07.png"/> </p>
<p>With a flexible-width layout, we need to compute the distance that the box needs to travel before it lines up at the right side of the page. Assuming that the paragraph&#8217;s width is 100%, we can subtract the <b>Text Size </b> box&#8217;s width from the paragraph&#8217;s width. While jQuery&#8217;s <i>.width() </i> method would usually come in handy for such calculations, it doesn&#8217;t factor in the width of the right and left padding or the right and left border. As of jQuery version 1.2.6, though we also have the <i>.outerWidth() </i> method at our disposal. This is what we&#8217;ll use here, to avoid having to add padding and border widths as well. For the sake of this example, we&#8217;ll trigger the animation by clicking the <b>Text Size </b> label, just above the buttons. Here is what the code should look like: </p>
<pre style="margin-left: 20px;">$(document).ready(function() { <br/>  $('div.label').click(function() { <br/>    var paraWidth = $('div.speech p').outerWidth(); <br/>    var $switcher = $(this).parent(); <br/>    var switcherWidth = $switcher.outerWidth(); <br/>    $switcher.animate({left: paraWidth - switcherWidth, <br/>             height: '+=20px', borderWidth: '5px'}, 'slow'); <br/>  }); <br/>}); <br/> </pre>
<p>Note that the <i>height </i> property has <i>+= </i> before the pixel value. This expression, introduced in jQuery 1.2, indicates a <b>relative value </b>. So, instead of animating the height to 20 pixels, the height is animated to 20 pixels greater than the current height. </p>
<p>Although this code successfully increases the height of the  and widens its border, at the moment the <i>left </i> position cannot be changed. We still need to enable changing its position in the CSS. </p>
<h3>Positioning with CSS </h3>
<p>When working with <i>.animate() </i>, it&#8217;s important to keep in mind the limitations that CSS imposes on the elements that we wish to change. For example, adjusting the <i>left </i> property will have no effect on the matching elements unless those elements have their CSS position set to <i>relative </i> or <i>absolute </i>. The default CSS position for all block-level elements is static, which accurately describes how those elements will remain if we try to move them without first changing their <i>position </i> value. </p>
<p style="margin-left: 20px; margin-right: 20px;"> <em>For more information on absolute and relative positioning, see Joe Gillespie&#8217;s article, Absolutely Relative at: <a href="http://www.wpdfd.com/issues/78/absolutely_relative/" target="_blank">http://www.wpdfd.com/issues/78/absolutely_relative/ </a> </em> </p>
<p>A peek at our stylesheet shows that we have now set  to be relatively positioned: </p>
<pre style="margin-left: 20px;"> #switcher { <br/>  position: relative; <br/>} <br/> </pre>
<p>With the CSS taken into account, the result of clicking on Text Size, when the animation has completed, will look like this: </p>
<p style="text-align: center;"> <img src="http://www.packtpub.com/files/images/jquery_article1_image08.png"/> </p>
<hr size="1" noshade="noshade" color="#ff9933"/> <br/>
<div class="header">Learning jQuery 1.3 </div>
<div style="line-height: 0.4em;">&#160; </div>
<table cellspacing="0" cellpadding="0" width="100%">
<tbody>
<tr>
<td width="99" valign="top"> <a href="http://www.packtpub.com/learning-jquery-1.3/book/mid/240609o1fp7w" target="_blank"> <img height="123" width="99" border="0" src="http://images.packtpub.com/images/100x123/1847196705.png" alt="Learning jQuery 1.3" class="left" title="Learning jQuery 1.3"/> </a> </td>
<td valign="top">
<ul>
<li>Better Interaction Design and Web Development with Simple JavaScript Techniques </li>
<li>An introduction to jQuery that requires minimal programming experience </li>
<li>Detailed solutions to specific client-side problems </li>
<li>For web designers to create interactive elements for their designs </li>
<li>For developers to create the best user interface for their web applications </li>
<li>Packed with great examples, code, and clear explanations </li>
<li>Revised and updated version of the first book to help you learn jQuery </li>
</ul>
<p>&#160;&#160; <a href="http://www.packtpub.com/learning-jquery-1.3/book/mid/240609o1fp7w" target="_blank">http://www.packtpub.com/learning-jquery-1.3/book </a> </td>
</tr>
</tbody>
</table>
<p> <br/><br />
<hr size="1" noshade="noshade" color="#ff9933"/> <br/> <br/>   <!-- END PART 2 --></p>
<p>If you feel confident in what you just read, then go ahead and move on to <a href="http://www.andysowards.com/blog/tutorials/how-to-add-flair-to-your-actions-with-jquery-%e2%80%93-part-3-%e2%80%93-javascript-tutorial/">Part 3</a>! Of course, it always helps to read things a second or third time first, just to let it sink in. Good luck! I hope you are learning some cool tricks!<br />
<h3 class='related_post_title'>If you like this, You&#8217;ll love These.</h3>
<ul class='related_post'>
<li><a href='http://www.andysowards.com/blog/2009/how-to-add-flair-to-your-actions-with-jquery-%e2%80%93-part-3-%e2%80%93-javascript-tutorial/' title='How to Add Flair to your Actions with jQuery – Part 3 – Javascript Tutorial'>How to Add Flair to your Actions with jQuery – Part 3 – Javascript Tutorial</a></li>
<li><a href='http://www.andysowards.com/blog/2011/how-to-redirect-visitors-to-another-site-or-page-different-techniques-explanations-for-beginners/' title='How To Redirect Visitors To Another Site Or Page &#8211; Different Techniques &amp; Explanations for Beginners'>How To Redirect Visitors To Another Site Or Page &#8211; Different Techniques &#038; Explanations for Beginners</a></li>
<li><a href='http://www.andysowards.com/blog/2011/how-to-use-rss-to-display-the-latest-updates-on-your-website-from-other-websites/' title='How To Use RSS To Display The Latest Updates On Your Website From Other Websites '>How To Use RSS To Display The Latest Updates On Your Website From Other Websites </a></li>
<li><a href='http://www.andysowards.com/blog/2010/wdndl-for-2262010-%e2%80%93-inspiration-user-interface-logos-cssjqueryajax-tutorials-geek-news/' title='#WDNDL For 2/26/2010 – Inspiration, User Interface, Logos, CSS/jQuery/AJAX Tutorials &amp; Geek News!'>#WDNDL For 2/26/2010 – Inspiration, User Interface, Logos, CSS/jQuery/AJAX Tutorials &#038; Geek News!</a></li>
<li><a href='http://www.andysowards.com/blog/2010/wdndl-for-2222010-%e2%80%93-freelancer-blogging-tips-jquery-stuff-plus-wp-theme-template-freebies/' title='#WDNDL For 2/22/2010 – Freelancer &amp; Blogging Tips, jQuery Stuff, Plus WP Theme &amp; Template Freebies!'>#WDNDL For 2/22/2010 – Freelancer &#038; Blogging Tips, jQuery Stuff, Plus WP Theme &#038; Template Freebies!</a></li>
<li><a href='http://www.andysowards.com/blog/2010/links-for-2010-02-02/' title='#WDNDL For 2/3/2010 – JS, CSS3, &amp; Photoshop Tutorials, Inspirations, &amp; Tech News!'>#WDNDL For 2/3/2010 – JS, CSS3, &#038; Photoshop Tutorials, Inspirations, &#038; Tech News!</a></li>
</ul>
<div class="fblike_button" style="margin: 10px 0;"><iframe src="http://www.facebook.com/plugins/like.php?href=http%3A%2F%2Fwww.andysowards.com%2Fblog%2F2009%2Fhow-to-add-flair-to-your-actions-with-jquery-part-2-javascript-tutorial%2F&amp;layout=standard&amp;show_faces=true&amp;width=450&amp;action=like&amp;colorscheme=light" scrolling="no" frameborder="0" allowTransparency="true" style="border:none; overflow:hidden; width:450px; height:25px"></iframe></div>
]]></content:encoded>
			<wfw:commentRss>http://www.andysowards.com/blog/2009/how-to-add-flair-to-your-actions-with-jquery-part-2-javascript-tutorial/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>

<!-- Performance optimized by W3 Total Cache. Learn more: http://www.w3-edge.com/wordpress-plugins/

Minified using disk: basic
Page Caching using disk: enhanced
Database Caching 1/16 queries in 0.008 seconds using disk: basic
Object Caching 1677/1722 objects using disk: basic

Served from: www.andysowards.com @ 2012-02-09 18:47:40 -->
