<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type="text/xsl" media="screen" href="/~d/styles/rss2full.xsl"?><?xml-stylesheet type="text/css" media="screen" href="http://feeds.feedburner.com/~d/styles/itemcontent.css"?><rss 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/" version="2.0">

<channel>
	<title>Michael P. Gilbert</title>
	
	<link>http://www.mpgilbert.com</link>
	<description>Responsive Front-end Web Developer</description>
	<lastBuildDate>Sun, 19 May 2013 03:53:16 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.5.1</generator>
		<atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="self" type="application/rss+xml" href="http://feeds.feedburner.com/mpgilbert" /><feedburner:info xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0" uri="mpgilbert" /><atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="hub" href="http://pubsubhubbub.appspot.com/" /><item>
		<title>Mobile-First Responsive Web Design</title>
		<link>http://www.mpgilbert.com/mobile-first-responsive-web-design</link>
		<comments>http://www.mpgilbert.com/mobile-first-responsive-web-design#comments</comments>
		<pubDate>Sun, 05 May 2013 21:10:39 +0000</pubDate>
		<dc:creator>michael</dc:creator>
				<category><![CDATA[Responsive Web Design]]></category>

		<guid isPermaLink="false">http://www.mpgilbert.com/?p=1077</guid>
		<description><![CDATA[This is the third article in a series that I was asked to write for work. The previous articles discussed the changes in workflow and some of the technical ingredients of responsive web design. In this final article, we dive a bit deeper and discuss some more advanced techniques in order to optimize a website [...]]]></description>
				<content:encoded><![CDATA[<p><img src="http://www.mpgilbert.com/wp-content/uploads/rwd-mobile-first.jpg" alt="" class="alignright">
<p>This is the third article in a series that I was asked to write for work. The previous articles discussed the <a href="/five-stages-of-responsive-web-design/">changes in workflow</a> and some of the <a href="/responsive-web-design-the-basics/">technical ingredients</a> of responsive web design. In this final article, we dive a bit deeper and discuss some more advanced techniques in order to optimize a website for mobile performance as well as legacy browser support.</p>
<p><span id="more-1077"></span></p>
<hr />
<p>We previously wrote about changes in workflow and basic techniques of responsive web design, so now let&#8217;s dive into something more challenging: optimizing website performance for mobile. While we&#8217;re adding complexity, let&#8217;s go ahead and add a dash of legacy browser support as well. This may seem like an odd mix of requirements, but let&#8217;s face it: Sometimes we find ourselves in a position where we have to simultaneously forge ahead with modern technologies while ensuring that we don&#8217;t forget about site visitors with less capable browsers.</p>
<p>To demonstrate some handy mobile-first methods, we&#8217;ll be referencing techniques used on the <a href="http://mediamultiplyer.com/" target="_blank">Media Multiplyer</a> site. It&#8217;s a fairly small site (only a few pages), but it was a perfect opportunity to explore experimental front-end development techniques.</p>
<h3>Luckily we&#8217;re not alone</h3>
<p>One of my favorite things about the web development industry is the wonderfully open community of developers who are willing to share their knowledge and expertise. Brad Frost is one of those generous and impressively talented developers. He has written extensively on the subject of mobile and responsive web design, and his expertly curated collection of <a href="http://bradfrost.github.com/this-is-responsive/patterns.html" target="_blank">responsive patterns</a> is an excellent resource to which I often refer. He&#8217;s also written an article, &#8220;<a href="http://www.html5rocks.com/en/mobile/responsivedesign/" target="_blank">Creating a Mobile-First Responsive Web Design</a>,&#8221; that I consider a great primer on mobile-first techniques that we can use in our work today.</p>
<p>I was already excited about responsive web design, but admittedly I had certain reservations about performance on mobile devices. For instance, if we build a site that looks and works great on our large desktop monitors with high-speed local area networks, how will that same site perform on phone screens with a significantly slower data connection? In Brad&#8217;s article, he references Luke Wroblewski&#8217;s concept of <a href="http://www.lukew.com/ff/entry.asp?933" target="_blank">mobile first</a>, which encourages teams to &#8220;focus on only the most important data and actions&#8221; in an application. In other words, consider small screens first and concentrate on what&#8217;s really important for the user: easily accessing high-quality content.</p>
<p>Brad&#8217;s mobile-first technique starts by including two style sheets: a <em>basic</em> style sheet that gets downloaded on all devices, and an <em>enhanced</em> style sheet that only gets downloaded on tablets and larger screens. The basic style sheet has colors, typography, and minimal layout styles—the stuff that looks good on a small screen. The enhanced style sheet does heavy lifting by layering on more complex styles for layout, flexible grids, large background images, etc.</p>
<p>The advantage of this technique is that small-screen mobile devices will only download what&#8217;s included in the basic style sheet. Larger screen devices, such as tablets, laptops and desktop computers will benefit from both style sheets.</p>
<h3>Don&#8217;t tell me. Show me.</h3>
<p>Let&#8217;s take it one step at a time and go through the Media Multiplyer site code together. The first thing we need to do is set the screen width to the actual width of the device using the <em>meta viewport</em> tag. This will start the process of optimizing our site for a mobile experience.</p>
<pre><code class="language-markup">&lt;meta name="viewport"
   content="width=device-width, initial-scale=1.0"&gt;
</code></pre>
<p>We&#8217;re accomplishing two things: We&#8217;re setting the viewport width to the width of the device as well as setting the zoom level to 100% (that&#8217;s the 1.0 part at the end). It&#8217;s important to note that we&#8217;re <em>not</em> disabling the user&#8217;s ability to zoom the page itself by adding &#8220;maximum-scale=1&#8243; or &#8220;user-scalable=no&#8221; properties. You may have seen these in the wild before. Or you may have run across sites on your mobile device that didn&#8217;t allow you to zoom in and wondered why. With our simplified <em>meta viewport</em> tag, the user will still be able to pinch-to-zoom to take a closer look at the images, text and other content.</p>
<p>The next step is to include both style sheets. We link the basic style sheet as usual:</p>
<pre><code class="language-markup">&lt;link rel="stylesheet" href="basic.css"
   media="screen, handheld"&gt;</code></pre>
<p>&hellip;and then we link the enhanced style sheet using a clever media query trick:</p>
<pre><code class="language-markup">&lt;link rel="stylesheet" href="enhanced.css"
   media="screen and (min-width: 40em)"&gt;</code></pre>
<p>We&#8217;re downloading the enhanced.css file, but also adding a media query attribute that specifies a minimum screen width, preventing it from getting downloaded on small screens. So, in turn, any large background images or other assets specified in the enhanced style sheet won&#8217;t get downloaded either.</p>
<p>You may also have noticed that we&#8217;re specifying the &#8220;min-width&#8221; media query with an <em>em</em>-based instead of <em>px</em>-based unit of measurement. This will create a <a href="http://blog.cloudfour.com/the-ems-have-it-proportional-media-queries-ftw/" target="_blank">proportional media query</a> that will help users who have used the zoom feature in their browser to increase text size, etc. In our example, a media query of 40em is calculated with the following simple formula:</p>
<pre><code class="language-markup">640px target ÷ 16px context = 40em result</code></pre>
<p>In other words, a 40em &#8220;min-width&#8221; media query is roughly equivalent to 640px, assuming a baseline font size of 16px.</p>
<p>The other important thing to note is the use of a &#8220;min-width&#8221; instead of &#8220;max-width&#8221; media query. If we used a &#8220;max-width&#8221; media query, the enhanced.css file would also download on devices with small screens. We&#8217;re going to continue that trend of using &#8220;min-width&#8221; media queries in our enhanced.css file as we <a href="http://en.wikipedia.org/wiki/Progressive_enhancement" target="_blank">progressively enhance</a> our styles for larger screens. So, for instance, we could add a media query like the following:</p>
<pre><code class="language-css">h2 {
    font-size: 21px;
}

@media all and (min-width: 52em) {
    h2 {
        font-size: 24px;
    }
}
</code></pre>
<p>In this example, the font size for our <em>h2</em> elements will be 21px by default and 24px for everything with a screen width larger than 52em (about 832px).</p>
<p>We can even change the layout from two columns to four columns:</p>
<pre><code class="language-css">.column {
    width: 50%;
}

@media all and (min-width: 48em) {
    .column {
        width: 25%;
    }
}
</code></pre>
<p>Of course, there&#8217;s just one small catch in our plan: Our original media query attribute is not supported by Internet Explorer 8 since it doesn&#8217;t support CSS3 media queries. So site visitors browsing our site with IE 8 will only get the basic styles. This could be a problem because we need to support IE 8 in our project, so what can we do?</p>
<h3>Consider the options</h3>
<p>On the subject of support for IE 8, there are a few options to consider:</p>
<ol>
<li>Do we simply ignore IE 8 since we&#8217;re concentrating on &#8220;emerging technologies&#8221; for our site?</li>
<li>Do we accept the fact that IE 8 will get a basic yet functional experience compared to modern browsers?</li>
<li>Can we somehow enable IE 8 to take advantage of our enhanced style sheet?</li>
</ol>
<p>Admittedly, the first option is probably not a practical solution. Internet Explorer 8 usage still represents a significant proportion of the overall browser market, so it&#8217;s important not to ignore it.</p>
<p>While the second option is better, we can go one step further.</p>
<p>Another option to consider is redundantly referencing the enhanced style sheet for IE 8 only. This creates an additional server request, but that shouldn&#8217;t be a big deal since we&#8217;re restricting it to non-mobile devices. Here&#8217;s how to achieve that:</p>
<pre><code class="language-markup">&lt;!--[if (lt IE 9) &amp; (!IEMobile)]&gt;
&lt;link rel="stylesheet" href="enhanced.css"&gt;
&lt;![endif]--&gt;
</code></pre>
<p>So now non-mobile IE 8 devices will download the enhanced style sheet and all is good, right? Well, not quite yet. Our enhanced.css file will naturally contain media queries too, so we&#8217;ll need to add some CSS rules specifically for IE 8 to fully cover our bases.</p>
<p>If we wrap the <em>html</em> element in a conditional comment, we can conveniently add a class for IE 8:</p>
<pre><code class="language-markup">&lt;!--[if IE 8 ]&gt; &lt;html lang="en-US" class="ie8"&gt; &lt;![endif]--&gt;</code></pre>
<p>Now we can duplicate the media queries we&#8217;ve added in enhanced.css and target IE 8 with a CSS rule of its own. For example, we could add a CSS rule like this:</p>
<pre><code class="language-css">.ie8 h2 {
    font-size: 24px;
}
</code></pre>
<h3>Fine-tune the details</h3>
<p>Using this method, we can go through the enhanced.css file and make sure that IE 8 will get the same (or at least similar) styles as all the modern browsers. We don&#8217;t necessarily need to duplicate every single style included in the media queries. None of the fun CSS3 features, like rounded corners, box shadows and gradients will be available to IE 8, so there&#8217;s no need to include them. But we can tailor the experience for IE 8 to include the important elements like layout, background images and font sizes.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.mpgilbert.com/mobile-first-responsive-web-design/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Responsive Web Design – The Basics</title>
		<link>http://www.mpgilbert.com/responsive-web-design-the-basics</link>
		<comments>http://www.mpgilbert.com/responsive-web-design-the-basics#comments</comments>
		<pubDate>Sun, 05 May 2013 21:07:56 +0000</pubDate>
		<dc:creator>michael</dc:creator>
				<category><![CDATA[Responsive Web Design]]></category>

		<guid isPermaLink="false">http://www.mpgilbert.com/?p=1073</guid>
		<description><![CDATA[This is the second blog article that I was recently asked to write for work. In the first article, we discussed how responsive web design can require changes in workflow and strategy. This one is a beginner&#8217;s guide to responsive web design where we briefly discuss each of the three technical ingredients. In Ethan Marcotte&#8217;s [...]]]></description>
				<content:encoded><![CDATA[<p><img src="http://www.mpgilbert.com/wp-content/uploads/rwd-basics.jpg" alt="" class="alignright">
<p>This is the second blog article that I was recently asked to write for work. In the <a href="http://www.mpgilbert.com/five-stages-of-responsive-web-design/">first article</a>, we discussed how responsive web design can require changes in workflow and strategy. This one is a beginner&#8217;s guide to responsive web design where we briefly discuss each of the three technical ingredients.</p>
<p><span id="more-1073"></span></p>
<hr />
<p>In Ethan Marcotte&#8217;s <a href="http://alistapart.com/article/responsive-web-design" target="_blank">groundbreaking article</a> published on the blog <em>A List Apart</em>, he helped us think about the web in a more flexible way, where the display of  all-important content can adapt to the capabilities of  devices instead of being boxed in by fixed-width, inflexible layouts. Let&#8217;s take a look at each of Ethan&#8217;s three original technical ingredients and see what they can do for us.</p>
<h3>Fluid grids</h3>
<p>In the beginning (well, in web terms anyway), all websites were responsive. You might remember the early days of the web as fondly as I do. Everything was exciting and new. It was also very simple compared to today&#8217;s web. We authored plain old semantic HTML, sprinkled in a few decorative images and released it to the world. We weren&#8217;t concerned with locking things down, so consequently our page layouts naturally flexed and breathed as needed.</p>
<p>Somewhere along the line we started using HTML tables and spacer graphics to turn all the random chaos into beautifully ordered web pages. But tables were intended for tabular data (like a spreadsheet), not for layout and presentation. So we converted our table-based code to more web standards-centric CSS layouts. This was more &#8220;responsible&#8221; and allowed us to separate structure from presentation. We felt like we were doing the &#8220;right thing&#8221; once again. But we were still locking things down with non-flexible pixel-based layouts. What happened to our beloved flexibility?</p>
<p>If we want our content to be adaptive, we need to convert those pixels to percentages so that our layouts can stretch and contract when the browser viewport changes (as viewed on small screens, tablets, and so forth). In our CSS file we need to change things like this:</p>
<pre><code class="language-css">.main {
    float: left;
    width: 660px;
    margin-right: 20px;
}
</code></pre>
<p>into something like this:</p>
<pre><code class="language-css">.main {
    float: left;
    width: 68.75%;
    margin-right: 2%;
}
</code></pre>
<p>In this simple example, I&#8217;m assuming the overall layout width, as viewed on a desktop browser, is 960 pixels. By using Ethan&#8217;s simple <a href="http://alistapart.com/article/fluidgrids" target="_blank">fluid grid formula</a>, we divide the <strong>target</strong> width (660 pixels) by the <strong>context</strong> (960 pixels) to provide our percentage <strong>result</strong> (68.75%). Here&#8217;s the simple formula:</p>
<pre><code class="language-css">target ÷ context = result
</code></pre>
<p>This is a tough concept to describe in words, so let&#8217;s take a peek at Ethan&#8217;s original <a href="http://d.alistapart.com/responsive-web-design/ex/ex-site-FINAL.html" target="_blank">responsive demo website</a>. Go check out his website and resize your browser by slowly dragging the right edge toward the left so that it collapses to a tall, narrow viewport. This will approximate what it&#8217;s like to view the website on a bunch of devices with a variety of screen widths. It&#8217;s not exactly the same, but it demonstrates the concept visually and that&#8217;s good for our purposes here.</p>
<p>No, really: go ahead and <a href="http://alistapart.com/article/responsive-web-design" target="_blank">take a look</a>. I&#8217;ll wait until you get back.</p>
<p>See what I mean? Did you see how the design responds and adapts to the width of the browser window as the available viewing space changed? This is one of the most powerful aspects of responsive web design. Not only can we linearize the content (stack it from top to bottom), but we can also optimize our layout for a variety of device sizes and capabilities. It’s important to remember that we’re changing the presentation of the content, not the foundational markup itself. Under the hood it&#8217;s the same HTML code, but the layout changes shape and the images shrink and expand as needed. Speaking of images, let&#8217;s move on to our next responsive web design ingredient.</p>
<h3>Flexible images</h3>
<p>So now our layout is fluid and flexible. How do we get those pesky images to flex with the rest of the content? We need to allow the images to shrink while retaining their original proportions. Again, we turn to CSS and add the following rule for our <strong>image</strong> tags:</p>
<pre><code class="language-css">img {
    max-width: 100%;
    height: auto;
}
</code></pre>
<p>Well that wasn&#8217;t too difficult. One more thing before we&#8217;re finished with our flexible images. We need to remove the <strong>width</strong> and <strong>height</strong> attributes from our image tags, which leaves us with:</p>
<pre><code class="language-css">&lt;img src="monkey.jpg" alt="image description"&gt;
</code></pre>
<p>Nice and simple. Now our images will proportionately shrink down as the available screen width decreases. An important point to keep in mind: it&#8217;s <em>not</em> a good idea to <em>increase</em> the dimensions of an image (i.e., start with a small image and stretch it bigger), so we&#8217;ll need to create our graphics the right size for the desktop layout and let CSS do the job of shrinking them down as needed. Keep in mind that these large images might be accessed on a mobile phone with a slow connection, so it&#8217;s still a good idea to compress and size them as you would normally.</p>
<p>We still need a way to make some minor layout adjustments from time to time, which brings us to our third and final responsive web design ingredient.</p>
<h3>Media queries</h3>
<p>Actually, one of the components of media queries, called <em>media types</em>, has been around for a while. Have you heard of a &#8220;printer&#8221; style sheet? That&#8217;s when the developer creates CSS rules that are only used when a web page is printed. The screen ignores them, but the printer uses them to format the content for a printed page.</p>
<p>With responsive web design, we can also query the browser for things like minimum and maximum width, device type and  other useful features. If we decide that the content in our large-screen, three-column layout gets too tall and narrow on small screens, we can use media queries to make adjustments. We can also change things like background images, colors, font styling and  more. Here&#8217;s a simple media query that changes the background color as the viewport increases:</p>
<pre><code class="language-css">.container {
    background-color: blue;
    color: white;
}

@media screen and (min-width: 480px) {
    .container {
        background-color: red;
    }
}

@media screen and (min-width: 960px) {
    .container {
        background-color: green;
    }
}
</code></pre>
<p>Do you see how that works? On a small smartphone screen, the container&#8217;s background color would be <strong>blue</strong>. On a medium tablet screen, it would be <strong>red</strong>. And on a large desktop computer, it would be <strong>green</strong>. If you were to resize your browser you&#8217;d see each in turn as the screen size changed.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.mpgilbert.com/responsive-web-design-the-basics/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>The Five Stages of Responsive Web Design</title>
		<link>http://www.mpgilbert.com/five-stages-of-responsive-web-design</link>
		<comments>http://www.mpgilbert.com/five-stages-of-responsive-web-design#comments</comments>
		<pubDate>Sun, 05 May 2013 21:05:21 +0000</pubDate>
		<dc:creator>michael</dc:creator>
				<category><![CDATA[Responsive Web Design]]></category>

		<guid isPermaLink="false">http://www.mpgilbert.com/?p=1071</guid>
		<description><![CDATA[I was recently asked to write a blog article on responsive web design at work. I immediately agreed to write the article, but I struggled a bit when I sat down to actually write it. So I broke it into three articles: a gentle introduction, a beginner&#8217;s guide, and an advanced topic. This is the [...]]]></description>
				<content:encoded><![CDATA[<p><img src="http://www.mpgilbert.com/wp-content/uploads/rwd-five-stages.jpg" alt="" class="alignright">
<p>I was recently asked to write a blog article on responsive web design at work. I immediately agreed to write the article, but I struggled a bit when I sat down to actually write it. So I broke it into three articles: a gentle introduction, a beginner&#8217;s guide, and an advanced topic. This is the first article that I wrote. It deals with my personal struggle to wrap my brain around how this whole responsive web design thing was going to fit into my development world.</p>
<p><span id="more-1071"></span></p>
<hr />
<p>For the past 15 years or so I&#8217;ve made a living building carefully handcrafted, pixel-precise websites. I&#8217;ve absolutely loved the challenge of tackling even the most daunting visual designs handed to me by talented web designers. You know the kind of websites I&#8217;m referring to&hellip;. They look more like a printed work of art and less like a simple word-processed document with text and decorative clip art. Irregular column widths, multiple overlapping graphics, endless variation from one page to the next, all wrapped in a fly-out navigation structure three levels deep—and it needs to look the same in a dozen browsers. No problem&hellip; how soon can I start?</p>
<p>After finishing a particularly difficult website build, I secretly enjoy hearing the comforting praise from a designer who marvels at how my web page looks &#8220;exactly like the original Photoshop comp.&#8221; I also like the occasional, &#8220;Wow, is that the comp or the HTML?&#8221;</p>
<h3>Learning to let go</h3>
<p>A few years ago I realized those same fixed-width, tightly controlled layouts were increasingly difficult to &#8220;get just right&#8221; in the quickly expanding universe of mobile devices and user contexts. And it wasn&#8217;t because Internet Explorer couldn&#8217;t quite keep up with Chrome and Firefox (but, let&#8217;s face it—that was also true). Almost overnight those clever works of visual design and code were being viewed on tiny phones, tablets of all sizes, small laptops and smaller netbooks&hellip; and even huge TV screens via game console browsers.</p>
<p>I just couldn&#8217;t keep up. I felt like I had lost control. I felt angry and frustrated. I briefly considered other career options. Surely there&#8217;s got to be a better way! At about this same time, I read Ethan Marcotte&#8217;s <a href="http://www.alistapart.com/articles/responsive-web-design/" target="_blank">original responsive web design article</a> published on <em>A List Apart</em>. But honestly, I was having a really tough time getting a grip on this new way of thinking. It was like I was going through the <a href="http://en.wikipedia.org/wiki/K%C3%BCbler-Ross_model" target="_blank">five stages of grief</a>:</p>
<ul>
<li><strong>Denial:</strong> &#8220;Surely this will never work. It will go away if I just ignore it.&#8221;</li>
<li><strong>Anger:</strong> &#8220;I&#8217;m not giving up pixel-precise control! That&#8217;s my specialty!&#8221;</li>
<li><strong>Bargaining:</strong> &#8220;We&#8217;ll make minor adjustments so that it looks good on tablets. We can build a separate mobile site for the rest.&#8221;</li>
<li><strong>Depression:</strong> &#8220;I don&#8217;t want to go through this again. I already gave up table-based layouts.&#8221;</li>
<li><strong>Acceptance:</strong> &#8220;Hey, maybe this could work after all. I&#8217;ll try it out and see what happens.&#8221;</li>
</ul>
<p>I had enjoyed Ethan&#8217;s presentations at a couple of web design conferences and was immediately impressed with his quiet confidence and broad knowledge of, well&hellip; pretty much all things web. I was also more than a little intimidated by the fact that he can do so many things so well. He&#8217;s an accomplished conference speaker, published author, web designer and front-end developer. Those last two skills, designer and developer, are key to this whole thing working because responsive web design (RWD) requires true collaboration between the web designer and the front-end developer. Ethan can do both&hellip; which must be a big advantage.</p>
<h3>Let the healing begin</h3>
<p>But in my world, I could see this might be problematic. How is this going to work in a typical agency workflow where someone else creates the design, and I write the code while they move on to another project? The truth is, it probably won&#8217;t work like that&hellip; at least not without some changes to our processes and mental models of how we think about and ultimately design for the web. With RWD we&#8217;ll need more collaboration during the design and development phases of the project to allow minor course corrections along the way. We&#8217;ll need to rely less on static Photoshop comps and perhaps even start to <a href="http://www.netmagazine.com/opinions/designing-browser" target="_blank">design in the browser</a>. We&#8217;ll need to try things out in the browser to see what parts of the design work and what needs slight modifications in order to be more flexible.</p>
<p>In Ethan&#8217;s original <em>A List Apart</em> article, while borrowing from the field of architecture, he challenged us to embrace the inherent flexibility of the web. Move with the ebb and flow, as it were. Instead of building a single device-specific display of our website, we should create a &#8220;flexible foundation&#8221; in which the content can adapt to the capabilities—and limitations—of the vast array of devices available today and in the future. His original RWD recipe includes the following three technical ingredients:</p>
<ol>
<li>Fluid grids</li>
<li>Flexible images</li>
<li>Media queries</li>
</ol>
<h3>How does that make you feel?</h3>
<p>About now, maybe you&#8217;re feeling some of the same anxiety I initially felt about RWD. Well, I&#8217;m here to tell you it&#8217;s OK. Lately I&#8217;ve discovered that it&#8217;s more of a journey than a destination. It&#8217;s simply a method of designing and building websites, and there are a lot of things to consider. We&#8217;re still trying to figure out how to make it all work. And like most things, there&#8217;s no single right way to do it. So we&#8217;ll take it one step at a time and experience it together.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.mpgilbert.com/five-stages-of-responsive-web-design/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>I Aspire to Be a Web Craftsman</title>
		<link>http://www.mpgilbert.com/i-aspire-to-be-a-web-craftsman</link>
		<comments>http://www.mpgilbert.com/i-aspire-to-be-a-web-craftsman#comments</comments>
		<pubDate>Sat, 02 Feb 2013 22:18:58 +0000</pubDate>
		<dc:creator>michael</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[Web Standards]]></category>

		<guid isPermaLink="false">http://www.mpgilbert.com/?p=1010</guid>
		<description><![CDATA[The other day I saw some front-end code that just plain angered me. I wasn&#8217;t upset that the website looked bad in the browser or that it wasn&#8217;t faithful to the original visual design. It was just poorly executed. It lacked semantics, clarity, and direction. It seemed obvious that the developer simply mailed it in. [...]]]></description>
				<content:encoded><![CDATA[<p><img src="http://www.mpgilbert.com/wp-content/uploads/on-being-a-web-craftsman.jpg" alt="I Aspire to Be a Web Craftsman" title="" class="alignright"></p>
<p>The other day I saw some front-end code that just plain angered me. I wasn&#8217;t upset that the website looked bad in the browser or that it wasn&#8217;t faithful to the original visual design. It was just poorly executed. It lacked semantics, clarity, and direction. It seemed obvious that the developer simply mailed it in. That experience compelled me to write a few words about craftsmanship and good old fashioned pride in one&#8217;s work.</p>
<p><span id="more-1010"></span></p>
<p>As I sat down to write about this subject I decided early on that I&#8217;d take a positive approach in hopes of inspiring others instead of pointing fingers at a bad example (which is why I&#8217;m <em>not</em> including a link to the bad code in question). So I searched the web using keywords like &#8220;handmade websites,&#8221; &#8220;beautiful code,&#8221; and &#8220;web craftsman&#8221; in hopes of finding people like me who take pride in a job well done. In my search, I found a bunch of people who go to great lengths to create carefully handcrafted custom web solutions&#8230; and don&#8217;t hesitate to mention that they&#8217;re pleased with their accomplishments. They point out things like: attention to detail, finesse, simplicity, ease of use, and even performance. I edited my own <a href="/about">About</a> page to capture some of these same points because I feel strongly that they&#8217;re good things to do on every project, even if it takes a bit more time.</p>
<p>While I was poking around looking for inspiring words to share, I ran across Joshua Porter&#8217;s presentation <a href="http://www.slideshare.net/bokardo/on-being-a-web-craftsman" target="_blank">On Being a Web Craftsman</a> on SlideShare. It&#8217;s truly one of the best things I&#8217;ve read in years. It&#8217;s only 17 slides total, but it so eloquently captures what I feel strongly about and what I aspire to be&mdash;a web craftsman. There are several great ideas captured in those few slides, but I think this one is my favorite:</p>
<blockquote><p>Craftsmen are not driven by money or recognition, but by simply doing Good Work.</p></blockquote>
<p>I really love that&#8230; because it&#8217;s so true. I feel like it&#8217;s definitely worth it to do &#8220;good work&#8221; on every project. Toward the end of Joshua&#8217;s presentation, he includes a slide titled &#8220;Trouble Spots&#8221; that really hits close to home:</p>
<blockquote><p>
Craftsmanship takes a lot of time.<br />
Craftsmen have trouble managing people.<br />
Craftsmen don&#8217;t necessarily play well with others.<br />
Craftsmen tend not to be business savvy.
</p></blockquote>
<p>I don&#8217;t necessarily think these are negative. I think they&#8217;re good qualities to have because they so accurately describe someone who goes out of their way to create something good and honest&#8230; and possibly even beautiful. Perhaps you feel the same.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.mpgilbert.com/i-aspire-to-be-a-web-craftsman/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>My Site Now Fits on Your Phone (and Your Tablet)</title>
		<link>http://www.mpgilbert.com/my-site-now-fits-on-your-phone-and-your-tablet</link>
		<comments>http://www.mpgilbert.com/my-site-now-fits-on-your-phone-and-your-tablet#comments</comments>
		<pubDate>Mon, 05 Nov 2012 03:40:15 +0000</pubDate>
		<dc:creator>michael</dc:creator>
				<category><![CDATA[Mobile]]></category>
		<category><![CDATA[News]]></category>
		<category><![CDATA[Responsive Web Design]]></category>
		<category><![CDATA[Web Standards]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://www.mpgilbert.com/?p=757</guid>
		<description><![CDATA[That&#8217;s right! I&#8217;ve re-written all of the HTML and CSS code on this site so that it&#8217;s now fully responsive. In other words, if you&#8217;re looking at this on a desktop computer, you can slowly resize your browser (i.e., click the lower-right corner and drag it to the left) and watch all of the website&#8217;s [...]]]></description>
				<content:encoded><![CDATA[<p><img class="alignright" title="" src="http://www.mpgilbert.com/wp-content/uploads/mpgilbert-rwd-post.jpg" alt="mpgilbert.com on multiple screens" /></p>
<p>That&#8217;s right! I&#8217;ve re-written all of the HTML and CSS code on this site so that it&#8217;s now fully responsive. In other words, if you&#8217;re looking at this on a desktop computer, you can slowly resize your browser (i.e., click the lower-right corner and drag it to the left) and watch all of the website&#8217;s content shift around as the window gets smaller and smaller until you reach the approximate size of a mobile phone. The overall layout, all of the text, and even the images will respond to the size of the browser at all dimensions. As the browser gets smaller, the site shrinks to properly fit. If you&#8217;re looking at this site on your mobile phone, you&#8217;ll just see a simple, clean, and performance-oriented website. The HTML code and all the content throughout the entire site are the same for all devices and screen widths.</p>
<p><span id="more-757"></span></p>
<p>There are several methods of doing <a href="http://en.wikipedia.org/wiki/Responsive_web_design" target="_blank">responsive web design</a>, but after much research and agonizing, I decided to take the <a href="http://www.lukew.com/ff/entry.asp?933" target="_blank">mobile first</a> approach. I did quite a lot of reading and experimenting over the last several weeks and decided to use my own website as the test. I must say, I had serious reservations about being able to make the mental shift to thinking about the mobile experience at the beginning, but I was pleasantly surprised with the process when I actually started coding. When you break it down, it&#8217;s really just an extension of the concept of <a href="http://en.wikipedia.org/wiki/Progressive_enhancement" target="_blank">progressive enhancement</a> which I&#8217;ve been a big fan of for many years. I generally try to separate the underlying structural markup (HTML) from the presentation (CSS) and behavioral layer (JavaScript) when building any website, but this seemed like taking it to a whole new level.</p>
<p>The other thing that I was surprised about was how comfortable I&#8217;ve become over the last few years at designing in the browser. I had a pretty clear mental picture of the final desktop layout, but I made numerous adjustments to the CSS in reaction to what&#8217;s happening in the browser at various widths. Also, I didn&#8217;t sit down with Photoshop and create design comps of the three typical browser widths (CSS media query breakpoints). For me, it&#8217;s much easier to see what&#8217;s going on in the browser and make adjustments to the code along the way.</p>
<p>I&#8217;ve always supported the &#8220;content is king&#8221; way of thinking, so the whole mobile first approach made a lot of sense to me—it places the content front and center from the very beginning. This may seem like an obvious thing to do, but you may be surprised to find out that it&#8217;s far from the norm in the field of web design. Websites are usually designed with fake content (called <a href="http://en.wikipedia.org/wiki/Greeking" target="_blank">greeking</a> in the industry). This approach has always confused me&#8230; how can you design a site without any of the content? What happens if the content that eventually gets written doesn&#8217;t fit into the neat, tidy, conveniently designed spaces? Well, it often doesn&#8217;t fit. That&#8217;s the problem.</p>
<p>I&#8217;m not primarily a visual designer, so when I decided to do this redesign (really it&#8217;s more of a rebuild), I needed a visual design to start with, so I maintained the basic look and feel of the existing WordPress theme that I bought a couple years ago (<a href="http://demo.woothemes.com/elefolio/" target="_blank">Elefolio</a> by WooThemes). I like the simplicity of the design with the neutral colors and overall non-intrusive approach that features the portfolio items nicely. Working with an existing visual design also closely matches the way that I normally work&mdash;partnering with a visual designer&mdash;so that was a familiar and comfortable starting point. I made several enhancements to the original design, but some visual elements are still present.</p>
<h3>Additional Reading</h3>
<p>Interested in reading more about responsive web design and mobile first? Look no further&#8230; here&#8217;s a short list of online resources that I found extremely useful while I was doing all of my research, experimentation, and development.</p>
<ul>
<li><a href="http://www.alistapart.com/articles/responsive-web-design/" target="_blank">Responsive Web Design article on A List Apart</a> by Ethan Marcotte</li>
<li><a href="http://www.abookapart.com/products/responsive-web-design" target="_blank">Responsive Web Design book</a> by Ethan Marcotte</li>
<li><a href="http://www.abookapart.com/products/mobile-first" target="_blank">Mobile First book</a> by Luke Wroblewski</li>
<li><a href="http://www.html5rocks.com/en/mobile/responsivedesign/" target="_blank">Creating a Mobile-First Responsive Web Design</a> by Brad Frost</li>
<li><a href="http://bradfrost.github.com/this-is-responsive/patterns.html" target="_blank">Responsive Web Design Patterns</a> by Brad Frost</li>
<li><a href="http://shop.oreilly.com/product/0636920018100.do" target="_blank">Head First Mobile Web book</a> by Lyza Danger Gardner, Jason Grigsby</li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://www.mpgilbert.com/my-site-now-fits-on-your-phone-and-your-tablet/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
