<?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>Dennis Plucinik&#039;s Web Design Blog</title>
	<atom:link href="http://www.dennisplucinik.com/blog/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.dennisplucinik.com/blog</link>
	<description>Just another WordPress site</description>
	<lastBuildDate>Fri, 17 Feb 2012 02:35:41 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>Learning Web Design: Basic CSS</title>
		<link>http://www.dennisplucinik.com/blog/2012/02/13/learning-web-design-basic-css/</link>
		<comments>http://www.dennisplucinik.com/blog/2012/02/13/learning-web-design-basic-css/#comments</comments>
		<pubDate>Tue, 14 Feb 2012 01:57:47 +0000</pubDate>
		<dc:creator>Dennis Plucinik</dc:creator>
				<category><![CDATA[Coding]]></category>
		<category><![CDATA[CSS]]></category>
		<category><![CDATA[Learning Web Design Series]]></category>

		<guid isPermaLink="false">http://www.dennisplucinik.com/blog/?p=1088</guid>
		<description><![CDATA[CSS is the modern way to add style to an HTML web page. There are only a few fundamental concepts you need to grasp before getting started with CSS. In order of importance: How to connect CSS to HTML elements &#8230; <a href="http://www.dennisplucinik.com/blog/2012/02/13/learning-web-design-basic-css/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>CSS is the modern way to add style to an HTML web page. There are only a few fundamental concepts you need to grasp before getting started with CSS. In order of importance: </p>
<ol>
<li>How to connect CSS to HTML elements</li>
<li>Specificity (order of importance)</li>
<li>The box model</li>
</ol>
<p><span id="more-1088"></span></p>
<h2 name="connectCSStoHTML">How to connect CSS to HTML elements</h2>
<p>There are three ways to match a CSS rule to an HTML element. They are by tag, class, or id. Here is an example of each.</p>
<pre><code class="prettyprint lang-html linenums">&lt;div&gt;this text will be blue&lt;/div&gt;
&lt;div class="mySpecialClass"&gt;this text will be green&lt;/div&gt;
&lt;div id="myUniqueId"&gt;this class will be red&lt;/div&gt;
</code>

<code class="prettyprint linenums lang-css">&lt;style&gt;
/* tag selector */
div {
  color: blue;
}

/* class selector */
div.mySpecialClass {
  color: green;
}

/* id selector */
div<em style="display: none;">\</em>#myUniqueId {
  color: red;
}
&lt;/style&gt;
</code>
</pre>
<p class="preCaption">Using a tag, class, and id selector</p>
<p>The major point here is how you identify elements in CSS. A rule defined for "div" will apply that style to <em>all</em> divs. A rule defined with "." (period) will apply that rule to all HTML elements that include that value in their class attribute. The same is for "#" (pound) which applys to HTML elements with the corresponding id attribute.</p>
<p>One important thing to remember is id's are unique identifiers and so there can only be one per page. You may however, use the same class multiple times per page. Elements can also have multiple classes per element (e.g., &lt;div class="first orange grid"&gt;>).</p>
<h3>Chaining</h3>
<p>A powerful feature of CSS is the ability to chain multiple selectors together. By doing this you can match different elements based on their hierarchical order in the HTML. For example, check out the following rules and how they are applied.</p>
<pre><code class="prettyprint lang-css linenums"><span title="applies to all divs that are children of a div">div div { color: red; }</span>
<span title="applies to all elements with a class value of 'someClass' that are also children of a div">div .someClass { color: red; }</span>
<span title="applies to a div with the id 'someID'">div<em style="display: none;">\</em>#someID {color: red; }</span>
</code>
</pre>
<p class="preCaption">Showing simple parent / child relationships</p>
<p><em>NOTICE the space between the selectors</em>. This indicates that the latter selector is a child of the former. NOT including a space indicates that the selectors apply to the same element. For example, the following example shows a CSS rule that matches the given HTML snippet using a tag, class, AND id selector.</p>
<pre><code class="prettyprint lang-html linenums">&lt;div id="myOneAndOnly" class="headline"&gt;Hold me&lt;/div&gt;
</code>

<code class="prettyprint lang-css linenums">
div<em style="display: none;">\</em>#myOneAndOnly.headline {
  color: red;
}
</code>
</pre>
<p class="preCaption">Chaining a tag, id, and class selector</p>
<h2 name="specificity">Specificity</h2>
<p>Now that you know how ids and classes work, you'll need to understand how the browser determines which rules are more important than others. This level of importance given to each selector is called "specificity". By "specificity" we mean literally "how specifically a CSS rule can target HTML elements." The easiest way to think about this is to consider how many elements a single selector will effect.</p>
<ul>
<li>a <strong>tag</strong> selector will target <strong>every single tag</strong> (a LOT of elements)</li>
<li>a <strong>class</strong> selector will target <strong>only a subset of tags</strong> (quite a few less)</li>
<li>an <strong>id</strong> selector will only target <strong>one element per page</strong> (exactly one)</li>
</ul>
<p>Let's start with the basic premise that that the lowest level of specificity is order of appearance. This means if we have multiple rules for the same element, only the last one will be applied.</p>
<pre><code class="prettyprint lang-html linenums">&lt;body&gt;
&lt;div class="things_I_love" id="NewYork" &gt;This text will be red&lt;/div&gt;
&lt;/body&gt;
</code>

<code class="prettyprint lang-css linenums">div { color: green; }
div { color: black; }
div { color: red; } /* <-- this rule wins because it's last */
</code>
</pre>
<p class="preCaption">Lowest specificity: order of appearance</p>
<p>Next up the specificity ladder are tags, then classes, then ids in order of increasing specificity. This means, if we take the previous example, and we want to make the text green, we just need to increase the specificity of that rule. We can do this by adding more selectors or by using a different selector with higher specificity.</p>
<pre><code class="prettyprint lang-html linenums">&lt;body&gt;
&lt;div class="things_I_love" id="NewYork"&gt;This text will be green&lt;/div&gt;
&lt;/body&gt;
</code>

<code class="prettyprint lang-css linenums">body div { color: green; } /* <-- this rule wins */
div { color: black; }
div { color: red; }
</code>
</pre>
<p class="preCaption">Level 1 specificity = tag selectors</p>
<h3>Calculating specificity</h3>
<p>Another way to quickly figure out how your CSS is going to get parsed is to calculate a specificity score. Following the math in this graphic should cover you for about 99% of the time. Basically what we're doing is applying an order of magnitude multiplier to each of the three selectors. This is because for each of the three tiers: tag, class, &#038; id, even using one selector from a higher tier will trump any number of lower tier selectors. For example, you could have 50 class selectors trying to set your text color to red, but if another rule uses even one id selector to set the color to blue, blue will win.</p>
<div id="attachment_1125" class="wp-caption aligncenter" style="width: 625px"><a href="http://www.dennisplucinik.com/blog/wp-content/uploads/2012/02/specificity.gif"><img src="http://www.dennisplucinik.com/blog/wp-content/uploads/2012/02/specificity.gif" alt="CSS Specificity Calculation Diagram / Infographic" title="CSS Specificity Calculation Diagram / Infographic" width="615" height="1806" class="size-full wp-image-1125" style="border: 5px solid #ccc; box-shadow: 0 1px 6px #555;" /></a><p class="wp-caption-text">CSS Specificity Calculation Diagram</p></div>
<h3>More resources explaining specificity</h3>
<p>If you're still stumped, here are some other resources to try and explain this concept differently (one example uses Star Wars characters to explain the ranking!). Also, you'll find that I drew a lot of inspiration from these posts, especially the one from css-tricks. My diagram is essentially a simplified version of theirs.</p>
<ul>
<li><a href="http://css-tricks.com/specifics-on-css-specificity/">Specifics on CSS Specificity</a></li>
<li><a href="http://coding.smashingmagazine.com/2007/07/27/css-specificity-things-you-should-know/">CSS Specificity: Things You Should Know</a></li>
<li><a href="http://net.tutsplus.com/tutorials/html-css-techniques/quick-tip-understanding-css-specificity/">Quick Tip: Understanding CSS Specificity</a></li>
<li><a href="http://www.w3.org/TR/css3-selectors/#specificity">Calculating a selector's specificity (W3C)</a></li>
</ul>
<h2 name="boxModel">The Box Model</h2>
<p>This diagram illustrates the relationship between the primary CSS properties of all HTML elements. It is important to understand this model since you will regularly need to calculate how much total space your elements can take up on the page. For instance, in the element illustrated below if the width was set to 300px, and padding, border, and width were all each 10px, the total width taken up by the element would be 360px (300 + (10 * 2) + (10 * 2) + (10 * 2)).</p>
<div id="attachment_1159" class="wp-caption aligncenter" style="width: 625px"><a href="http://www.dennisplucinik.com/blog/wp-content/uploads/2012/02/box_model1.gif"><img src="http://www.dennisplucinik.com/blog/wp-content/uploads/2012/02/box_model1.gif" alt="CSS Box Model Diagram" title="CSS Box Model Diagram" width="615" height="500" class="size-full wp-image-1159" style="border: 5px solid #ccc; box-shadow: 0 1px 6px #555;" /></a><p class="wp-caption-text">CSS Box Model Diagram</p></div>
<blockquote cite="http://www.w3.org/TR/CSS2/box.html"><p>The CSS box model describes the rectangular boxes that are generated for elements in the document tree and laid out according to the visual formatting model. <cite>- <a href="http://www.w3.org/TR/CSS2/box.html">W3C</a></cite></p></blockquote>
<p>Before beginning to code a website, we need visually break apart the design into rectangular sections. This process used to be done in the context of an HTML table since CSS support wasn't widespread among browsers at the time. Nowadays, we can think in the context of pure CSS based layouts. Ultimately this gives us more freedom over the layout while retaining the semantic value of the HTML document.</p>
<p>If we take this website, we can clearly see how the sections break down into rectangles. Each of the rectangles will follow the rules of the box model.</p>
<div id="attachment_1174" class="wp-caption aligncenter" style="width: 610px"><img src="http://www.dennisplucinik.com/blog/wp-content/uploads/2012/02/css_layout.gif" alt="CSS Layout illustrating use of the box model" title="CSS Layout illustrating use of the box model" width="600" height="426" class="size-full wp-image-1174" /><p class="wp-caption-text">CSS Layout illustrating use of the box model</p></div>
<p>In the next post, I will explain how we use positioning and floats to bring structure to our markup. </p>
<h2>In Conclusion</h2>
<p>If you have managed to follow along until this point, congratulations! You have a good enough understanding of CSS to move on to bigger and better things. Yes I admit it hasn't been too sexy so far but trust me once we get to positioning, floats, and cross-browser quirks, things are really going to start heating up <img src='http://www.dennisplucinik.com/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<h3>Helpful Articles</h3>
<p><a href="http://sixrevisions.com/css/20_websites_learn_master_css/">20 Websites To Help You Learn and Master CSS</a><br />
<a href="http://meyerweb.com/">meyerweb.com</a></p>
<h3>Related Books</h3>
<p class="amazonBook"><iframe src="http://rcm.amazon.com/e/cm?t=denpluwebdes-20&#038;o=1&#038;p=8&#038;l=as1&#038;asins=0321658531&#038;ref=qf_sp_asin_til&#038;fc1=000000&#038;IS2=1&#038;lt1=_blank&#038;m=amazon&#038;lc1=0000FF&#038;bc1=000000&#038;bg1=FFFFFF&#038;f=ifr" style="width:120px;height:240px;" scrolling="no" marginwidth="0" marginheight="0" frameborder="0"></iframe></p>
<p class="amazonBook"><iframe src="http://rcm.amazon.com/e/cm?t=denpluwebdes-20&#038;o=1&#038;p=8&#038;l=as1&#038;asins=1593272863&#038;ref=qf_sp_asin_til&#038;fc1=000000&#038;IS2=1&#038;lt1=_blank&#038;m=amazon&#038;lc1=0000FF&#038;bc1=000000&#038;bg1=FFFFFF&#038;f=ifr" style="width:120px;height:240px;" scrolling="no" marginwidth="0" marginheight="0" frameborder="0"></iframe></p>
<p class="amazonBook"><iframe src="http://rcm.amazon.com/e/cm?t=denpluwebdes-20&#038;o=1&#038;p=8&#038;l=as1&#038;asins=0596527330&#038;ref=qf_sp_asin_til&#038;fc1=000000&#038;IS2=1&#038;lt1=_blank&#038;m=amazon&#038;lc1=0000FF&#038;bc1=000000&#038;bg1=FFFFFF&#038;f=ifr" style="width:120px;height:240px;" scrolling="no" marginwidth="0" marginheight="0" frameborder="0"></iframe></p>
<p class="amazonBook"><iframe src="http://rcm.amazon.com/e/cm?t=denpluwebdes-20&#038;o=1&#038;p=8&#038;l=as1&#038;asins=0321719638&#038;ref=qf_sp_asin_til&#038;fc1=000000&#038;IS2=1&#038;lt1=_blank&#038;m=amazon&#038;lc1=0000FF&#038;bc1=000000&#038;bg1=FFFFFF&#038;f=ifr" style="width:120px;height:240px;" scrolling="no" marginwidth="0" marginheight="0" frameborder="0"></iframe></p>
]]></content:encoded>
			<wfw:commentRss>http://www.dennisplucinik.com/blog/2012/02/13/learning-web-design-basic-css/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Learning Web Design &#8211; Series Introduction</title>
		<link>http://www.dennisplucinik.com/blog/2012/02/02/learning-web-design-series-introduction/</link>
		<comments>http://www.dennisplucinik.com/blog/2012/02/02/learning-web-design-series-introduction/#comments</comments>
		<pubDate>Thu, 02 Feb 2012 20:00:04 +0000</pubDate>
		<dc:creator>Dennis Plucinik</dc:creator>
				<category><![CDATA[Coding]]></category>
		<category><![CDATA[Design]]></category>
		<category><![CDATA[HTML]]></category>
		<category><![CDATA[Learning Web Design Series]]></category>

		<guid isPermaLink="false">http://www.dennisplucinik.com/blog/?p=1061</guid>
		<description><![CDATA[Starting January 27th I started teaching Web Design 1 at Parsons The New School for Design in New York City. I will be producing quite a bit of content in the next few months and I'll use this blog to &#8230; <a href="http://www.dennisplucinik.com/blog/2012/02/02/learning-web-design-series-introduction/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Starting January 27th I started teaching Web Design 1 at Parsons The New School for Design in New York City. I will be producing quite a bit of content in the next few months and I'll use this blog to expound on the in-class discussions.</p>
<p>You may follow along via the course website:<br />
<a href="http://dennisplucinik.github.com/Parsons">http://dennisplucinik.github.com/Parsons</a></p>
<p>You can access the syllabus, all the slides and additional resources as well.</p>
<p><span id="more-1061"></span></p>
<h2>Topics I Will Cover</h2>
<p>Here is a short synopsis of the topics I'll be covering in the class in order of occurrence.</p>
<ul>
<li>History of the web and HTML
<li>Website fundamentals
<li>HTML basics
<li>CSS basics
<li>JavaScript (i.e., jQuery) basics
<li>HTML5
<li>CSS3
<li>Intermediate JavaScript
<li>PHP &#038; MySQL
</ul>
<p>Each week I assign a few articles to read and an activity (usually a tutorial or simple task related to the week's content). I also briefly recap the previous week's reading assignment at the beginning of each class. In addition to the in-class discussion I plan to write a more well thought out response of my own to each reading here on this blog. So to my friends who want to participate in this discussion outside of class, this is the appropriate venue. The class discussion will remain private although any of my students are welcome to engage with me here as well.</p>
<p>Hopefully my conversations here will help spark new ideas in class and vice versa. If you have any thoughts please let me know in the comments below.</p>
<p>Also, if you want real time updates when I post new articles, <a href="http://www.twitter.com/dennisplucinik">follow me on Twitter at @dennisplucinik</a>.</p>
<p>Thanks for reading!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.dennisplucinik.com/blog/2012/02/02/learning-web-design-series-introduction/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Learn HTML5 Series Introduction</title>
		<link>http://www.dennisplucinik.com/blog/2012/02/01/learn-html5-series-introduction/</link>
		<comments>http://www.dennisplucinik.com/blog/2012/02/01/learn-html5-series-introduction/#comments</comments>
		<pubDate>Wed, 01 Feb 2012 13:52:42 +0000</pubDate>
		<dc:creator>Dennis Plucinik</dc:creator>
				<category><![CDATA[Coding]]></category>
		<category><![CDATA[Design]]></category>
		<category><![CDATA[HTML5]]></category>
		<category><![CDATA[Learn HTML5 Series]]></category>

		<guid isPermaLink="false">http://www.dennisplucinik.com/blog/?p=995</guid>
		<description><![CDATA[I recently started a meetup group here in NYC called Learn HTML5 under the premise that there are "over 1 million Google searches each day by people asking what is HTML5?". The purpose of the meetup is to answer that &#8230; <a href="http://www.dennisplucinik.com/blog/2012/02/01/learn-html5-series-introduction/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>I recently started a meetup group here in NYC called <a href="http://www.meetup.com/Learn-HTML5">Learn HTML5</a> under the premise that there are "over 1 million Google searches each day by people asking what is HTML5?".  The purpose of the meetup is to answer that question for you.  I want to cover this topic via a series of articles under the same name "Learn HTML5".  </p>
<p>What I want to do is start with the basics.  I think the key to understanding HTML5 is to learn the new features and figure out which are relevant to you and your project.  For the first part of this series I will be focusing on aspects of HTML5 relevant to developers and so, we will be looking at a lot of code.  My goal is for you to deeply understand the significance of these new technologies and use your knowledge to help push the web forward.   </p>
<p>This series will help you understand those two things - the components of HTML5 and which are relevant to you. I've broken down the sections for coders, designers, and managers as there are different implications for each group.</p>
<p><span id="more-995"></span></p>
<h2>Content Strategy</h2>
<p>The content for this series will be made available through several channels. The goal is to enable access to this content through as many channels as possible. </p>
<p>Each article will represent one chapter. Chapters will be consolidated into one of three different books based on group (i.e., coders, designers, and managers). Each month I will be presenting a meetup in New York City covering the latest article. Prior to each month's meetup, a full article will be available for download via Amazon, and iBookStore self-publishing. Each book will be available for download once I have presented all the topics. Members of the meetup will have access to the full SlideShare presentation as well as a free download of the final book for each group once we have completed all the presentations.</p>
<p>Here is the proposed content broken down by group:</p>
<p><strong>Learn HTML5: For Coders</strong></p>
<ul>
<li>What is it?</li>
<li>Web Application Architecture</li>
<li>Building an Offline Capable Book Reading App</li>
<li>Creating QR Codes with Canvas</li>
<li>Creating a Location Based Mobile Web App</li>
<li>Embedding Video and Audio Using the VideoJS Library</li>
</ul>
<p><strong>Learn HTML5: For Designers</strong></p>
<ul>
<li>Designing Responsive Interfaces</li>
<li>Enhancing a WordPress Theme with HTML5</li>
<li>Replacing Sprites with CSS3</li>
</ul>
<p><strong>Learn HTML5: For Managers</strong></p>
<ul>
<li>Why it is Important for Businesses</li>
<li>Opportunities for Mobile Platforms</li>
<li>How to Interview an HTML5 Candidate</li>
<li>Implications on Content Strategy</li>
<li>SEO Implications and Text-Level Semantics</li>
<li>What the Future Holds</li>
</ul>
<h2>In Closing</h2>
<p>That's about all I have to say for now. I know completing everything I've planned so far is a tremendous undertaking but I like a good challenge <img src='http://www.dennisplucinik.com/blog/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' />  The response I've gotten so far on the Meetup group has been very encouraging. If you haven't joined yet, you may do so here: <a href="http://www.meetup.com/Learn-HTML5/">http://www.meetup.com/Learn-HTML5/</a> and leave me some suggestions or feedback!</p>
<p>Also, If you'd like me to cover anything specific that's not listed, let me know, I'd like to build the content around what people want. You can even take a quick poll here: <a href="http://dennisplucinik.tumblr.com/post/8981217169/which-html5-topics-would-you-like-to-know-about">Which HTML5 Topics Would You Like to Know About?</a>.</p>
<p>Until next time.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.dennisplucinik.com/blog/2012/02/01/learn-html5-series-introduction/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>What is HTML5?</title>
		<link>http://www.dennisplucinik.com/blog/2012/01/27/what-is-html5/</link>
		<comments>http://www.dennisplucinik.com/blog/2012/01/27/what-is-html5/#comments</comments>
		<pubDate>Fri, 27 Jan 2012 18:49:38 +0000</pubDate>
		<dc:creator>Dennis Plucinik</dc:creator>
				<category><![CDATA[Coding]]></category>
		<category><![CDATA[HTML5]]></category>
		<category><![CDATA[Learn HTML5 - For Coders]]></category>
		<category><![CDATA[Learn HTML5 Series]]></category>

		<guid isPermaLink="false">http://www.dennisplucinik.com/blog/?p=992</guid>
		<description><![CDATA[In the last year I've seen an almost frantic rush of companies trying to find HTML5 developers, and subsequently a rush of developers scrambling to fill that demand. However, both sides seem unable to answer questions like, "What does HTML5 &#8230; <a href="http://www.dennisplucinik.com/blog/2012/01/27/what-is-html5/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>In the last year I've seen an almost frantic rush of companies trying to find HTML5 developers, and subsequently a rush of developers scrambling to fill that demand.  However, both sides seem unable to answer questions like, "What does HTML5 actually mean?", "Can I call myself an HTML5 developer?", "What do I look for when hiring an HTML5 developer?"  The first question I always ask about the project is "Which components actually require HTML5?"  From there we can begin to narrow down what we're looking for and eventually answer all the other questions.  I ask this first because I frequently hear things like "It has to be optimized for iPad" which does NOT automatically mean you need HTML5.  In many cases, the project may even just need a good JavaScript developer.</p>
<p><span id="more-992"></span></p>
<h2>It's Not Just Version Five</h2>
<p>Saying HTML5 is "the fifth revision of HTML" is misleading.  Whereas previous versions of HTML primarily consisted of markup upgrades such as new semantic tags, or stricter syntax, this version encompasses much more.</p>
<h3>Paving the Cow-Paths</h3>
<p>The general theme behind HTML5's development effort has been to pay close attention to what developers are already doing when adding new features.  This is why we have things like rounded corners built into the CSS3 spec, as well as the new &lt;video&gt; tag. </p>
<p>HTML5 is meant to take existing conventions, make them easier to implement, more performant, and native.  </p>
<h3>Combining Existing Technologies</h3>
<p>With the publication of HTML 4 in 1997, the primary focus was on deprecating presentational tags (e.g., &lt;font&gt;) in favor of using CSS.  At that point, HTML, CSS, and JavaScript played distinctly different roles and were referred to individually.</p>
<p>With HTML5, we have a perceived marriage of those three primary front-end technologies.  In truth, they are still distinctly different but you can think of them as playing on the same team in the web-browser game.</p>
<h3>Role Switching</h3>
<p>Where one technology was previously used to do certain things, we now have native support built in.  For example, <a href="">CSS3</a> takes over some of the tasks previously managed by JavaScript like <a href="http://">mouseover transitions</a>, <a href="http://">simple animations</a>, <a href="http://">rounded corners</a>, <a href="http://">drop shadows</a>, &#038; <a href="http://">text-shadows</a>.  New semantic markup replaces the need to use CSS for marking up content by adding worthless class names.  Role switching can be illustrated clearly in text-level semantics.  For example, instead of writing:</p>
<pre>&lt;div class="header"&gt;</pre>
<p>we now write:</p>
<pre>&lt;header&gt;</pre>
<p>There are a host of other new semantic tags including footer, section, article, aside, and more.  The new &lt;audio&gt; and &lt;video&gt; tags have given us an option other than relying on 3rd party plugins for managing rich media.  We can now augment our Flash video player implementations with the capability of operating on non-Flash supported devices such as iPhone and iPad. </p>
<h3>HTML5 and Mobile Devices</h3>
<p>Mobile devices have been the central topic of many HTML5 conversations and with good reason.  One component of the HTML5 spec is <a href="">device access</a>.  Which means some of the hardware on your mobile device can be accessed with JavaScript.  This includes your <a href="">device’s GPS</a>, <a href="">address book</a>, <a href="">calendar</a>, and more. </p>
<p>HTML5 is heralding in an era of thin clients and mobile applications with APIs for building more native-like functionality such as local storage, application cache, and file APIs.  This allows developers to design applications that remain functional even when there is no internet connection - much like a native app.  Apple has even added helpers to WebKit (e.g., viewport size management) making the transition more seamless.</p>
<h2>A Little More History</h2>
<p>Before we get in over our head with all of the cool new features of HTML5, it’s worth it to have some understanding of how we got here.</p>
<h3>HTML Version Timeline</h3>
<p>Let’s go back to 1991. The first musings of HTML were published in a document titled <a href="http://www.w3.org/History/19921103-hypertext/hypertext/WWW/MarkUp/Tags.html">“HTML Tags”</a> by Tim Berners-Lee. Though he is considered by many to be the father of the internet (if not for the sake of that document alone), he indeed was standing on the shoulders of those who came before him.</p>
<p>Before HTML in 1991, there was SGML in 1974, and before that - GML in 1969. HTML was built on the concept of refining an existing technology that could <em>almost</em> do the job, but not quite. HTML5 is a continuation of this tradition.</p>
<h3>Microformats</h3>
<p>Remember I talked about “paving the cowpaths”? The way an HTML spec gets published involves a bit of “running before you can walk”. Since the process involves such a long period of revisions, browsers vendors incorporate proposed specs before they are actually accepted by the standards committees (i.e., the W3C). The spec authors (i.e., WHATWG) know this and so in order to usher these new features as smoothly as possible, they strongly consider what users are already doing when developing a new feature.</p>
<p>Microformats are an example of where existing behavior formed the foundation of new HTML5 specs.  Microformats are an agreed upon convention for identifying common data types such as blog post elements including publish date, title, author name, etc.  The goal is to create a more semantically rich document and microformats accomplish this (albeit in a round-about way) by adding class names to corresponding elements (e.g., &lt;div class="hnews hentry item"&gt;).  Microformats in HTML5 are called "text level semantics" which we discussed earlier with the header, footer, section, article, and aside tags.</p>
<h2>What's Next?</h3>
<p>As a general summary we could say HTML5 provides a new set of elements meant to give native support for existing technologies via more semantically rich documents.</p>
<p>It is comforting to know that there are more features coming with every new browser version.  The biggest hurdle any new language faces is adoption.  With HTML5 that means adoption by browser vendors of proposed new features.  Each browser adopts a different number of new features with each new version getting us slowly closer to full adoption.  It sounds slow and painful but it is nowhere near as bad as it was in the last decade for two reasons.  First, all new browser versions that support HTML5 are using the same parsing engine.  This eliminates cross-browser rendering variances.  Second, mobile devices running a modern OS (e.g., Android and iOS) have modern browsers installed which support many new HTML5 features.  Although this means that yes there is yet another device to support, those devices are all reasonably advanced (as opposed to say, developing for desktop browsers where some users still use IE6.)</p>
<p>What I have briefly tried to describe is where we are, how we got here, and where we are headed. I will continue to go into more detail with this series and hopefully cover at least all of the basic topics soon. if there is something specific you would like to hear about please let me know. </p>
]]></content:encoded>
			<wfw:commentRss>http://www.dennisplucinik.com/blog/2012/01/27/what-is-html5/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>2 Beginner Tips for Adobe Illustrator</title>
		<link>http://www.dennisplucinik.com/blog/2011/07/21/beginner-tips-for-adobe-illustrator/</link>
		<comments>http://www.dennisplucinik.com/blog/2011/07/21/beginner-tips-for-adobe-illustrator/#comments</comments>
		<pubDate>Thu, 21 Jul 2011 22:49:09 +0000</pubDate>
		<dc:creator>Dennis Plucinik</dc:creator>
				<category><![CDATA[Design]]></category>
		<category><![CDATA[Adobe]]></category>
		<category><![CDATA[Illustrator]]></category>

		<guid isPermaLink="false">http://www.dennisplucinik.com/blog/?p=964</guid>
		<description><![CDATA[I've used Illustrator in the past but I don't honestly remember my way around the interface. So as per my usual routine, I will be recording my intro steps for you and future me. Here are the first to things &#8230; <a href="http://www.dennisplucinik.com/blog/2011/07/21/beginner-tips-for-adobe-illustrator/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>I've used Illustrator in the past but I don't honestly remember my way around the interface. So as per my usual routine, I will be recording my intro steps for you and future me.</p>
<p>Here are the first to things that tripped me up. Everything beyond this I'll probably resort to tutorials or just find on my own. Enjoy!<br />
<span id="more-964"></span></p>
<h2>1.) How to change the canvas size</h2>
<ol>
<li>From the menu bar click File > Document Setup</li>
<li>In the Document Setup dialog menu, click the Edit Artboards button (Figure 1-1)<br />
<br />
<div id="attachment_971" class="wp-caption aligncenter" style="width: 510px"><img src="http://www.dennisplucinik.com/blog/wp-content/uploads/2011/07/Screen-shot-2011-07-15-at-12.09.59-PM.gif" alt="" title="Document Setup &gt; Edit Artboards" width="500" height="548" class="size-full wp-image-971" /><p class="wp-caption-text">Document Setup &gt; Edit Artboards - Figure 1-1</p></div>
</li>
<li>In the toolbar you can change your height and width settings (Figure 1-2)<br />
<br />
<div id="attachment_972" class="wp-caption aligncenter" style="width: 588px"><img src="http://www.dennisplucinik.com/blog/wp-content/uploads/2011/07/Screen-shot-2011-07-15-at-12.11.11-PM.gif" alt="" title="height and width settings" width="578" height="314" class="size-full wp-image-972" /><p class="wp-caption-text">height and width settings - Figure 1-2</p></div>
</li>
</ol>
<h2>2.) How to draw a rounded corner button</h2>
<ol>
<li>Draw a box with the rounded rectangle tool (Figure 2-1)<br />
<br />
<div id="attachment_984" class="wp-caption aligncenter" style="width: 307px"><img src="http://www.dennisplucinik.com/blog/wp-content/uploads/2011/07/Screen-shot-2011-07-15-at-12.36.gif" alt="" title="Draw a box with the rounded rectangle tool" width="297" height="356" class="size-full wp-image-984" /><p class="wp-caption-text">Draw a box with the rounded rectangle tool - Figure 2-1</p></div>
</li>
<li>To change the corner radius, repeat step 1 but before releasing the mouse button press the up or down key to marginally increase and decrease the radius respectively, or press the left or right key to fully decrease or increase the roundness respectively.<sup>1</sup></li>
</ol>
<h3>Helpful Articles</h3>
<p><sup>1</sup><a href="http://livedocs.adobe.com/en_US/Illustrator/13.0/help.html?content=WS714a382cdf7d304e7e07d0100196cbc5f-6261.html">http://livedocs.adobe.com/en_US/Illustrator/13.0/help.html?content=WS714a382cdf7d304e7e07d0100196cbc5f-6261.html</a></p>
<h3>Related Books</h3>
<p class="amazonBook"><iframe src="http://rcm.amazon.com/e/cm?t=dennipluci-20&#038;o=1&#038;p=8&#038;l=as1&#038;asins=032170178X&#038;ref=tf_til&#038;fc1=000000&#038;IS2=1&#038;lt1=_blank&#038;m=amazon&#038;lc1=0000FF&#038;bc1=FFFFFF&#038;bg1=FFFFFF&#038;npa=1&#038;f=ifr" style="width:120px;height:240px;" scrolling="no" marginwidth="0" marginheight="0" frameborder="0"></iframe></p>
<p class="amazonBook"><iframe src="http://rcm.amazon.com/e/cm?t=dennipluci-20&#038;o=1&#038;p=8&#038;l=as1&#038;asins=0321573781&#038;ref=tf_til&#038;fc1=000000&#038;IS2=1&#038;lt1=_blank&#038;m=amazon&#038;lc1=0000FF&#038;bc1=FFFFFF&#038;bg1=FFFFFF&#038;npa=1&#038;f=ifr" style="width:120px;height:240px;" scrolling="no" marginwidth="0" marginheight="0" frameborder="0"></iframe></p>
<p class="amazonBook"><iframe src="http://rcm.amazon.com/e/cm?t=dennipluci-20&#038;o=1&#038;p=8&#038;l=as1&#038;asins=0596808011&#038;ref=tf_til&#038;fc1=000000&#038;IS2=1&#038;lt1=_blank&#038;m=amazon&#038;lc1=0000FF&#038;bc1=FFFFFF&#038;bg1=FFFFFF&#038;npa=1&#038;f=ifr" style="width:120px;height:240px;" scrolling="no" marginwidth="0" marginheight="0" frameborder="0"></iframe></p>
<p class="amazonBook"><iframe src="http://rcm.amazon.com/e/cm?t=dennipluci-20&#038;o=1&#038;p=8&#038;l=as1&#038;asins=0321713060&#038;ref=tf_til&#038;fc1=000000&#038;IS2=1&#038;lt1=_blank&#038;m=amazon&#038;lc1=0000FF&#038;bc1=FFFFFF&#038;bg1=FFFFFF&#038;npa=1&#038;f=ifr" style="width:120px;height:240px;" scrolling="no" marginwidth="0" marginheight="0" frameborder="0"></iframe></p>
]]></content:encoded>
			<wfw:commentRss>http://www.dennisplucinik.com/blog/2011/07/21/beginner-tips-for-adobe-illustrator/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>JavaScript Explained: Difference Between Logical OR &#8220;&#124;&#124;&#8221; and Bitwise OR &#8220;&#124;&#8221;</title>
		<link>http://www.dennisplucinik.com/blog/2011/05/28/javascript-explained-difference-between-logical-or-and-bitwise-or/</link>
		<comments>http://www.dennisplucinik.com/blog/2011/05/28/javascript-explained-difference-between-logical-or-and-bitwise-or/#comments</comments>
		<pubDate>Sat, 28 May 2011 19:19:36 +0000</pubDate>
		<dc:creator>Dennis Plucinik</dc:creator>
				<category><![CDATA[Coding]]></category>
		<category><![CDATA[javascript]]></category>

		<guid isPermaLink="false">http://www.dennisplucinik.com/blog/?p=893</guid>
		<description><![CDATA[I'm not ashamed to say today I got slammed on a JavaScript pop quiz presented to me by a curious coworker. It is the type of question you might see on a JavaScript-centric job interview conducted by someone who likes &#8230; <a href="http://www.dennisplucinik.com/blog/2011/05/28/javascript-explained-difference-between-logical-or-and-bitwise-or/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>I'm not ashamed to say today I got slammed on a JavaScript pop quiz presented to me by a curious coworker. It is the type of question you might see on a JavaScript-centric job interview conducted by someone who likes giving questions that trip you up : )</p>
<p><span id="more-893"></span></p>
<p>Here's the quiz:</p>
<pre>var moo = 2;
moo = moo | 1;
alert(moo);</pre>
<p>The question is: what is the value of moo in the alert?</p>
<p>If you answered 2, Congratulations! You are part of the majority of JavaScript developers who got this wrong (including myself, and yes I'm being presumptious). The tricky part is the single-pipe on line 2. Naively, I misunderstood it to mean "OR" which in my opinion is understandable since it actually does mean "OR". The problem is that there are two types of OR - Logical and Bitwise. The one presented in the test is the latter.</p>
<p>The official definition for a Bitwise OR is "<dfn>Returns a one in each bit position for which the corresponding bits of either or both operands are ones</dfn>." (<cite>Mozilla</cite>). </p>
<p>Maybe I'm alone here but that sounds like Greek to me. </p>
<h3>Helpful Articles</h3>
<p>Mozilla: <a href="https://developer.mozilla.org/en/javascript/reference/operators/bitwise_operators">https://developer.mozilla.org/en/javascript/reference/operators/bitwise_operators</a><br />
<a href="http://www.eecs.umich.edu/~bartlett/jsops.html">http://www.eecs.umich.edu/~bartlett/jsops.html</a></p>
<h3>Related Books</h3>
]]></content:encoded>
			<wfw:commentRss>http://www.dennisplucinik.com/blog/2011/05/28/javascript-explained-difference-between-logical-or-and-bitwise-or/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>6 SEO Secrets That Can Get Your Website Banned From Google</title>
		<link>http://www.dennisplucinik.com/blog/2011/05/21/6-seo-secrets-that-can-get-your-website-banned-from-google/</link>
		<comments>http://www.dennisplucinik.com/blog/2011/05/21/6-seo-secrets-that-can-get-your-website-banned-from-google/#comments</comments>
		<pubDate>Sun, 22 May 2011 02:07:10 +0000</pubDate>
		<dc:creator>David Murton</dc:creator>
				<category><![CDATA[Marketing]]></category>
		<category><![CDATA[Google]]></category>
		<category><![CDATA[SEO]]></category>

		<guid isPermaLink="false">http://www.dennisplucinik.com/blog/?p=924</guid>
		<description><![CDATA[Professional SEO services and website developers go to great lengths to ensure their clients have top notch websites that generate as much traffic as possible. Google is always on the lookout for pages that use dirty tricks to attract visitors. &#8230; <a href="http://www.dennisplucinik.com/blog/2011/05/21/6-seo-secrets-that-can-get-your-website-banned-from-google/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Professional <a href="http://www.inetzeal.net/">SEO services</a> and website developers go to great lengths to ensure their clients have top notch websites that generate as much traffic as possible. Google is always on the lookout for pages that use dirty tricks to attract visitors. This post explores six of those tricks, from a different, more humorous perspective.</p>
<p><span id="more-924"></span></p>
<h2>Ad click schemes</h2>
<p>Click-bot programs are tools designed to scour a site from behind proxies and click on ads. Proxies are magical gateways in a cyber-sea of unicorn ponies and wizards that protect web sites from those evil spiders Google uses to destroy revenue and consume the souls of the virtuous. For those who require a more human touch in making money online, there are sites, or click rings, that advertise "AdSense click" revenue generation. Join a click ring today to Get Rich Quick.</p>
<h2>Hosting malicious software</h2>
<p>This includes spyware, trojans, adware, malicious Javascript code and so on. Web surfers tend to grow bored after a short time online. That is why they surf the web instead of staying on a single page for longer than a few seconds. The insightful webmaster learns how to cajole users into finding the best content - their content - via malware.</p>
<p>For those uninitiated in this art, it is highly recommended to avoid patching server vulnerabilities. Before long a friendly cyberspace wizard will find those vulnerabilities and, sans your humble request for help, take your online presence to the next level of enlightenment. Wizards typically operate from behind seven or more proxies, weaving their magic to direct unwary passersby to your site, increasing revenue as a result.</p>
<h2>Paid links</h2>
<p>Why build links in a way Googlebot considers natural when an unnatural approach maximizes cash flow? So-called natural link building, by hosting content others find valuable, takes forever to produce substantial results. The quickest way to earn money with link building is to pay for as many links as feasible, as fast as possible. Googlebot checks for rapid backlink accumulation, <a href="http://www.mattcutts.com/blog/how-to-report-paid-links/">but there is little chance of ever being caught.</a></p>
<h2>Stacking title tags</h2>
<p>Create multiple title tags for each web page in a site. People and web browsers see only one title tag, so this is a completely safe practice, right? Googlebot is coded to search for this, but what is the likelihood of being caught? If you said slim to nil, you are not exactly right, but what is life without a little danger? Take a chance and experience the excitement.</p>
<h2>Doorway pages</h2>
<p>A quick Meta refresh never hurt anyone. This can be implemented with 301 or 302 redirection headers, directing a user agent to a specified page. Also called bridge, portal or gateway pages, doorway pages are a boon for business. Matt Cutts may disagree, but consider: Visitors searching for information about "sea turtles" end up on your page about climate change. Brilliant. Implement this strategy right away. It is good for business, and will have you snickering into the night.</p>
<h2>Cloaking</h2>
<p>Cloaking is the art and science of showing a search engine spider one page, but tactfully displaying another page to users. For instance, when the IP address of a requesting user corresponds to that of a spider, the web server returns a page about kittens. When a human user requests that same page, however, they see a page of pornography. Google has stated that cloaking is okay for certain purposes, like delivering a page based on a user's language and location, but that <a href="http://www.google.com/support/webmasters/bin/answer.py?answer=66355">serving pages based on user agent data could be seen as deceptive.</a></p>
<p>In all seriousness, ad click schemes, malware, fast link building, stacked titles, doorway pages and deceptive cloaking should be avoided. Those practices are well-known to Google's search team, and Googlebot's code discovers these, and similar, underhanded tactics with ease.</p>
<hr />
<h3>About the author</h3>
<p>
<img src="http://www.dennisplucinik.com/blog/wp-content/uploads/2011/03/David-Murton.jpg" alt="David Murton" title="David Murton" width="70" height="93" class="alignleft size-full wp-image-650" style="float: left;margin-right: 10px;" />David Murton has been helping companies build and maintain their online relationships with customers since 2006. He is also a professional writer and blogger, with a particular interest in the open source Drupal platform. On a more personal note, David is an avid piano and accordion player, drawn especially to music of the classical and romantic periods.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.dennisplucinik.com/blog/2011/05/21/6-seo-secrets-that-can-get-your-website-banned-from-google/feed/</wfw:commentRss>
		<slash:comments>10</slash:comments>
		</item>
		<item>
		<title>Setting up an Amazon EC2 Server to Run TeamCity</title>
		<link>http://www.dennisplucinik.com/blog/2011/04/06/setting-up-an-amazon-ec2-server-to-run-teamcity/</link>
		<comments>http://www.dennisplucinik.com/blog/2011/04/06/setting-up-an-amazon-ec2-server-to-run-teamcity/#comments</comments>
		<pubDate>Thu, 07 Apr 2011 03:04:11 +0000</pubDate>
		<dc:creator>Dennis Plucinik</dc:creator>
				<category><![CDATA[Hosting]]></category>
		<category><![CDATA[Amazon EC2]]></category>
		<category><![CDATA[CI]]></category>
		<category><![CDATA[TeamCity]]></category>

		<guid isPermaLink="false">http://www.dennisplucinik.com/blog/?p=734</guid>
		<description><![CDATA[This post is a follow-up to my previous post - Intro to Continuous Integration with TeamCity. As I learned, TeamCity is best (for my project) when set up on an Amazon EC2 instance. Since we're using Git (via GitHub) for &#8230; <a href="http://www.dennisplucinik.com/blog/2011/04/06/setting-up-an-amazon-ec2-server-to-run-teamcity/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>This post is a follow-up to my previous post - <a href="http://www.dennisplucinik.com/blog/2011/04/06/intro-to-continuous-integration-with-teamcity/">Intro to Continuous Integration with TeamCity</a>. As I learned, TeamCity is best (for my project) when set up on an Amazon EC2 instance. Since we're using Git (via GitHub) for source control, TeamCity can listen to our GitHub repo and recognize when a commit has been made so it can run any appropriate build procedures.<br />
<span id="more-734"></span></p>
<p>This post makes the following assumptions:</p>
<ul>
<li>You have set up an account on GitHub</li>
<li>You have successfully been able to <a href="http://www.dennisplucinik.com/blog/2011/03/25/uploading-a-project-to-github/">push changes to it</a> (either from the command line or <a href="http://www.dennisplucinik.com/blog/2011/03/25/configuring-the-egit-plugin-for-eclipse/">from Eclipse</a>)</li>
</ul>
<p>
In this post I will walk you through the following steps:</p>
<ol>
<li>Setting up an Amazon EC2 account</li>
<li>Configuring and launching an instance</li>
<li>Downloading and installing TeamCity on the instance</li>
<li><del>Configuring TeamCity to communicate with GitHub</del>*</li>
<li>Saving the instance for later use</li>
</ol>
<p><em>* These items will be covered in a later post.</em></p>
<h2>Setting up an Amazon EC2 account</h2>
<p>First, sign up for an account here: <a href="http://aws.amazon.com/ec2/">http://aws.amazon.com/ec2/</a></p>
<p>Once you have your account and billing in order, you should see Figure 1-1 when you log in. This is the main dashboard. You will spend most of your time with AWS working within this interface.</p>
<div id="attachment_739" class="wp-caption aligncenter" style="width: 627px"><img src="http://www.dennisplucinik.com/blog/wp-content/uploads/2011/03/control-panel.gif" alt="Figure 1-1 - Amazon EC2 Console Dashboard" title="Figure 1-1 - Amazon EC2 Console Dashboard" width="617" height="326" class="size-full wp-image-739" /><p class="wp-caption-text">Figure 1-1 - Amazon EC2 Console Dashboard</p></div>
<h2>Configuring and launching an instance</h2>
<p>From the Console Dashboard, click the "Launch Instance" button. A popup will appear that looks like Figure 2-1. If for some reason you don't see a "Getting Started" section with a "Launch Instance" button on the main dashboard, you can click the "Instances" link in the Navigation panel, then click the "Launch" button inside that screen. It should be to the top left of the main panel.<br />
<div id="attachment_740" class="wp-caption aligncenter" style="width: 650px"><img src="http://www.dennisplucinik.com/blog/wp-content/uploads/2011/03/step1.gif" alt="Figure 2-1 - Request Instances Wizard: Choose an AMI" title="Figure 2-1 - Request Instances Wizard: Choose an AMI" width="640" height="441" class="size-full wp-image-740" /><p class="wp-caption-text">Figure 2-1 - Request Instances Wizard: Choose an AMI</p></div></p>
<p>Click the "Select" button next to <b>Basic 32-bit Amazon Linux AMI 2011.02.1 Basic</b>. Figure 2-2 will appear.<br />
<div id="attachment_741" class="wp-caption aligncenter" style="width: 650px"><img src="http://www.dennisplucinik.com/blog/wp-content/uploads/2011/03/step2.gif" alt="Figure 2-1 - Request Instances Wizard: Instance Details" title="Figure 2-1 - Request Instances Wizard: Instance Details" width="640" height="456" class="size-full wp-image-741" /><p class="wp-caption-text">Figure 2-1 - Request Instances Wizard: Instance Details</p></div></p>
<p>From here I changed the Instance Type drop down to "Micro (t1.micro, 613MB)" just because I was testing and I believe the Micro instances are free. Leave all the other options set to default and click "Continue". You should now see Figure 2-3. (Update/Note: Micro instances are free for now, I'm not sure where I read this but they will eventually charge for using it. It may be a startup trial or something. Also, there is a specific reason why we're using a Micro instance which I will explain later. Also I've found out that our TeamCity system will require another larger instance for another reason which I will explain later.)</p>
<div id="attachment_742" class="wp-caption aligncenter" style="width: 650px"><img src="http://www.dennisplucinik.com/blog/wp-content/uploads/2011/03/step3.gif" alt="Figure 2-3 - Request Instance Wizard: Instance Details" title="Figure 2-3 - Request Instance Wizard: Instance Details" width="640" height="456" class="size-full wp-image-742" /><p class="wp-caption-text">Figure 2-3 - Request Instance Wizard: Instance Details</p></div>
<p>Leave all the defaults, click "Continue". See Figure 2-4.</p>
<div id="attachment_744" class="wp-caption aligncenter" style="width: 650px"><img src="http://www.dennisplucinik.com/blog/wp-content/uploads/2011/03/step4.gif" alt="Figure 2-4 - Request Instance Wizard: Instance Details" title="Figure 2-4 - Request Instance Wizard: Instance Details" width="640" height="456" class="size-full wp-image-744" /><p class="wp-caption-text">Figure 2-4 - Request Instance Wizard: Instance Details</p></div>
<p>I added "TeamCity Server" to the value of the first Name/Value pair. I'm not sure where this information is surfaced later but it seems fitting for now. Click "Continue". See Figure 2-5.</p>
<div id="attachment_745" class="wp-caption aligncenter" style="width: 650px"><img src="http://www.dennisplucinik.com/blog/wp-content/uploads/2011/03/step5.gif" alt="Figure 2-5 - Request Instance Wizard: Create Key Pair" title="Figure 2-5 - Request Instance Wizard: Create Key Pair" width="640" height="456" class="size-full wp-image-745" /><p class="wp-caption-text">Figure 2-5 - Request Instance Wizard: Create Key Pair</p></div>
<p>Here again, I don't know what the purpose of the name is / where it gets surfaced later / etc. I just followed the recommendation and set the name for my key pair to "TeamCityKey". Follow the rest of the instructions (you will download a .pem file for later use). Click "Continue" when it becomes available. See Figure 2-6.</p>
<div id="attachment_746" class="wp-caption aligncenter" style="width: 650px"><a href="http://www.dennisplucinik.com/blog/wp-content/uploads/2011/03/step6.gif"><img src="http://www.dennisplucinik.com/blog/wp-content/uploads/2011/03/step6.gif" alt="Figure 2-6 - Request Instance Wizard: Configure Firewall" title="Figure 2-6 - Request Instance Wizard: Configure Firewall" width="640" height="456" class="size-full wp-image-746" /></a><p class="wp-caption-text">Figure 2-6 - Request Instance Wizard: Configure Firewall</p></div>
<p>By default, I believe SSH is added as a rule. If it is not, select it from the drop down and click "Add Rule". Also, select HTTP from the drop down and click "Add Rule". This restricts connections to those two types so our other services won't have a problem connecting. Use whatever Group Name and Description you want, or leave the defaults like me. Click "Continue". See Figure 2-7.</p>
<div id="attachment_747" class="wp-caption aligncenter" style="width: 650px"><img src="http://www.dennisplucinik.com/blog/wp-content/uploads/2011/03/step7.gif" alt="Figure 2-7 - Request Instance Wizard: Review" title="Figure 2-7 - Request Instance Wizard: Review" width="640" height="456" class="size-full wp-image-747" /><p class="wp-caption-text">Figure 2-7 - Request Instance Wizard: Review</p></div>
<p>This is the final review before spinning up the new instance. If everything looks good, click "Launch". You should now see Figure 2-8.<br />
<div id="attachment_748" class="wp-caption aligncenter" style="width: 650px"><img src="http://www.dennisplucinik.com/blog/wp-content/uploads/2011/03/step8.gif" alt="Figure 2-8 - Launch Instance Wizard" title="Figure 2-8 - Launch Instance Wizard" width="640" height="338" class="size-full wp-image-748" /><p class="wp-caption-text">Figure 2-8 - Launch Instance Wizard</p></div></p>
<p>You can either read about all the other AWS features, or just click "Close" like me. You should now see a table row with your instance info and a status of "running". See Figure 2-9.<br />
<div id="attachment_749" class="wp-caption aligncenter" style="width: 650px"><img src="http://www.dennisplucinik.com/blog/wp-content/uploads/2011/03/step9.gif" alt="Figure 2-9 - Instance running" title="Figure 2-9 - Instance running" width="640" height="134" class="size-full wp-image-749" /><p class="wp-caption-text">Figure 2-9 - Instance running</p></div></p>
<p>Once the status switches from "pending" to "running", right click anywhere on the row, you will see a popup (Figure 2-10), click "Connect" and you will see Figure 2-11.<br />
<div id="attachment_750" class="wp-caption aligncenter" style="width: 252px"><img src="http://www.dennisplucinik.com/blog/wp-content/uploads/2011/03/step10.gif" alt="Figure 2-10 - Running instance option menu" title="Figure 2-10 - Running instance option menu" width="242" height="437" class="size-full wp-image-750" /><p class="wp-caption-text">Figure 2-10 - Running instance option menu</p></div></p>
<div id="attachment_751" class="wp-caption aligncenter" style="width: 548px"><img src="http://www.dennisplucinik.com/blog/wp-content/uploads/2011/03/step11.gif" alt="Figure 2-11 - Connect Help - Secure Shell (SSH)" title="Figure 2-11 - Connect Help - Secure Shell (SSH)" width="538" height="511" class="size-full wp-image-751" /><p class="wp-caption-text">Figure 2-11 - Connect Help - Secure Shell (SSH)</p></div>
<p>This part screwed me up. IMO these instructions are painful. It's stuff like this that bother me. In hindsight, now that I have done this I think "that was a stupid mistake" and probably have the same unhelpful mentality as people around me who just said "oh that's easy" when I asked for help. I fortunately do have at least one friend who took the time to talk me through it despite my bitching and moaning. </p>
<p>So <b>here are the easy instructions</b> - copy that line of code in the example, paste it into your SSH client (PuTTY, Terminal, etc.) and hit enter. If this doesn't work, read through those 4 instructions again, specifically step 3 regarding setting the file permissions. You might just have to run chmod 400 on it first. Another possible error (the one I encountered) was this message:</p>
<pre>Please login as the ec2-user user rather than the root user</pre>
<p>To remedy this, just change the "root@" part of your command line to "ec2-user@" like this:</p>
<pre>ssh -i {YourKeyName}.pem ec2-user@ec2-xxx-xx-xx-xxx.compute-1.amazonaws.com</pre>
<p>If this goes well, you should see a little EC2 ascii art, and a blank commmand line. You will likely find yourself in /home/ec2-user/. </p>
<p>FINALLY we can move onto the next step...</p>
<h2>Downloading and installing TeamCity on the instance</h2>
<p>Now that we have the EC2 instance up and running, we can move back to my previous post which elaborates on downloading and installation:<br />
<a href="http://www.dennisplucinik.com/blog/2011/04/06/intro-to-continuous-integration-with-teamcity#DownloadAndInstallTeamCity">Intro to Continuous Integration with TeamCity: Downloading and installing TeamCity</a>. </p>
<p>Please read make sure you understand the concepts described there before continuing.</p>
<h2>Saving the instance for later use</h2>
<p>One thing about Amazon EC2 is that whenever you stop an instance, you lose everything. This includes any downloads, installations, configurations, etc. In order to avoid losing all the effort you put into setting up this server you'll need to create an image. </p>
<p>To do this, right click on your instance name, and in the subsequent popup box click "Create Image (EBS AMI)". You should see Figure 3-1.</p>
<div id="attachment_763" class="wp-caption aligncenter" style="width: 647px"><img src="http://www.dennisplucinik.com/blog/wp-content/uploads/2011/03/step3-1.gif" alt="Figure 3-1 - Create Image" title="Figure 3-1 - Create Image" width="637" height="465" class="size-full wp-image-763" /><p class="wp-caption-text">Figure 3-1 - Create Image</p></div>
<p>Type in an Image Name and Description and click "Create This Image". You should now see Figure 3-2.<br />
<div id="attachment_764" class="wp-caption aligncenter" style="width: 646px"><img src="http://www.dennisplucinik.com/blog/wp-content/uploads/2011/03/step3-2.gif" alt="Figure 3-2 - Create Image" title="Figure 3-2 - Create Image" width="636" height="295" class="size-full wp-image-764" /><p class="wp-caption-text">Figure 3-2 - Create Image</p></div></p>
<p>Click "Close". Now if you click "AMIs" in the Navigation panel, you should see your new image processing. See Figure 3-3.<br />
<div id="attachment_765" class="wp-caption aligncenter" style="width: 650px"><img src="http://www.dennisplucinik.com/blog/wp-content/uploads/2011/03/step3-3.gif" alt="Figure 3-3 - Saved image" title="Figure 3-3 - Saved image" width="640" height="169" class="size-full wp-image-765" /><p class="wp-caption-text">Figure 3-3 - Saved image</p></div></p>
<p>At this point the next step will be to set up one more EC2 instance for the TeamCity Build Agent to run on. To briefly elaborate, we will save an image of the larger instance, and instruct the micro instance to spin it up when a repo change is detected. I will absolutely document the process of configuring TeamCity to do just that in another post. </p>
<h2>In closing</h2>
<p>Hopefully this has provided you with some helpful info. If you've got any questions please drop them in the comments below. They're more likely to get answered there either by me or someone else as this is a fairly highly trafficked blog.</p>
<p>Thanks for reading!</p>
<h3>Helpful Articles</h3>
<p><a href="http://www.dennisplucinik.com/blog/2011/03/25/intro-to-continuous-integration-with-teamcity">http://www.dennisplucinik.com/blog/2011/03/25/intro-to-continuous-integration-with-teamcity</a></p>
<p><a href="http://www.jadurham.com/codevault/amazon-cloud-aws/17-ec2-a-teamcity-youtrack-a-ssl.html">http://www.jadurham.com/codevault/amazon-cloud-aws/17-ec2-a-teamcity-youtrack-a-ssl.html</a><br />
<a href="http://confluence.jetbrains.net/display/TCD6/Installing+and+Configuring+the+TeamCity+Server#InstallingandConfiguringtheTeamCityServer-installingWithTomcat">http://confluence.jetbrains.net/display/TCD6/Installing+and+Configu...uringtheTeamCityServer-installingWithTomcat</a><br />
<a href="http://www.jetbrains.com/teamcity/features/amazon_ec2.html">http://www.jetbrains.com/teamcity/features/amazon_ec2.html</a></p>
<h3>Related Books</h3>
<p class="amazonBook"><iframe src="http://rcm.amazon.com/e/cm?t=dennipluci-20&#038;o=1&#038;p=8&#038;l=as1&#038;asins=1430227249&#038;ref=qf_sp_asin_til&#038;fc1=000000&#038;IS2=1&#038;lt1=_blank&#038;m=amazon&#038;lc1=0000FF&#038;bc1=000000&#038;bg1=FFFFFF&#038;f=ifr" style="width:120px;height:240px;" scrolling="no" marginwidth="0" marginheight="0" frameborder="0"></iframe></p>
<p class="amazonBook"><iframe src="http://rcm.amazon.com/e/cm?t=dennipluci-20&#038;o=1&#038;p=8&#038;l=as1&#038;asins=0980576830&#038;ref=qf_sp_asin_til&#038;fc1=000000&#038;IS2=1&#038;lt1=_blank&#038;m=amazon&#038;lc1=0000FF&#038;bc1=000000&#038;bg1=FFFFFF&#038;f=ifr" style="width:120px;height:240px;" scrolling="no" marginwidth="0" marginheight="0" frameborder="0"></iframe></p>
<p class="amazonBook"><iframe src="http://rcm.amazon.com/e/cm?t=dennipluci-20&#038;o=1&#038;p=8&#038;l=as1&#038;asins=0596515812&#038;ref=qf_sp_asin_til&#038;fc1=000000&#038;IS2=1&#038;lt1=_blank&#038;m=amazon&#038;lc1=0000FF&#038;bc1=000000&#038;bg1=FFFFFF&#038;f=ifr" style="width:120px;height:240px;" scrolling="no" marginwidth="0" marginheight="0" frameborder="0"></iframe></p>
<p class="amazonBook"><iframe src="http://rcm.amazon.com/e/cm?t=dennipluci-20&#038;o=1&#038;p=8&#038;l=as1&#038;asins=1449393683&#038;ref=qf_sp_asin_til&#038;fc1=000000&#038;IS2=1&#038;lt1=_blank&#038;m=amazon&#038;lc1=0000FF&#038;bc1=000000&#038;bg1=FFFFFF&#038;f=ifr" style="width:120px;height:240px;" scrolling="no" marginwidth="0" marginheight="0" frameborder="0"></iframe></p>
]]></content:encoded>
			<wfw:commentRss>http://www.dennisplucinik.com/blog/2011/04/06/setting-up-an-amazon-ec2-server-to-run-teamcity/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>Intro to Continuous Integration with TeamCity</title>
		<link>http://www.dennisplucinik.com/blog/2011/04/06/intro-to-continuous-integration-with-teamcity/</link>
		<comments>http://www.dennisplucinik.com/blog/2011/04/06/intro-to-continuous-integration-with-teamcity/#comments</comments>
		<pubDate>Thu, 07 Apr 2011 03:04:02 +0000</pubDate>
		<dc:creator>Dennis Plucinik</dc:creator>
				<category><![CDATA[Hosting]]></category>
		<category><![CDATA[Amazon EC2]]></category>
		<category><![CDATA[CI]]></category>
		<category><![CDATA[TeamCity]]></category>

		<guid isPermaLink="false">http://www.dennisplucinik.com/blog/?p=709</guid>
		<description><![CDATA[In my most recent endeavor, I am redesigning the build process for a new project. I've decided to use Git for source control, TeamCity for CI (Continuous Integration), Amazon EC2 for hosting the CI server, and a MediaTemple Dedicated Virtual &#8230; <a href="http://www.dennisplucinik.com/blog/2011/04/06/intro-to-continuous-integration-with-teamcity/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>In my most recent endeavor, I am redesigning the build process for a new project. I've decided to use <a href="http://git-scm.com/">Git</a> for <a href="http://en.wikipedia.org/wiki/Revision_control">source control</a>, <a href="http://www.jetbrains.com/teamcity/">TeamCity</a> for CI (<a href="http://en.wikipedia.org/wiki/Continuous_integration">Continuous Integration</a>), <a href="http://aws.amazon.com/ec2/">Amazon EC2</a> for hosting the CI server, and a <a href="http://www.mediatemple.net/go/order/?refdom=dennisplucinik.com">MediaTemple</a> Dedicated Virtual server for hosting the production and staging sites.</p>
<p>Though some people may have you believe setting this all up is easy, I can comfortably admit that in my experience it has not been. Hence, the blog posts which will serve to remind me how to get back into this mess should I ever accidentally find my way out.<br />
<span id="more-709"></span></p>
<h2>What This Article Will Cover</h2>
<ul>
<li>What is TeamCity?</li>
<li>Where does it fit in?</li>
<li>Setting up TeamCity</li>
<li>Downloading and installing TeamCity on an Amazon EC2 instance</li>
<li>Configuring TeamCity</li>
</ul>
<h2>What is TeamCity?</h2>
<p>TeamCity is "proprietary continuous-integration server by JetBrains with free professional edition" (Wikipedia). I'm not going to explain what CI is so if you don't know please ask Wikipedia. After having set up Git properly, I found that GitHub has has built in functionality to integrate with TeamCity. Considering my setup goals of having exactly that, my next logical step is to go check out TeamCity. </p>
<p>Honestly, I did not know if TeamCity was a downloadable program meant for local use, a web service, a program meant for server use, etc. Since we've got multiple people on our team, I'd like to keep the amount of local configuration for each member to a minimum. I'd also like to be able to administer this setup and make changes, on the fly without having to bother the other guys. Fortunately, after poking around <del>a lot</del> what I have found out is that TeamCity is capable of doing this. We will do it by installing it on an Amazon EC2 instance (but this is not the only way - you could use your own server.)</p>
<h2>Where does it fit in?</h2>
<p>Here is a diagram of my current project's software stack/architecture. It includes some of what we currently have implemented, as well as everything we'd like to eventually have. You can see where TeamCity fits into the system.<br />
<div id="attachment_717" class="wp-caption aligncenter" style="width: 628px"><img src="http://www.dennisplucinik.com/blog/wp-content/uploads/2011/03/app-layout-4.gif" alt="Figure 1-1 - Our application roadmap" title="Figure 1-1 - Our application roadmap" width="618" height="597" class="size-full wp-image-717" /><p class="wp-caption-text">Figure 1-1 - Our application roadmap</p></div></p>
<p>Basically TeamCity listens to your Git repository for changes. As soon as a push occurs on Git, TeamCity spins up (another) Amazon EC2 instance, then the TeamCity build agent starts up and fires off some <a href="http://maven.apache.org/">Maven</a> commands. These commands will sequentially kick off the following general functions:</p>
<ol>
<li>Validate and compile JavaScript</li>
<li>Run unit tests on JavaScript and PHP</li>
<li>Run integration tests in Selenium</li>
<li>If everything passes, kick off a build into production</li>
</ol>
<p>
I will likely go into thorough detail on each of these steps in a future post since as with everything else, I tend to forget which process I went through.</p>
<h2>Setting up TeamCity</h2>
<p>Since TeamCity is an application you download, you'll need a machine to run it on. Either you can run it on your local machine, or set it up on a public web server like Amazon EC2 (which is what we're going to do). Read this post on <a href="http://www.dennisplucinik.com/blog/2011/04/06/setting-up-an-amazon-ec2-server-to-run-teamcity/">Setting up an Amazon EC2 Server to Run TeamCity</a> if you do not already have it set up.</p>
<h2 id="DownloadAndInstallTeamCity">Downloading and installing TeamCity on an Amazon EC2 instance</h2>
<p>This is where I got stuck. Basically I didn't know how to download a file from the command line in Linux. I knew I could click a link from a browser and then execute the file that way. I just didn't have this one critical piece of information. In case you are in the same 0.01 percent of the population as I was, the solution is a command called "wget". I don't know why I never knew it. I just didn't (I even saw the Social Network.)</p>
<p>Now that I've forked over that embarrassing little nugget, let's just get to it already. </p>
<p>Type this into your command line:</p>
<pre>wget http://download.jetbrains.com/teamcity/TeamCity-6.0.3.tar.gz</pre>
<p>Provided you haven't navigated yourself into a restricted folder before you pressed Enter, this should work without issue.  </p>
<p>To install the instance, next we need to unpack the download. Type this into your command line and press Enter:</p>
<pre>tar -xvzf TeamCity-6.0.3.tar.gz</pre>
<p>Note about the "-xvzf" (all lowercase) parameters:</p>
<ul>
<li>x means "extract files from an archive". This is required because a .tar file is an archive.</li>
<li>v means "verbosely list files processed". It's not necessary but will give you a better understanding of what changes are being made.</li>
<li>z means "filter the archive through gzip". This is required because the .gz indicates this file has been compressed using gzip, and so needs to be decompressed using gzip.</li>
<li>f means "force-local" or "archive file is local even if it has a colon". I can only imagine this prevents some bad stuff from happening. Honestly though IDK.</li>
</ul>
<p>If everything went as planned, you will have see a bunch of text flying by for a few seconds, and then you should see a quiet little command line. The unpacking process should have created a new folder on your machine called TeamCity. What we have now is an application installed which is only waiting to be started so we can access it from a web browser. To do just this, type the following into the command line and press Enter:</p>
<pre>cd TeamCity
bin/teamcity-server.sh start</pre>
<p>Unfortunately I ran into some very weird problems at this point (which have since been resolved) related to my webserver access configuration which apparently was preventing me from accessing my TeamCity web interface. I may update this post with that information if enough people tell me they have the same problem. I don't think my problem was a fluke considering everything (even the EC2 instance) was a fresh install. So in the spirit of moving on (sorry) I'm going to assume you did not run into the same problems as me here. If in fact you did not have problems, then you should be able to simply access your new TeamCity install by following the link provided by Amazon for your EC2 server + "/TeamCity" (See this post: <a href="http://www.dennisplucinik.com/blog/2011/04/06/setting-up-an-amazon-ec2-server-to-run-teamcity/#attachment_751">Figure 2-11 - Connect Help - Secure Shell (SSH)</a>). Please let me know in the comments if you get hung up here and I will be happy to dig up the details and elaborate.</p>
<h2>Configuring TeamCity</h2>
<p>Now that you have an EC2 instance running which you have installed and can access your TeamCity server, you will need to configure it to do the interesting stuff that we described above.</p>
<p>Since I believe this topic warrants it's own post, I <del>have done just that. Please read: [link removed]</del> ...I'm still working on this part.</p>
<h2>In closing</h2>
<p>Hopefully this has provided you with some helpful info. If you've got any questions please drop them in the comments below. They're more likely to get answered there either by me or someone else as this is a fairly highly trafficked blog.</p>
<p>Thanks for reading!</p>
<h3>Helpful Articles</h3>
<p><a href="http://www.dennisplucinik.com/blog/2011/04/06/setting-up-an-amazon-ec2-server-to-run-teamcity/">http://www.dennisplucinik.com/blog/2011/04/06/setting-up-an-amazon-ec2-server-to-run-teamcity/</a></p>
<p><a href="http://www.modelmetrics.com/wp-content/uploads/2011/01/Teamcity-install.pdf">http://www.modelmetrics.com/wp-content/uploads/2011/01/Teamcity-install.pdf</a><br />
<a href="http://confluence.jetbrains.net/display/TCD65/Setting+Up+TeamCity+for+Amazon+EC2">http://confluence.jetbrains.net/display/TCD65/Setting+Up+TeamCity+for+Amazon+EC2</a></p>
<p>//<a href="http://osherove.com/blog/2010/5/31/running-teamcity-from-amazon-ec2-cloud-based-scalable-build.html">http://osherove.com/blog/2010/5/31/running-teamcity-from-amazon-ec2-cloud-based-scalable-build.html</a></p>
<h3>Related Books</h3>
<p class="amazonBook"><iframe src="http://rcm.amazon.com/e/cm?t=dennipluci-20&#038;o=1&#038;p=8&#038;l=as1&#038;asins=0321336380&#038;ref=qf_sp_asin_til&#038;fc1=000000&#038;IS2=1&#038;lt1=_blank&#038;m=amazon&#038;lc1=0000FF&#038;bc1=000000&#038;bg1=FFFFFF&#038;f=ifr" style="width:120px;height:240px;" scrolling="no" marginwidth="0" marginheight="0" frameborder="0"></iframe>
</p>
<p class="amazonBook"><iframe src="http://rcm.amazon.com/e/cm?t=dennipluci-20&#038;o=1&#038;p=8&#038;l=as1&#038;asins=0974514047&#038;ref=qf_sp_asin_til&#038;fc1=000000&#038;IS2=1&#038;lt1=_blank&#038;m=amazon&#038;lc1=0000FF&#038;bc1=000000&#038;bg1=FFFFFF&#038;f=ifr" style="width:120px;height:240px;" scrolling="no" marginwidth="0" marginheight="0" frameborder="0"></iframe>
</p>
<p class="amazonBook"><iframe src="http://rcm.amazon.com/e/cm?t=dennipluci-20&#038;o=1&#038;p=8&#038;l=as1&#038;asins=0974514039&#038;ref=qf_sp_asin_til&#038;fc1=000000&#038;IS2=1&#038;lt1=_blank&#038;m=amazon&#038;lc1=0000FF&#038;bc1=000000&#038;bg1=FFFFFF&#038;f=ifr" style="width:120px;height:240px;" scrolling="no" marginwidth="0" marginheight="0" frameborder="0"></iframe>
</p>
<p class="amazonBook"><iframe src="http://rcm.amazon.com/e/cm?t=dennipluci-20&#038;o=1&#038;p=8&#038;l=as1&#038;asins=0321146530&#038;ref=qf_sp_asin_til&#038;fc1=000000&#038;IS2=1&#038;lt1=_blank&#038;m=amazon&#038;lc1=0000FF&#038;bc1=000000&#038;bg1=FFFFFF&#038;f=ifr" style="width:120px;height:240px;" scrolling="no" marginwidth="0" marginheight="0" frameborder="0"></iframe></p>
]]></content:encoded>
			<wfw:commentRss>http://www.dennisplucinik.com/blog/2011/04/06/intro-to-continuous-integration-with-teamcity/feed/</wfw:commentRss>
		<slash:comments>9</slash:comments>
		</item>
		<item>
		<title>&#8220;Pay Whatever and Download&#8221; jQuery Plugin</title>
		<link>http://www.dennisplucinik.com/blog/2011/04/03/jquery-pay-whatever-and-download/</link>
		<comments>http://www.dennisplucinik.com/blog/2011/04/03/jquery-pay-whatever-and-download/#comments</comments>
		<pubDate>Mon, 04 Apr 2011 03:06:36 +0000</pubDate>
		<dc:creator>Dennis Plucinik</dc:creator>
				<category><![CDATA[Coding]]></category>
		<category><![CDATA[jQuery]]></category>
		<category><![CDATA[PayPal]]></category>
		<category><![CDATA[plugins]]></category>

		<guid isPermaLink="false">http://www.dennisplucinik.com/blog/?p=813</guid>
		<description><![CDATA[Today I want to release my very first jQuery plugin. Actually I'm not going to post it officially to jQuery's plugin repo yet. I just want to get it out there small-time so I have a chance to tweak it &#8230; <a href="http://www.dennisplucinik.com/blog/2011/04/03/jquery-pay-whatever-and-download/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Today I want to release my very first jQuery plugin. Actually I'm not going to post it officially to jQuery's plugin repo yet. I just want to get it out there small-time so I have a chance to tweak it a bit before going all spotlights and ammunition over on jQuery's site. With my recent return to blogging regularly, I have been thinking of different types of interesting content to create like PSDs, or ebooks, etc... content that will take a lot of time to produce. So I thought of this plugin for one simple reason: Creating content takes time, and for those readers who appreciate that content enough to flip me a buck for it, I say - why not do it in style?</p>
<p><span id="more-813"></span></p>
<p>Seriously though, I think this plugin presents a good model. It basically allows you to put your file download link behind one extra click while presenting a super simple form for the reader to optionally pop you a dollar via PayPal. (Having something like Amazon's one-click here would be so money... literally). Hopefully this doesn't piss off too many freeloaders. In any case you can plan on seeing it on every one of my posts that include a download going forward.</p>
<h2>Code</h2>
<p>This plugin is simply implemented by calling:</p>
<pre>$(containerSelector).payWhateverAndDownload({
    fileURL: "http://www.yourdomain.com/whateverFileURL.zip",
    paypalID: "you@youremail.com"
});</pre>
<p>Those are the only two properties the plugin needs to run. Everything else has a default however, you can override most things - see the <em>"API"</em> section below.</p>
<h2>Screenshot</h2>
<p>Figure 1-1 shows what it looks like using the defaults.</p>
<img src="http://www.dennisplucinik.com/blog/wp-content/uploads/2011/04/screenshot.gif" alt="Figure 1-1 - "Pay Whatever and Download" jQuery Plugin" title="Figure 1-1 - "Pay Whatever and Download" jQuery Plugin" width="456" height="281" class="size-full wp-image-814" />
<h2>API</h2>
<p>Here's my informal API just to highlight that I've abstracted a bunch of things you can override such as:</p>
<ul>
<li>amount label (e.g., "pay any amount")</li>
<li>button color one</li>
<li>button color two</li>
<li>donation amount</li>
<li>currency (symbol)</li>
<li>PayPal currency code</li>
<li>file URL</li>
<li>button one text (e.g., "Pay whatever you want and download"</li>
<li>button two text (e.g., "Click to download")</li>
<li>PayPal ID</li>
</ul>
<p>I've also coded in a bunch of CSS3 styles but you can override them by sending in a "stylesheet" property in the args object set to a blank space. It is visible but not pretty in IE.</p>
<p>Also, there are some callbacks you can insert into the args object for each important event such as:</p>
<ul>
<li>after init</li>
<li>before init</li>
<li>first button clicked</li>
<li>download button clicked</li>
<li>donate button clicked</li>
</ul>
<p>That about sums it up without going into any more detail about the plugin API. If you're really interested you can just read the code, it's pretty straightforward IMO. So without further ado, I give you a live example of this plugin in action.</p>
<div id="dowloadPlugin">
<h3>Download the plugin!</h3>
</div>
<p><script src="http://www.dennisplucinik.com/blog/wp-content/themes/DennisPlucinik/scripts/jquery.js"></script><br />
<script src="http://www.dennisplucinik.com/blog/wp-content/themes/DennisPlucinik/scripts/jquery-paywhateveranddownload.js"></script><br />
<script>
$('#dowloadPlugin').payWhateverAndDownload({
fileURL:'http://www.dennisplucinik.com/blog/wp-content/uploads/2011/04/PayWhateverAndDownload.rar',
paypalID:'dennis@dennisplucinik.com'
});
</script></p>
]]></content:encoded>
			<wfw:commentRss>http://www.dennisplucinik.com/blog/2011/04/03/jquery-pay-whatever-and-download/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
	</channel>
</rss>

