<?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>Francisco Samper</title>
	<atom:link href="http://www.franciscosamper.com/?feed=rss2" rel="self" type="application/rss+xml" />
	<link>http://www.franciscosamper.com</link>
	<description>diseño web alicante</description>
	<lastBuildDate>Fri, 18 May 2012 21:45:31 +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>A Foot On The Bottom Rung: First Forays Into Responsive Web Development</title>
		<link>http://www.franciscosamper.com/?p=442</link>
		<comments>http://www.franciscosamper.com/?p=442#comments</comments>
		<pubDate>Fri, 18 May 2012 21:45:31 +0000</pubDate>
		<dc:creator>Fran</dc:creator>
				<category><![CDATA[Portfolio]]></category>
		<category><![CDATA[Bottom]]></category>
		<category><![CDATA[Development]]></category>
		<category><![CDATA[First]]></category>
		<category><![CDATA[Foot]]></category>
		<category><![CDATA[Forays]]></category>
		<category><![CDATA[into]]></category>
		<category><![CDATA[Responsive]]></category>
		<category><![CDATA[Rung]]></category>

		<guid isPermaLink="false">http://www.franciscosamper.com/?p=442</guid>
		<description><![CDATA[&#160;&#160; Responsive design is the hottest topic in front-end Web development right now. It’s going to transform the Web into&#8230;]]></description>
			<content:encoded><![CDATA[<table width="650">
<tr>
<td width="650">
<div style="width:650px;">
      <img src="http://statisches.auslieferung.commindo-media-ressourcen.de/advertisement.gif" alt="" border="0" /><br />
      <a href="http://auslieferung.commindo-media-ressourcen.de/random.php?mode=target&#038;collection=smashing-rss&#038;position=1" target="_blank"><img src="http://auslieferung.commindo-media-ressourcen.de/random.php?mode=image&#038;collection=smashing-rss&#038;position=1" border="0" alt="" /></a>&nbsp;<a href="http://auslieferung.commindo-media-ressourcen.de/random.php?mode=target&#038;collection=smashing-rss&#038;position=2" target="_blank"><img src="http://auslieferung.commindo-media-ressourcen.de/random.php?mode=image&#038;collection=smashing-rss&#038;position=2" border="0" alt="" /></a>&nbsp;<a href="http://auslieferung.commindo-media-ressourcen.de/random.php?mode=target&#038;collection=smashing-rss&#038;position=3" target="_blank"><img src="http://auslieferung.commindo-media-ressourcen.de/random.php?mode=image&#038;collection=smashing-rss&#038;position=3" border="0" alt="" /></a>
    </div>
</td>
</tr>
</table>
<p>Responsive design is the hottest topic in front-end Web development right now. It’s going to transform the Web into an all-singing, all-dancing, all-devices party, where we can access any information located anywhere in the world. But does responsive design translate well from the text-heavy Web design blogosphere to the cold hard reality of commercial systems?</p>
<p>Rumors came through our office grapevine that management was looking to revamp our mobile presence. There was talk of multiple apps being built externally that could be used on some of the major mobile devices. Our team had been getting familiar with responsive design and put forward a proposal of doing away with device-specific apps and developing a single responsive website that could be served to both desktop and mobile users. After a few hasty demos and prototypes, the idea was accepted and we began work.</p>
<p>The brief: make our current website, <a href="http://www.airport-hotels.uk.com">Airport-Hotels.uk</a>, responsive while retaining the existing layout for users on browsers of 1000 pixels and up.</p>
<p>The following is what we picked up along the way.</p>
<h3>Starting With Desktop Is OK</h3>
<p>The general consensus now seems to be “mobile first.” I agree. Starting with a single(ish)-column mobile website is the easiest way to get your CSS off to a great start. However, we use an external design agency, so the time and cost of a new mobile-first design was not feasible. It was left to the front-end developer to translate the existing design onto screens of smaller dimensions.</p>
<p>The solution was to break up the website into smaller blocks (or nuggets), which could then be positioned differently as the browser’s width increased. This led to our first base media query, which contained the main branding elements, with minimal layout information. Because the nuggets were of a fairly fixed size, we had a foundation for creating a grid for each of our major media queries. Anything that wasn’t deemed to be a “nugget,” such as a larger block of text, would be responsive and fill in the gaps that the nuggets couldn’t.</p>
<p><a href="http://media.smashingmagazine.com/wp-content/uploads/2012/02/starting-with-desktop-ok-desktop.png"><img class="alignnone size-full wp-image-111688" title="Row from availability table desktop view" src="http://media.smashingmagazine.com/wp-content/uploads/2012/02/starting-with-desktop-ok-desktop.png" alt="" width="977" height="132" /></a></p>
<p><a href="http://media.smashingmagazine.com/wp-content/uploads/2012/02/starting-with-desktop-ok-mobile.png"><img class="alignnone size-full wp-image-111690" title="Availability grid mobile view" src="http://media.smashingmagazine.com/wp-content/uploads/2012/02/starting-with-desktop-ok-mobile.png" alt="Mobile view of availability results" width="482" height="239" /></a></p>
<p>While this method is not as good a practice as “mobile first,” it does have the advantage of being faster and cheaper than a full redesign. And you pick up great knowledge along the way for when resources do become available for something more substantial.</p>
<h3>Less Is More</h3>
<p>When getting your feet wet with media queries, you’re tempted to go all out, but do you need to? Theoretically, you could serve a completely different design to each device. While this would be spectacular and self-satisfying, maintaining it would be a nightmare. We ended up using the default media queries in Andy Clarke’s <a href="http://stuffandnonsense.co.uk/projects/320andup/">320 and Up</a> framework, containing four breakpoints (1382 pixels was not in the brief). Looking back now, we could have removed at least one of those queries, possibly two.</p>
<p>We’ve been gathering statistics in the weeks since the website’s release, and by far the majority of our customers are running browsers either of 320 × 480 pixels or on full desktops. We could hit over 85% of our user base by focusing on these resolutions, while cutting down on development time and maintenance.</p>
<p>This was especially evident on our availability page, which easily contains the most information of any of the pages in our booking flow. In the end, rather than try to serve the perfect design to each device width, we moved much of the CSS for the largest media query to the size below: less maintenance, less fuss, and more time to work on the UX (and, importantly to the business, to make bookings).</p>
<h3>Ability Sniffing Is Not Enough</h3>
<p>When I first saw tools like <a href="http://modernizr.com/">Modernizr</a>, I thought they would change everything. I suppose they have, but don’t rely on them too much. Mobile browsers have more inconsistencies than any desktop I have ever seen. Even WebKit-based browsers can render things completely differently. With debugging tools at a minimum, it’s like we’ve been thrust back into the pre-developer toolbar era of IE bug fixing. Luckily, that’s one of my favorite things.</p>
<p>Exploring this strange new world of bugs became one of the major aspects of the project. A few of my favorites are highlighted below. Hopefully, they won’t trip you up.</p>
<h4>CSS Columns</h4>
<p>I love CSS columns. I had been wanting to use them for a while; but, other than small personal projects, nothing with appropriate content came up. While trying to work out the best layout for our website on a 320-pixel device, I realized that, rather than generating columns using floats or inline blocks, we could reduce the layout CSS to just a few lines by creating CSS columns. With most major mobile Web browsers being based on WebKit and Opera, this seemed to be a fairly reasonable solution and appeared to lay out everything perfectly. Great!</p>
<p>Here is the original code for the 320-pixel media query:</p>
<pre class="brush: css">.product {
    -moz-column-count: 2;
    -moz-column-gap: 5px;
    -webkit-column-count: 2;
    -webkit-column-gap: 5px;
    column-count: 2;
    column-gap: 5px;
}</pre>
<p>And here is the updated solution (roughly speaking — the actual code was much longer):</p>
<pre class="brush: css">.product&gt;div {
    width: 49%;
    float: left;
    margin: 0.5%;
}</pre>
<p>Unfortunately, the <code>column</code> specification isn’t quite ready yet. On BlackBerrys and some HTC Android phones, our form elements (specifically, the buttons) became unclickable. The layout was perfect — we checked that the CSS was accepted with Modernizr, and all the links worked — and yet you couldn’t click the “Book” button. Back to the drawing board with that one.</p>
<p>We ended up using a more standard float-based column layout.</p>
<h4>CSS Gradients</h4>
<p>Gradients were another excellent instance of browser idiosyncrasies. We used a lot of CSS gradients in this redevelopment to replace some images. This should have saved the user’s bandwidth and made redesigns and maintenance faster.</p>
<p>On WebOS (with a WebKit-based browser), though, CSS gradients would render as completely black unless used on a form input element. It was baffling. In the end, we figured out that it was a bug in the implementation of <code>-webkit-linear-gradient</code>. We’ve learned that the bug has been fixed in the upcoming version, so this might not be an issue in the future.</p>
<p>Here is the offending CSS:</p>
<pre class="brush: css">.ppcHeader {
    background: #73bff1; /* Old browsers */
    background: -moz-linear-gradient(left, #73bff1 0%, #009ff7 100%); /* FF3.6+ */
    background: -webkit-gradient(linear, left top, right top, color-stop(0%,#73bff1), color-stop(100%,#009ff7)); /* Chrome,Safari4+ */
    background: -webkit-linear-gradient(left, #73bff1 0%,#009ff7 100%); /* Chrome10+,Safari5.1+ */
    background: -o-linear-gradient(left, #73bff1 0%,#009ff7 100%); /* Opera11.10+ */
    background: -ms-linear-gradient(left, #73bff1 0%,#009ff7 100%); /* IE10+ */
    background: linear-gradient(left, #73bff1 0%,#009ff7 100%); /* W3C */
    margin-bottom: 20px;
}</pre>
<p>(Bear in mind that CSS gradients add a heavy load to the browser’s rendering engine, so if you are using a lot of them, switching them off for mobile might be wise.)</p>
<h4>JavaScript on BlackBerry 5.0 and Opera Mini</h4>
<p>Basically, JavaScript does not work on Blackberry 5.0. BlackBerry tries, but it’s so inconsistent and buggy that it’s not worth it. We were reliably advised by <a href="http://www.quirksmode.org/about/">Peter-Paul Kochs</a> to just resort to device sniffing and to turn off any JavaScript. This is another reason to make sure your websites are progressively enhanced by falling back to non-JavaScript versions.</p>
<p>Meanwhile, Opera Mini works fine with JavaScript, but each of a website’s pages is rendered on Opera’s servers and then essentially compressed into a big image before being sent to the mobile device. This is great for the user because it can reduce bandwidth to 10% of the normal browsing experience. On the other hand, if you have <code>onkeyup</code> validation in your forms, this can be a problem because each call to the JavaScript would require refreshing the entire page from the server.</p>
<h3>Forms Drop Users</h3>
<p>This was and still is one of the major problems with mobile browsing on our e-commerce website. In order to make a purchase on an average website, the user has to fill in a lot of information: names, addresses, credit-card details, the list goes on and on. While typing on mobile has gotten much easier, navigating large forms is a frustrating and laborious process.</p>
<p>Our mockup payment page had 22 form inputs that needed some kind of interaction. These were required either to make a successful booking, to provide information to the product supplier after booking or for our own sales and data purposes.</p>
<p><a href="http://media.smashingmagazine.com/wp-content/uploads/2012/02/forms-drop-users-desktop.png"><img class="alignnone size-large wp-image-111695" title="Airport hotels payment form desktop view" src="http://media.smashingmagazine.com/wp-content/uploads/2012/02/forms-drop-users-desktop-576x1024.png" alt="Payment form desktop view" width="576" height="1024" /></a><a href="http://media.smashingmagazine.com/wp-content/uploads/2012/02/forms-drop-users-mobile.png"><img class="alignright size-large wp-image-111696" title="Airport hotels paymnt form mobile view" src="http://media.smashingmagazine.com/wp-content/uploads/2012/02/forms-drop-users-mobile-112x1024.png" alt="Payment form mobile view" width="112" height="1024" /></a></p>
<p>The question became (as it always seems to be with mobile), what could we remove and what did we have to keep? Well, we tried to take the middle path, which is currently in development or might even be live by the time you read this.</p>
<p>We chose to split our payment process into two stages. Because our users can save more on their purchase by booking early, our first payment stage asks for the very minimum of information required in order to confirm a booking: name, car registration and credit-card details. This gives the user the best price available and chalks up another booking for us. Part two of the payment process is to gather the rest of the information required to “complete” the booking. This second stage can be filled out at the user’s convenience, either immediately or later on using our online booking management system. This eases any frustration caused by having to fill out a large form.</p>
<h3>Good UI != Good UI</h3>
<p>A good user interface means something completely different on mobile devices — and even tablets for that matter. Many of the user-friendly features we have implemented on our desktop website would just be bad ideas on these smaller mouse-less devices.</p>
<h4>Lightboxes</h4>
<p>Lightboxes were all the rage a few years ago. They were a convenient and pretty way to display a small amount of content or something that wasn’t worth loading a new page for. In IE 7 and up, you can position lightboxes using <code>position: fixed</code>, which is great. On mobile devices, though, browsers do not implement <code>position: fixed</code>, or they implement it in an odd way to prevent non-mobile-ready websites from not working at all. This will ruin any lightboxes.</p>
<p>We recommend just loading a new page for lightbox content: less JavaScript, easier and fast. A new tab would also be fine, but due to the infancy of tabbed browsing on mobile devices, maintaining the flow is probably a better idea for now.</p>
<h4>Hovers</h4>
<p>Content that is only visible via hovering obviously doesn’t work on touchscreens. What used to be an easy way to hide content while keeping it accessible has become a bit of a nightmare to deal with. We tried just removing the hover and showing the content, to see what would happen. The iPhone actually handles hovers fairly well, translating them into tap events. On Android, you need to click and hold for a little while to prevent the default action of clicking the link (our links are anchor-tag-based).</p>
<p>In the end, modifying the code that handles the hovers (assuming it’s JavaScript) and adding a tap event seemed to be the best solution. This allowed us to preserve the design’s aesthetic, while keeping as much functionality as possible for mobile users.</p>
<pre class="brush: js">if( document.createTouch ) {
    this.addEvent(c[j],'tap',this.tipOver,false);
} else {
    this.addEvent(c[j],'mouseover',this.tipOver,false);
    this.addEvent(c[j],'mouseout',this.tipOut,false);
}</pre>
<h4>Date Picker</h4>
<p>Our date-picker calendar was one of the biggest hurdles to overcome in the UI. We have a text input that allows the user to enter a date. Prior to the date-picker, our solution was a dynamically generated select box, but that caused confusion among many users because they might have remembered the day of the week they were flying on but not the date. So, we added the jQuery UI Datepicker to make filling in the search form one step easier.</p>
<p>However, what was one step forward for convenience on the desktop was one step back on mobile. Focusing the text input would open both the date picker and the phone’s keyboard, thus obscuring the date picker.</p>
<p>Our next option was to use the HTML5 date input. Because this element was released so recently, browsers are still playing catch up, and implementations vary wildly. It’s just as rough on desktop, with Firefox still rendering it as a text input, Chrome adds an up/down selector and forces the date format, while Opera actually renders a calendar just like the jQuery UI Datepicker. This solution still requires the date-picker JavaScript, but it forces the format, which can actually make it less user-friendly. While the concept is great and the solution will be great once the bugs are ironed out, we found that the date type input is not yet ready for commercial use in this fashion.</p>
<p>Our eventual solution (not yet live) was to use a JavaScript “touch event” query to generate a more mobile-friendly date picker than the standard jQuery UI one. This creates an iOS-styled triple drop-down menu for day, month and year and is user-friendly on mobile devices. The no-JavaScript backup can be either a text input or a select drop-down menu. <a href="http://secure.holidayextras.co.uk/js/general/jquery.mobileFriendlyDatepicker.js">Have a look at the code for yourself.</a></p>
<h3>Fix IE First</h3>
<p>The final point, which reflects the complexity of mobile development, is how to fit old versions of IE into this new technology. IE 8 and below ignores media queries, which presents a rather sticky problem when your entire website is based on them. There are several solutions to this, which we’ll explore below.</p>
<h4>JavaScript Polyfills</h4>
<p>I can think of two great JavaScript polyfill options for media queries. The first is Respond.js, which continually monitors the browser’s width, parses the CSS and then serves the correct styles for that width. This is a great solution if you need the website to respond on IE 8 and below. The main issue is the time between the document loading and the JavaScript kicking in; the website is initially displayed using the base style sheet, usually the mobile view, before it “jumps” to the full desktop version. Obviously, this doesn’t look great on a desktop monitor, and if the user is on an old browser, then their computer and Internet connection will probably be slow, too, which means that the jump time could be even longer.</p>
<p>The other JavaScript option here is the Chrome frame, which achieves the same end and has the same disadvantages. This solution isn’t bad, but just not right for our implementation.</p>
<h4>Include All Media Queries</h4>
<p>This is one of my favorite options for responsive websites and is also used in the latest version of the 320 and Up boilerplate. Create a separate CSS file for each device width; and for IE, serve them all to the user, with no media queries. With a mobile-first approach and a couple of fixed widths in your IE style sheet, this will serve the full-sized version of the website to users of outdated browsers. This solution is fast, simple and easy to maintain.</p>
<h4>A Separate IE Style Sheet Entirely</h4>
<p>Finally, given the right conditions, you could just write a completely separate IE style sheet, full of conditional comments to load the full desktop version of the website. Theoretically, this need only contain small amounts of layout information; but given that many of these styles will be reproduced in your media queries for wider widths, it can cause maintenance issues down the line. Duplicating code is never a good idea, which makes me wary of this solution.</p>
<p>Interestingly, we used this solution in the end, but with a twist. We used a PHP plugin in our template files to combine, compress and cache our CSS files. Due to some issues with the cache in IE, we were already generating a separate cached CSS file for IE users. We added a couple of lines to the PHP file to strip out media queries entirely as it combines and compresses the CSS. This method delivers the results of the “include all media queries” solution, while allowing the option for inline media queries in the style sheet. Because of the way we organized the CSS, this turned out to be the best solution for the project.</p>
<h3>Conclusion</h3>
<p>After all that, we finally have the first version of our responsive booking flow. I like to think that this epitomizes “mobile-ready.” We aren’t necessarily mobile-optimized, but our feet are on the bottom rung of a tall ladder that climbs to a great system that works perfectly on all devices. This is the starting point, if you will.</p>
<p>Was it worth it? It’s been a long journey, with a lot of head scratching and learning on our feet fast, but that’s what Web development is about, and I wouldn’t have it any other way. You can’t be perfect the first time round, and you don’t have to be. The point is that this technology is ready now, and the sooner you start using it, the better prepared you’ll be for the mobile market as it comes running at you. In the next few years, we’re hoping to see JavaScript network APIs that will allow Web users to add purchases directly to their monthly phone bill. I expect the mobile e-commerce market will explode at that point. Will you be ready?</p>
<p><em>(al) (da) (il)</em></p>
<hr />
<p><small>© Gavyn McKenzie for <a href="http://www.smashingmagazine.com">Smashing Magazine</a>, 2012.</small></p>
<p><a rel="nofollow" href="http://www.smashingmagazine.com/2012/05/18/a-foot-on-the-bottom-rung-first-forays-into-responsive-web-development/">Smashing Magazine Feed</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.franciscosamper.com/?feed=rss2&#038;p=442</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Quick Course On Effective Website Copywriting</title>
		<link>http://www.franciscosamper.com/?p=441</link>
		<comments>http://www.franciscosamper.com/?p=441#comments</comments>
		<pubDate>Fri, 18 May 2012 21:45:30 +0000</pubDate>
		<dc:creator>Fran</dc:creator>
				<category><![CDATA[Portfolio]]></category>
		<category><![CDATA[Copywriting]]></category>
		<category><![CDATA[Course]]></category>
		<category><![CDATA[Effective]]></category>
		<category><![CDATA[Quick]]></category>
		<category><![CDATA[Website]]></category>

		<guid isPermaLink="false">http://www.franciscosamper.com/?p=441</guid>
		<description><![CDATA[&#160;&#160; Many dismiss copywriting as something that ad agency people do. Truthfully, all of us need to pay close attention&#8230;]]></description>
			<content:encoded><![CDATA[<table width="650">
<tr>
<td width="650">
<div style="width:650px;">
      <img src="http://statisches.auslieferung.commindo-media-ressourcen.de/advertisement.gif" alt="" border="0" /><br />
      <a href="http://auslieferung.commindo-media-ressourcen.de/random.php?mode=target&#038;collection=smashing-rss&#038;position=1" target="_blank"><img src="http://auslieferung.commindo-media-ressourcen.de/random.php?mode=image&#038;collection=smashing-rss&#038;position=1" border="0" alt="" /></a>&nbsp;<a href="http://auslieferung.commindo-media-ressourcen.de/random.php?mode=target&#038;collection=smashing-rss&#038;position=2" target="_blank"><img src="http://auslieferung.commindo-media-ressourcen.de/random.php?mode=image&#038;collection=smashing-rss&#038;position=2" border="0" alt="" /></a>&nbsp;<a href="http://auslieferung.commindo-media-ressourcen.de/random.php?mode=target&#038;collection=smashing-rss&#038;position=3" target="_blank"><img src="http://auslieferung.commindo-media-ressourcen.de/random.php?mode=image&#038;collection=smashing-rss&#038;position=3" border="0" alt="" /></a>
    </div>
</td>
</tr>
</table>
<p>Many dismiss copywriting as something that ad agency people do. Truthfully, all of us need to pay close attention to copywriting if we want to achieve our business objectives.</p>
<p>The goal of a &#8220;regular&#8221; text is to inform or entertain. The goal of Web copy (and ideally your website in general) is to get people to do something&mdash;to sign up, make a purchase, or something similar. Hiring a professional copywriter can be very expensive, which is one of the reasons why this is a valuable skill to have yourself.</p>
<blockquote><p>&#8220;I don&#8217;t need to learn copywriting, I write based on how it sounds to me.&#8221;</p>
</blockquote>
<p>Think you don&#8217;t need to learn copywriting?</p>
<p>David Ogilvy, the father of modern advertising, addressed this in his book <a href="http://www.amazon.com/Ogilvy-Advertising-David/dp/039472903X" target="_blank">Ogilvy on Advertising</a>. One of his copywriters told him that he had not read any books about advertising; he preferred to rely on his own intuition.</p>
<p>Ogilvy asked him: <em>&#8220;Suppose your gallbladder has to be removed this evening. Will you choose a surgeon who has read some books on anatomy and knows where the gallbladder, is or someone who relies on his own intuition?&#8221;</em></p>
<p>What distinguishes top experts from mediocre players is that the best <em>know more</em>. You can write better copy if you know more about it.</p>
<h3>The Process Of Writing Great Copy</h3>
<p>Everything is easier with the right process. If your approach to copywriting is &#8220;I&#8217;ll just try to be convincing&#8221;, you&#8217;re setting yourself up for failure.</p>
<p>You don&#8217;t even need to be a &#8220;natural writer&#8221; to come up with excellent copy, you just need the right process and some key principles about writing copy that sells.</p>
<p>The best processes are simple, as those are the ones you actually use.</p>
<p>Here are the six steps of effective copywriting process:</p>
<ol>
<li>Research: customer, product and competition.</li>
<li>Outline and guideposts.</li>
<li>Draft copy.</li>
<li>Conversion boost.</li>
<li>Revise, rearrange.</li>
<li>Test.</li>
</ol>
<p>And now let&#8217;s get to the details:</p>
<h3>1. Research</h3>
<p>This is often the most time-intensive part of your copywriting.</p>
<blockquote><p>&#8220;You don&#8217;t stand a tinker&#8217;s chance of producing successful advertising unless you start doing your homework. I have always found this extremely tedious, but there is no way around it.&#8221;<br /><em>&mdash; David Ogilvy</em></p>
</blockquote>
<p>David Ogilvy had the task to do copywriting for a Rolls Royce ad. He spent three weeks reading about it before he came up with the headline and the rest of the copy. While he was talking about advertising, it equally applies to your website copy&mdash;the goal is to get people to do something.</p>
<p><a href="http://media.smashingmagazine.com/wp-content/uploads/2012/03/ogilvy-rolls-royce-ad.jpg"><img class="aligncenter size-full wp-image-126866" title="ogilvy-rolls-royce-ad" src="http://media.smashingmagazine.com/wp-content/uploads/2012/03/ogilvy-rolls-royce-ad.jpg" alt="" width="699" height="576" /><br />
<em>Ogilvy&#8217;s famous Rolls Royce ad.</em></a></p>
<p>You need to figure out why people buy the product, how they buy it, what they use it for, and what really matters to them. If you don&#8217;t have this figured out, you really cannot write a copy that works. When it&#8217;s your own business that you&#8217;re writing copy for, things go much faster, of course, as you know the product and the competition.</p>
<h4><strong>Gauge</strong><strong> the Competition</strong></h4>
<p>You need to be aware of your direct competition, how they present their product, and what claims they seem to be making. If you are not selling something unique, you are selling as much for your competition as you are selling for yourself. Being “like” others or choosing to be “one of the leading providers of” is a losing strategy.</p>
<p><a href="http://www.amazon.com/Neuromarketing-Understanding-Buttons-Customers-Brain/dp/078522680X/" target="_blank">Neuromarketing research</a> tells us that differentiating our claims is the key to talking to the old brain, the decision making part of our brain. Our whole business identity should be different from the competition, and the claims we&#8217;re making about our product should stand out.</p>
<h4><strong>Get Out of the Office</strong></h4>
<p>The answers are not in your office and you won&#8217;t have eureka-moments at brainstorming meetings (working <a href="http://www.newyorker.com/reporting/2012/01/30/120130fa_fact_lehrer" target="_blank">solo is far more effective</a> anyway). You have to interview people. Don&#8217;t waste time interviewing random people, you need to talk to your ideal customers and find out what&#8217;s on their minds.</p>
<p>Find out what they think about your kind of product, what language they use when they talk about it, what attributes are important to them, and what promises would most likely convince them to buy it. Pick the last 10 to 20 customers (who still remember their purchasing experiences), and ask them these questions (recording the interviews is a good idea, but ask for permission):</p>
<ul>
<li>Who are you? What do you do? (customer profile)</li>
<li>What does our product help you do? (helps you understand how they use it, tells you words they use to describe our product)</li>
<li>Which parameters did you compare on different options? (which features matter)</li>
<li>What were the most important ones? (key pains to solve)</li>
<li>Which alternatives did you consider? (competitors we have to look at)</li>
<li>What made you choose our product? (our key advantage)</li>
<li>What were the biggest hesitations and doubts before the purchase? (things we have to address in the copy)</li>
<li>Were there questions you needed answers to, but couldn&#8217;t find any? (necessary information to provide)</li>
<li>What information would have helped you make the decision faster? (same as above)</li>
<li>In which words would you recommend it to somebody you know? (words they use to describe our product)</li>
</ul>
<p>Take note of the exact wording they use. Your copy needs to match the conversation in your customer&#8217;s mind. If you talk about &#8220;scribing devices&#8221; and he needs a pen, there&#8217;s a mismatch.</p>
<p>My point is that when customers see the product described in words they have in their mind already, then you&#8217;ve got their attention.</p>
<h3>2. Outline And Guideposts</h3>
<p>Next step: <strong>write the outline</strong>. Guideposts are the markers that help you write the content.</p>
<p>Writing an outline usually only takes a few minutes and provides a road map for the rest of the project. It allows you to complete the work faster and ensures that you stick to the flow.</p>
<p>The outline structure will depend on the page you&#8217;re writing the copy for. The main pages you need a well thought-out copy in place are your home page and product pages.</p>
<p>Here are outline templates I personally use, and you can copy them. I&#8217;ve tweaked and tested them over the years, and this model works the best for me.</p>
<h4><strong>Home Page Copy </strong></h4>
<p>Your home page copy structure depends a lot on your business. A nail salon would have a different approach from an e-commerce store; a website selling mobile app design courses is different from a hosting company. Hence, it&#8217;s basically impossible for me to give you an outline template for your home page.</p>
<p>What IS universal is the value proposition. Every home page needs one (unless you&#8217;re a very well-known brand)</p>
<p>A value proposition is a promise of value to be delivered. It’s the primary reason a prospect should buy from you. The value proposition is usually a block of text with a visual.</p>
<p>There is no one right way to go about it, but I suggest you start with the following formula:</p>
<ul>
<li><strong>Headline</strong>:<br />What is the end-benefit you’re offering, in one short sentence. Can mention the product and/or the customer. Attention grabber.</li>
<li><strong>Sub-headline or a two-to-three sentence paragraph</strong>:<br /> A specific explanation of what you do/offer, for whom, and why is it useful.</li>
<li><strong>Bullet points</strong>:<br /> List the key benefits or features.</li>
</ul>
<p>Here&#8217;s a list of useful <a href="http://conversionxl.com/value-proposition-examples-how-to-create/" target="_blank">value proposition examples</a> you can check out.</p>
<h4><strong>Product Page Copy Outline</strong></h4>
<p>Product page is where you sell the value of your product and where the user takes action (adds to cart, sign up, makes a purchase, etc.).</p>
<ol>
<li>Name of the product.</li>
<li>Value proposition: what&#8217;s the end-benefit of this product and who is it for?</li>
<li>Specific and clear overview of what the product does and why is that good (features and benefits).</li>
<li>What&#8217;s the pain that it solves? Description of the problem.</li>
<li>List of everything in the product (e.g. curriculum of the course, list of every item in the package, etc.).</li>
<li>Technical information: parameters, what do you get and how does it work?</li>
<li>Objection handling. Make a list of all possible FUDs (fears, uncertainties, doubts) and address them.</li>
<li>Bonuses (what you get on top of the offer).</li>
<li>Money-back guarantee (+ return policy).</li>
<li>Price.</li>
<li>Call to action.</li>
<li>Expectation setting: what happens after you buy?</li>
</ol>
<p>What you now have in place is like a skeleton. Next step would be to start writing the draft version of the copy by filling in the blanks.</p>
<h3>3. Draft Copy</h3>
<p>Start filling in the blanks in the template above, and keep these points in mind for the style of your writing.</p>
<h4><strong>Avoid Jargon and Blandvertising</strong></h4>
<p>The goal of the copy is to connect with the reader, and guide them towards an action.</p>
<blockquote><p>&#8220;Human relationships are about communicating. Business jargon should be banished in favor of simple English. Simplicity is a sign of truth and a criterion of beauty. Complexity can be a way of hiding the truth.&#8221;<br /><em>&mdash; Helena Rubinstein</em></p>
</blockquote>
<p>Using complicated, fancy words does not make you seem any smarter or your solution any better&mdash;it just turns everybody off. Who wants to read something that doesn&#8217;t feel like it&#8217;s written for them? Talk to people like a real human. If you wouldn&#8217;t use a phrase on your website in a conversation with a customer, then don&#8217;t use it.</p>
<p>In addition to fancy words, avoid meaningless phrases. What do &#8220;on-demand marketing software&#8221;, &#8220;integrated solutions&#8221; or &#8220;flexible platform&#8221; really mean anyway?</p>
<p>Or useless phrases like &#8220;changing the way X is done&#8221;, &#8220;paradigm shifting &#8230;&#8221; or &#8220;exceeding customer expectations&#8221;&mdash;stop the nonsense. These bland phrases have long lost any meaning, and you will just waste precious attention time. You can see a list of the top 100 most overused buzzwords and marketing speak in press releases <a href="http://www.adamsherk.com/public-relations/most-overused-press-release-buzzwords/" target="_blank">here</a>.</p>
</p>
<p>Another thing to avoid&mdash;superlatives and hype. Saying things like &#8220;the best&#8221;, &#8220;world leader&#8221;, &#8220;once-in-a-lifetime opportunity&#8221; will just ruin your integrity. People don&#8217;t believe such claims anyway (even if they&#8217;re true).</p>
<p>What to do instead? Be specific.</p>
<h4><strong>Be Specific</strong></h4>
<p>Specificity converts.</p>
<blockquote><p>&#8220;Clearer and more specific subject lines convert better.&#8221;<br /><em>&mdash; <a href="http://www.marketingexperiments.com/blog/research-topics/copywriting-research-topics/writing-meaningful-copy.html" target="_blank">Bob Kemper</a>, Senior Director of Sciences, MECLABS.</em></p>
</blockquote>
<p>While in that specific quote Bob was focused on subject lines, this principle applies equally well to all copywriting. Specific is believable, specific is attractive, specific is convincing. Don’t be vague, be specific.</p>
<p>&#8220;We have the best coffee in the world&#8221; vs &#8220;Our estate earned the &#8216;world’s best coffee&#8217; title at the Specialty Coffee Association of America&#8217;s Roasters Guild for the third year in a row.&#8221; Which claim is more believable?</p>
<p>You can use a superlative if you back it up.</p>
<p><a href="https://squareup.com/" target="_blank">Here’s an example</a>. Can you understand what they offer?</p>
<p><a href="https://squareup.com/"><img class="aligncenter size-full wp-image-126857" title="Square" src="http://media.smashingmagazine.com/wp-content/uploads/2012/03/squareup.jpg" alt="" width="500" height="317" /></a><br />
<em>Specific headline. Specific call to action with a specific explanation of what they get when they sign up. Specific benefits listed. Specific image to show the product in action.</em></p>
<h4><strong>It Has to Be About Them</strong></h4>
<p>Remember the old brain I mentioned before?</p>
<p>Our brains have three layers, and the oldest part&mdash;the old brain&mdash;is the decision-making part.</p>
<p>The &#8220;Old Brain&#8221; is the part that humans and their predecessors have had the longest&mdash;like 450 million years or so. So the part of the brain that controls decisions is fairly primitive and mostly concerned with survival.</p>
<p>If your copy is about you (your product, your company) and not the prospect (his problems, his life), you will fail. Make it about them. Too many companies start by stating &#8220;our company was founded&#8230;&#8221;, &#8220;we offer &#8230;&#8221; or something especially useless like &#8220;welcome to your website&#8221;.</p>
<p>Instead of saying &#8220;we specialize in dog training&#8221;, say &#8220;train your dog in two weeks&#8221;&mdash;move the focus from you to the benefit they will receive. People care about themselves&mdash;not you&mdash;and whether your website can be helpful in some way.</p>
<h4>How Much Information Should I Provide?</h4>
<p>Tests have shown that <a href="http://www.useit.com/alertbox/9710a.html">79% of people don’t read</a>, they just skim. However, 16% read everything.</p>
<p>Those 16% are your main target group, the most interested people. If people are not interested in what you are selling, it doesn’t matter how long or short your sales copy is. If they are interested, you should give them as much information as possible.</p>
<p>Complete information is the best sales copy. A study by <a href="http://www.idc.com/">IDC</a> showed that 50% of the uncompleted purchases were due to lack of information. They can always skip parts and click the “buy” button once they have the information they need. But if they read through the whole thing and they’re still not convinced, then you have a problem.</p>
<p>This is why you should always strive to say everything that can possibly be said about your product. You cannot be there in person to explain and answer the questions, so your copy needs to do it for you.</p>
<h4><strong>All at Once or Make Them Click?</strong></h4>
<p><a href="http://econsultancy.com/us/blog/7909-short-vs-long-form-hitting-the-target-with-landing-page-depth-2" target="_blank">Long form copy</a> works just great, but it&#8217;s not necessary to provide all the information on a single page. It&#8217;s okay to move supplemental information onto a different page (layer, popup, etc.) and just link to it.</p>
<p>For instance, Amazon often hides full technical information of products behind a link&mdash;since it&#8217;s only interesting to the hardcore tech savvy customers (and most customers are not).</p>
<p><a href="http://media.smashingmagazine.com/wp-content/uploads/2012/03/amazontech.jpg"><img class="aligncenter size-full wp-image-126863" title="Amazon screenshot" src="http://media.smashingmagazine.com/wp-content/uploads/2012/03/amazontech.jpg" alt="" width="500" height="217" /><br />
<em>Full technical details available after clicking a link.</em></a></p>
<p>The important thing is that all the information needed to make the decision is on a single page. Don&#8217;t make people <del>work</del> click to read stuff that you want them to read anyway (like features, benefits, testimonials, pricing, etc.).</p>
<h4>When, Where and If at All Should I Show the Price?</h4>
<p>Some people think that the price drives readers away, and they should hide it somehow&mdash;or make it hard to get to. While there is truth in that sometimes, it&#8217;s mostly false.</p>
<p>Consider this:</p>
<ol>
<li>People always want to know how much things cost.</li>
<li>If you don&#8217;t publish the price, have a &#8220;get a quote&#8221; form instead. But if your competition does, they may get the client.</li>
</ol>
<p>You should always make the price easy to find, but for more complex / expensive products <em>communicate the value before the price</em>.</p>
<p>Let&#8217;s say you&#8217;re selling a copper vase. Price: $  990.</p>
<p>Seems expensive. But what if you knew that it was designed by Andy Warhol and previously used by Kurt Cobain? If you know who these people are and respect them, this changes everything, and it might seem like a steal instead.</p>
<p>So communicate value before price.</p>
<p>If your price is cheap, you want people to know it. If it&#8217;s expensive, the price qualifies the right people who are convinced to buy your copy. Giving price details also convinces your reader of the image and brand value of your product.</p>
<h3>4. Conversion Boost</h3>
<p>Once you have the content in place, it&#8217;s time to give it a conversion boost. The goal of the website copy is to convert the reader into a buyer (or subscriber, lead, etc.). There are certain things we can do to improve the conversion rate (the percentage of readers that take action) of the copy.</p>
<p>We&#8217;ll use three guides here to make the copy sell better:</p>
<ul>
<li>Conversion frameworks.</li>
<li>Science of persuasion.</li>
<li>Neuromarketing research.</li>
</ul>
<p><a href="http://media.smashingmagazine.com/wp-content/uploads/2012/03/5522310921_f14ef8e261.jpg"><img class="aligncenter size-full wp-image-126873" title="5522310921_f14ef8e261" src="http://media.smashingmagazine.com/wp-content/uploads/2012/03/5522310921_f14ef8e261.jpg" alt="" width="500" height="375" /><br />
<em>Conversion boost. Image credit </em></a><em><a href="http://www.flickr.com/photos/28misguidedsouls/5522310921/sizes/m/in/photostream/">APM Alex</a>.</em></p>
<h4><strong>Conversion Frameworks and Why They Matter</strong></h4>
<p>Conversion frameworks are a structured approach for increasing website conversion rates. The most prominent ones have been fine-tuned over the years and have been proven to boost sales.</p>
<p>While the conversion frameworks apply to a website as a whole, they can also be used as frameworks to improve sales copy.</p>
<p>There are <a href="http://www.invesp.com/conversion-framework.html" target="_blank">many</a> <a href="http://www.widerfunnel.com/conversion-rate-optimization/the-six-landing-page-conversion-rate-factors" target="_blank">conversion</a> <a href="http://www.marketingexperiments.com/methodology-marketingexperiments.html" target="_blank">frameworks</a> around, let&#8217;s use one of them as an example:</p>
<blockquote><p>C = 4m + 3v + 2(i-f) – 2a</p>
</blockquote>
<p>This is not a lesson in physics, but a conversion formula developed by <a href="http://www.marketingexperiments.com/" target="_blank">Marketing Experiments</a>. Translation:</p>
<p>
C = Probability of conversion<br />
m = Motivation of user (when)<br />
v = Clarity of the value proposition (why)<br />
i = Incentive to take action<br />
f = Friction elements of process<br />
a = Anxiety about entering information
</p>
<p>Summary: The probability of conversion depends on the match between the offer and visitor motivation + the clarity of the value proposition + (incentives to take action now&mdash;friction)&mdash;anxiety. The numbers next to each character signify the importance of them.</p>
<p>How to apply this to your copy:</p>
<ul>
<li>Is your value proposition easy to understand and perfectly clear? Would everyone understand what you offer and how it&#8217;s beneficial to them?</li>
<li>Go through your copy and see if there&#8217;s any way to make your statements clearer.</li>
<li>Communicate value: don&#8217;t just list features, turn them into benefits.</li>
<li>Make a list of all possible questions, doubts and objections that prospects might have in the buying process. Address them.</li>
<li>Make the buying or signup process as easy as possible, remove everything that is not absolutely necessary.</li>
<li>Add <a href="http://bokardo.com/archives/writing-microcopy/" target="_blank">microcopy</a>: explain why you need certain data and what happens after they give it to you.</li>
<li>Provide full information: what happens after they buy, what can they expect, when is the product shipped, what&#8217;s the delivery time.</li>
<li>Add risk reversal: what kind of guarantees are in place? What happens if they don&#8217;t like it, or it&#8217;s not what they thought, etc?</li>
</ul>
<h4><strong>The Science of Persuasion</strong></h4>
<p>Persuasion has been researched thoroughly. <a href="http://influenceatwork.com/Book-Dr--Cialdini/Robert-Cialdini,-Ph-D-(1).aspx">Mr. Cialdini</a> is undoubtedly the biggest authority on the field. <a href="http://www.amazon.com/Robert-B.-Cialdini/e/B000AP9KKG/ref=ntt_athr_dp_pel_1" target="_blank">His books</a> are bestsellers and have been on the “must-read” list for marketers and copywriters for years.</p>
<p>In his research, Cialdini came up with six scientific principles of persuasion that will help guide you to become more effective at getting people to do what you want. In case you&#8217;re not familiar with those principles, then here’s the summary:</p>
<p><strong>Principle 1: Reciprocity<br />
</strong>People feel obligated to give back to others who have given to them.<br />
How to use it: teach your prospect something useful in your copy, give away free stuff, and better yet&mdash;add value to your prospects long before you even start to sell them something.</p>
<p><strong>Principle 2: Liking<br />
</strong>We prefer to say “yes” to those we know and like.<br />
How to use it: talk/write like a human, connect with the reader, share details about yourself. Blog. Be friendly and cool (like Richard Branson, Oprah, Gary V).</p>
<p><strong>Principle 3: Social Proof<br />
</strong>People decide what’s appropriate for them to do in a situation by examining and following what others are doing.<br />
How to use it: show how many others are already using your product. Show off your numbers. Use testimonials. Link to 3rd-party articles.</p>
<p><strong>Principle 4: Authority<br />
</strong>People rely on those with superior knowledge or perspective for guidance on how to respond AND what decisions to make.<br />
How to use it: Demonstrate your expertise. Show off your resume and results. Get celebrity (in your niche) endorsements.</p>
<p><strong>Principle 5: Consistency<br />
</strong>Once we make a choice/take a stand, we will encounter personal and interpersonal pressure to behave consistently with that commitment.<br />
How to use it: Start small and move up from there. Sell something small at first (a no-brainer deal), even if you make no money on it. They now see themselves as your customer, and will most likely return to make a larger purchase.</p>
<p><strong>Principle 6: Scarcity<br />
</strong>Opportunities appear more valuable when they are less available.<br />
How to use it: Use time or quantity limited bonuses. Limit access to your product. Promote exclusivity.</p>
<h4><strong>What Neuromarketing Teaches Us</strong></h4>
<p>Research in neuromarketing (<a href="http://www.amazon.com/Neuromarketing-Understanding-Buttons-Customers-Brain/dp/078522680X">put together in this book</a>) reveals interesting things about our brains.</p>
<p><a href="http://media.smashingmagazine.com/wp-content/uploads/2012/03/5546677366_454238c3fb.jpg"><img class="size-full wp-image-126871" title="5546677366_454238c3fb" src="http://media.smashingmagazine.com/wp-content/uploads/2012/03/5546677366_454238c3fb.jpg" alt="" width="500" height="371" /><br />
<em>Neuromarketing study in action. Image credit: </em></a><em><a href="http://www.flickr.com/photos/smieyetracking/5546677366/sizes/m/in/photostream/">SMI Eye Tracking</a>.</em></p>
<p>We’re usually trying to talk to the &#8220;new brain&#8221;&mdash;the sophisticated one&mdash;but it’s the brute &#8220;old brain&#8221; that makes all the decisions, so we need to dumb it down. Here’s the formula for talking to the old brain:</p>
<p><strong>Selling probability</strong> = Pain x Claim x Gain x (Old Brain)<sup>3</sup></p>
<ol>
<li>First you need to identify the prospect’s pain and make sure they acknowledge the pain before you start to sell them anything. Then, you’ve got to differentiate your claims from your competitors. The strongest claim is the one that eliminates the strongest pain.</li>
<li>Next, you have to show convincing proof to back the claims up. The &#8220;Old Brain&#8221; is resistant to new ideas and concepts, so your proof must be very convincing. Show tangible evidence, data, before &amp; after comparisons, testimonials, and case studies.</li>
<li>In order to reach the old brain, you need to start with a &#8220;grabber&#8221;&mdash;something that really <a href="http://conversionxl.com/how-to-grab-and-hold-attention/" target="_blank">gets the attention</a> (&#8220;if you’re selling fire extinguishers, start with fire&#8221;, like Ogilvy said). Second&mdash;the &#8220;Old brain&#8221; is visual, so use a big picture to illustrate and reinforce your message. Visuals get to the brain much faster than words. Best visuals show contrast&mdash;before/after, beginning/end, then/now.</li>
</ol>
<p>How to apply it to your copy:</p>
<ul>
<li>Start with a grabber&mdash;something that evokes emotion.</li>
<li>Address the pain from the get-go.</li>
<li>Use a big picture next to your value proposition, one that the prospect can identify with.</li>
<li>Are your claims different from the competition?</li>
<li>Add proof to your claims in all possible formats.</li>
</ul>
<h3>5. Revise And Rearrange</h3>
<p>Done with conversion boosting? Now enjoy a full night of sleep and come back to the copy in the morning.</p>
<p>A fresh look a day later will help you spot inconsistencies, missing information, and flaws in the general flow of the copy. Use this time to add more information, rearrange the order of different blocks and fix the typos (<a href="http://www.bbc.co.uk/news/education-14130854" target="_blank">spelling mistakes can cost you customers</a>).</p>
<p>Before you publish the sales copy, it always pays to get two or three other people to read it and give you feedback. You want feedback from your ideal customers&mdash;do they get any questions that were left unanswered? Is there any part that needs to be made clearer? And peers&mdash;other marketers or entrepreneurs. What could make the offer better and more credible?</p>
<p>Once the editing is complete, you can make it live on your website. Don&#8217;t guess whether the headline or value propositions are as good as they can be, immediately launch two versions of the copy and test them.</p>
<h3>6. Test</h3>
<p>There is no good way to predict how well the copy will do. Sometimes the conversion rates can skyrocket overnight. Sometimes the new copy turns out to be a downright dud.</p>
<p><a href="http://media.smashingmagazine.com/wp-content/uploads/2012/03/4273968004_4a7b1490c0_b.jpg"><img class="aligncenter size-full wp-image-126869" title="4273968004_4a7b1490c0_b" src="http://media.smashingmagazine.com/wp-content/uploads/2012/03/4273968004_4a7b1490c0_b.jpg" alt="Testing" width="500" height="473" /><br />
<em>You need to test your copy. Image credit </em></a><em><a href="http://www.flickr.com/photos/horiavarlan/4273968004/sizes/l/in/photostream/">Horia Varlan</a>.</em></p>
<p>Maybe it’s because the offer is weak. Perhaps the headline is the bottleneck. It&#8217;s impossible to put the finger on the problem as all you have are hypothesis. The only way to know is to test.</p>
<p>Don&#8217;t trust a copywriter who says he always writes killer copy on his first try. Nobody does.</p>
<p>Most common problems:</p>
<ul>
<li>Your value proposition is poor.</li>
<li>The offer doesn&#8217;t match the audience&#8217;s needs.</li>
<li>The headline is weak.</li>
<li>It&#8217;s not clear how the visitor benefits from this.</li>
</ul>
<p>Start with <a href="http://www.smashingmagazine.com/2010/06/24/the-ultimate-guide-to-a-b-testing/" target="_blank">A/B testing</a> value propositions, and go from there.</p>
<h3>Conclusion</h3>
<p>Writing great copy is a skill you have to learn just like anything else. Use the outline and the tips to get started on the right track. Stephen King, the famous writer, said that if you want to be a writer, you must do two things above all others: read a lot and write a lot. I believe the same goes for writing great copy.</p>
<p>The best Web copy is not the one that uses sophisticated persuasion and mind manipulation techniques. The best copy provides full information about the product, its benefits, and makes it clear whether it&#8217;s the right one for the user.</p>
<p><em>(jvb) (il)</em></p>
<hr />
<p><small>© Peep Laja for <a href="http://www.smashingmagazine.com">Smashing Magazine</a>, 2012.</small></p>
<p><a rel="nofollow" href="http://www.smashingmagazine.com/2012/05/18/quick-course-on-effective-website-copywriting/">Smashing Magazine Feed</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.franciscosamper.com/?feed=rss2&#038;p=441</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Stop Redesigning And Start Tuning Your Site Instead</title>
		<link>http://www.franciscosamper.com/?p=440</link>
		<comments>http://www.franciscosamper.com/?p=440#comments</comments>
		<pubDate>Thu, 17 May 2012 22:02:11 +0000</pubDate>
		<dc:creator>Fran</dc:creator>
				<category><![CDATA[Portfolio]]></category>
		<category><![CDATA[Instead]]></category>
		<category><![CDATA[Redesigning]]></category>
		<category><![CDATA[Site]]></category>
		<category><![CDATA[Start]]></category>
		<category><![CDATA[Stop]]></category>
		<category><![CDATA[Tuning]]></category>

		<guid isPermaLink="false">http://www.franciscosamper.com/?p=440</guid>
		<description><![CDATA[&#160;&#160; In my nearly two decades as an information architect, I’ve seen my clients flush away millions upon millions of&#8230;]]></description>
			<content:encoded><![CDATA[<table width="650">
<tr>
<td width="650">
<div style="width:650px;">
      <img src="http://statisches.auslieferung.commindo-media-ressourcen.de/advertisement.gif" alt="" border="0" /><br />
      <a href="http://auslieferung.commindo-media-ressourcen.de/random.php?mode=target&#038;collection=smashing-rss&#038;position=1" target="_blank"><img src="http://auslieferung.commindo-media-ressourcen.de/random.php?mode=image&#038;collection=smashing-rss&#038;position=1" border="0" alt="" /></a>&nbsp;<a href="http://auslieferung.commindo-media-ressourcen.de/random.php?mode=target&#038;collection=smashing-rss&#038;position=2" target="_blank"><img src="http://auslieferung.commindo-media-ressourcen.de/random.php?mode=image&#038;collection=smashing-rss&#038;position=2" border="0" alt="" /></a>&nbsp;<a href="http://auslieferung.commindo-media-ressourcen.de/random.php?mode=target&#038;collection=smashing-rss&#038;position=3" target="_blank"><img src="http://auslieferung.commindo-media-ressourcen.de/random.php?mode=image&#038;collection=smashing-rss&#038;position=3" border="0" alt="" /></a>
    </div>
</td>
</tr>
</table>
<p>In my nearly two decades as an information architect, I’ve seen my clients flush away millions upon millions of dollars on worthless, pointless, “fix it once and for all” website redesigns. All types of organizations are guilty: large government agencies, Fortune 500s, not-for-profits and (especially) institutions of higher education.</p>
<p>Worst of all, these offending organizations are prone to <strong>repeating the redesign process</strong> every few years like spendthrift amnesiacs. Remember what Einstein said about insanity? (It’s <a href="http://www.brainyquote.com/quotes/quotes/a/alberteins133991.html">this</a>, if you don’t know.) It’s as if they enjoy the sensation of failing spectacularly, publicly and expensively. Sadly, redesigns rarely solve actual problems faced by end users.</p>
<p>I’m frustrated because it really doesn’t have to be this way. Let’s look at why redesigns happen, and some straightforward and inexpensive ways we might avoid them.</p>
<h3>The Diagnostic Void</h3>
<p>Your users complain about your website’s confounding navigation, stale content, poor usability and other user experience failures. You bring up their gripes with the website’s owners. They listen and decide to take action. Their hearts are in the right place. But the wheels quickly come off.</p>
<p><img src="http://media.smashingmagazine.com/wp-content/uploads/2012/05/site_owner.jpg" alt="" title="Site owner" width="486" height="290" class="alignnone size-full wp-image-112168" /></p>
<p>Most website owners don’t know how to diagnose the problems of a large complex website. It’s just not something they were ever taught to do. So, they’re put in the unfortunate, uncomfortable position of operating like country doctors who’ve suddenly been tasked to save their patients from a virulent new pandemic. It is their responsibility, but they’re simply unprepared.</p>
<p><img src="http://media.smashingmagazine.com/wp-content/uploads/2012/05/vendor.jpg" alt="" title="vendor" width="486" height="290" class="alignnone size-full wp-image-112169" /></p>
<p>Sadly, many website owners fill this diagnostic void &mdash; or, more typically, allow it to be filled &mdash; with whatever solution sounds best. Naturally, many less-than-ethical vendors are glad to dress up their offerings as solutions to anyone with a problem &mdash; and a budget. The tools themselves (search engines, CMS’, social apps) are wonderful, but they’re still <strong>just tools</strong> &mdash; very expensive ones, at that &mdash; and not solutions to the very specific problems that an organization faces. Without proper diagnostics to guide the configuration of tools, any resulting improvements to the user experience will be almost accidental.</p>
<p><img src="http://media.smashingmagazine.com/wp-content/uploads/2012/05/design_agency.jpg" alt="" title="design_agency" width="486" height="290" class="alignnone size-full wp-image-112170" /></p>
<p>Sometimes design agencies are brought in to fill the diagnostic void. And while not all agencies are evil, a great many follow a business model that depends on getting their teams to bill as many hours as they can and as soon as possible. Diagnostics can slow the work down (which is why clients rarely include a diagnostic phase in their RFPs). So, many agencies move to make a quick, tangible impression (and make their clients happy) by delivering redesigns that are <strong>mostly cosmetic</strong>.</p>
<p>A pretty face can last only a few years, but by then the agency is long gone. Invariably, the new owner wishes to make their mark by freshening or updating the website’s look. And another agency will be more than happy to oblige. Repeat ad nauseam, and then some.</p>
<p>Oh, and sometimes these redesigns can be pricey. Like <a href="http://usability.com/2012/01/31/four-seasons-18m-redesign-is-taking-a-lot-of-heat/">$  18 million pricey</a>.</p>
<p>See why I’m so grouchy?</p>
<h3>Forget the Long Tail: The Short Head Is Where It’s At</h3>
<p>Whether you’re a designer, researcher or website owner, I’ve got some good news for you: diagnostics aren’t necessarily difficult or expensive. Better yet, you’ll often find that addressing the problems you’ve diagnosed isn’t that hard.</p>
<p>And the best news? Small simple fixes can accomplish far more than expensive redesigns. The reason? People just care about some stuff more than they care about other stuff. A lot more. Check this out and you’ll see:</p>
<p><img src="http://media.smashingmagazine.com/wp-content/uploads/2012/05/Monster-Main.jpg" alt="" title="Monster-Main" width="500" height="380" class="alignnone size-full wp-image-112185" /></p>
<p>This hockey-stick-shaped curve is called a Zipf curve. (It <a href="http://en.wikipedia.org/wiki/Zipf%27s_law">comes from linguistics</a>: Zipf was a linguist who liked to count words… but don’t worry about that.) Here it is in dragon form, displaying the frequency of search queries on a website. The most frequently searched queries (starting on the left) are very, very frequent. They make up the “short head.” As you move to the right (to the esoteric one-off queries in the “long tail”), query frequency drops off. A lot. And it’s a really long tail.</p>
<p><img src="http://media.smashingmagazine.com/wp-content/uploads/2012/05/Monster-2.jpg" alt="" title="Monster-2" width="500" height="70" class="alignnone size-full wp-image-112186" /></p>
<p>This is absolutely the most important thing in the universe. So, to make sure it’s absolutely clear, let’s make the same point using text:</p>
<table border="1">
<tbody>
<tr>
<th>Query’s rank</td>
<th>Cumulative %</th>
<th>Query’s frequency</th>
<th>Query</th>
</tr>
<tr>
<td>1</td>
<td>1.40%</td>
<td>7,218</td>
<td>campus map</td>
</tr>
<tr>
<td>14</td>
<td>10.53%</td>
<td>2,464</td>
<td>housing</td>
</tr>
<tr>
<td>42</td>
<td>20.18%</td>
<td>1,351</td>
<td>web enroll</td>
</tr>
<tr>
<td>98</td>
<td>30.01%</td>
<td>650</td>
<td>computer center</td>
</tr>
<tr>
<td>221</td>
<td>40.05%</td>
<td>295</td>
<td>msu union</td>
</tr>
<tr>
<td>500</td>
<td>50.02%</td>
<td>124</td>
<td>hotels</td>
</tr>
<tr>
<td>7,877</td>
<td>80.00%</td>
<td>7</td>
<td>department of surgery</td>
</tr>
</tbody>
</table>
<p>In this case, tens of thousands of unique queries are being searched for on this <a href="http://www.msu.edu/">university website</a>, but the first one accounts for 1.4% of all search traffic. That’s massive, considering that it’s just one query out of tens of thousands. How many short-head queries would it take to get to 10% of all search traffic? Only 14 &mdash; out of tens of thousands. The 42 most frequent queries cover over 20% of the website’s entire search traffic. About a hundred gets us to 30%. And so on.</p>
<h3>It’s Zipf’s World; We Just Live in It</h3>
<p>This is very good news.</p>
<p>Want to improve your website’s search performance? Don’t rip out the search engine and buy a new one! Start by testing and <strong>improving the performance</strong> of the 100 most frequent queries. Or, if you don’t have the time, just the top 50. Or 10. Or 1 &mdash; test out “campus map” by actually <a href="http://search.msu.edu/index.php?q=campus+map">searching for it</a>. Does something useful and relevant come up? No? Why not? Is the content missing or mistitled or mistagged or jargony or broken? Is there some other problem? That, folks, is diagnostics. And when you do that with your website’s short head, your diagnostic efforts will go a very long way.</p>
<p>The news gets better: Zipf is a rule. The search queries for all websites follow a Zipf distribution.</p>
<p>And the news gets even jump-up-and-down-and-scream-your-head-off better: Zipf is true not only for your website’s search queries. <strong>Your content</strong> works the same way! A small subset of your website’s content does the heavy lifting. Much of the rest has little or no practical value at all. (In fact, I’ve heard a rumor that 90% of Microsoft.com’s content has never, ever been accessed. Not once. But it’s a just a rumor. And you didn’t hear it here.) Bottom line: don’t redesign <em>all</em> of your content &mdash; focus on the stuff that people actually need.</p>
<p>You’ll also see a short head when it comes to your website’s features. People need just a few of them; the rest are gravy.</p>
<p>And there’s more. Of all the <strong>audience types</strong> that your website serves, one or two matter far more than the others. What tasks do those audience types wish to accomplish on your website? A few are short-head tasks; the rest just aren’t that important.</p>
<p>As you can see, the Zipf curve is everywhere. And fortunately, the phenomenon is helpful: you can use it to prioritize your efforts to tweak and tune your website’s content, functionality, searchability, navigation and overall performance.</p>
<p><img src="http://media.smashingmagazine.com/wp-content/uploads/2012/05/Monster-3.jpg" alt="" title="Monster-3" width="500" height="125" class="alignnone size-full wp-image-112187" /></p>
<h3>Your Website Is Not A Democracy</h3>
<p>When you examine the short head &mdash; of your documents, your users’ tasks, their search behavior and so forth &mdash; you’ll know where to find the most important problems to solve. In effect, you can stop boiling the ocean…</p>
<p><img src="http://media.smashingmagazine.com/wp-content/uploads/2012/05/ocean.jpg" alt="Ocean" title="Ocean" width="500" height="265" class="alignnone size-full wp-image-112226" /></p>
<p>… and start prioritizing your efforts to diagnose and truly solve your website’s problems.</p>
<p>Now, let’s put these short-head ideas together. Below is a report card for an academic website that starts with the short head of its audience:</p>
<p><a href="http://media.smashingmagazine.com/wp-content/uploads/2012/05/Table-big.jpg"><img src="http://media.smashingmagazine.com/wp-content/uploads/2012/05/Diagram.jpg" alt="" title="Diagram" width="500" height="350" class="alignnone size-full wp-image-112189" /></a></p>
<p>In other words, of all the audience types this university website has, the three most important are people who might pay money to the university (applicants,) people who are paying money now (students) and people who will hopefully pay money for the rest of their lives (alumni). How do we know they’re the <strong>most important audiences</strong>? We could go by user research; for example, the analytics might suggest that these audiences generate more traffic than anyone else. Or perhaps the university’s stakeholders believe that these are the most important ones in their influence and revenue. Or some combination of both. Whatever the case, these three audiences likely swamp all other segments in importance.</p>
<p>Then, we would want to know the short-head tasks and information needs of each audience type. We might interview stakeholders to see what they think (column 2). And we might perform research &mdash; user interviews and search analytics, for example &mdash; to find out what users say is most important to them (column 3).</p>
<p>Of course, as the good folks at <a href="http://xkcd.com/773/">xkcd demonstrate</a>, stakeholders and users don’t always see things the same way:</p>
<p><a href="http://xkcd.com/773/"><img src="http://media.smashingmagazine.com/wp-content/uploads/2012/05/Univ_site.jpg" alt="" title="Univ_site" width="500" height="350" class="alignnone size-full wp-image-112205" /></a></p>
<p>That’s why talking to both stakeholders and users is important. And once you’ve figured out the short head for each, you’ll need to earn your salary and, through some careful negotiation, combine your takes on each audience type’s needs. That’s what we’ve done in column 4.</p>
<p>Finally, in column 5, we’ve tested each task or need and evaluated how well it works. (Because it’s a university-related example, letter grades seemed appropriate.) You can do this evaluation in an expensive, statistically significant way; but really, <a href="http://www.useit.com/alertbox/discount-usability.html">enough research</a> is <a href="http://uxmag.com/articles/getting-guerrilla-with-it">out there</a> to suggest that you don’t need to spend a lot of time and money on such testing. More importantly, these needs and tasks are often fairly narrow and, therefore, easy to test.</p>
<p>So, after testing, we can see what’s not going well. Finding information on “mentoring” is hard for applicants. And current students have a devil of a time when they “look up grades.”</p>
<p>Now we’re done diagnosing the problems and can begin making fixes. We can change the title of the “Paired Guidance Program” page to “Mentoring.” We can create a better landing page for the transcript application. The hard part, diagnostics, is out of the way, and we can <strong>now fix and tune</strong> our website’s performance as much as our resources allow.</p>
<p><img src="http://media.smashingmagazine.com/wp-content/uploads/2012/05/Monster-4.jpg" alt="" title="Monster-4" width="500" height="82" class="alignnone size-full wp-image-112190" /></p>
<h3>From Project To Process To Payoff</h3>
<p>These fixes are typically and wonderfully small and concrete, but because they live in the short head, they make a huge and lovely impact on the user experience &mdash; at a fraction of the cost of a typical redesign.</p>
<p>The <strong>tuning process</strong> itself is quite simple. It’s what we used to arrive at the report card below:</p>
<p><img src="http://media.smashingmagazine.com/wp-content/uploads/2012/05/Chart.jpg" alt="" title="Chart" width="486" height="190" class="alignnone size-full wp-image-112191" /></p>
<p>If you repeat this simple process on a regular basis &mdash; say, every month or quarter &mdash; then you can head off the entropy that causes fresh designs and fresher content to go rotten. Thus, the redesign that your organization has scheduled for two years from now can officially be canceled.</p>
<p>Your website’s owners ought to be happy about all this. And you should be, too: rather than tackling the project of getting your website “right” &mdash; which is impossible &mdash; you can now focus on tweaking and tuning it from here on out. So, forget redesigns, and start owning and benefiting from a process of continual improvement.</p>
<p><img src="http://media.smashingmagazine.com/wp-content/uploads/2012/05/Monster-end.jpg" alt="" title="Monster-end" width="500" height="82" class="alignnone size-full wp-image-112192" /></p>
<h4>Special Thanks &#8211; Illustrations</h4>
<p><a href="http://www.evalotta.net/" title="Eva-Lotta">Eva-Lotta</a> is a UX Designer and Illustrator based in London, UK where she currently works as an interaction designer at Google. Besides her daytime mission of making the web a more understandable, usable and delightful place, she regularly takes <a href="http://www.flickr.com/photos/evalottchen/sets/72157607235674386/with/6848813489/" title="Sketchnotes">sketchnotes</a> at all sorts of talks and conferences and recently self-published her <a href="http://www.sketchnotesbook.com/" title="Book">second book</a>. Eva-Lotta also  teaches sketching workshops and is interested in (something she calls) visual improvisation. Exploring the parallels between sketching and improvisation, she experiments with the principles from her theater improvisation practice to inspire visual work. </p>
<p><em>(al)</em></p>
<hr />
<p><small>© Louis Rosenfeld for <a href="http://www.smashingmagazine.com">Smashing Magazine</a>, 2012.</small></p>
<p><a rel="nofollow" href="http://www.smashingmagazine.com/2012/05/16/stop-redesigning-and-start-tuning-your-site-instead/">Smashing Magazine Feed</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.franciscosamper.com/?feed=rss2&#038;p=440</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Responsive Images and Web Standards at the Turning Point</title>
		<link>http://www.franciscosamper.com/?p=439</link>
		<comments>http://www.franciscosamper.com/?p=439#comments</comments>
		<pubDate>Wed, 16 May 2012 22:37:05 +0000</pubDate>
		<dc:creator>Fran</dc:creator>
				<category><![CDATA[Portfolio]]></category>
		<category><![CDATA[images]]></category>
		<category><![CDATA[Point]]></category>
		<category><![CDATA[Responsive]]></category>
		<category><![CDATA[Standards]]></category>
		<category><![CDATA[Turning]]></category>

		<guid isPermaLink="false">http://www.franciscosamper.com/?p=439</guid>
		<description><![CDATA[Responsible responsive design demands responsive images—images whose dimensions and file size suit the viewport and bandwidth of the receiving device.&#8230;]]></description>
			<content:encoded><![CDATA[<p>Responsible responsive design demands responsive images—images whose dimensions and file size suit the viewport and bandwidth of the receiving device. As HTML provides no standard element to achieve this purpose, serving responsive images has meant using JavaScript trickery, and accepting that your solution will fail for some users.</p>
<p>Then a few months ago, in response to an article here, a W3C Responsive Images Community Group formed—and proposed a simple-to-understand HTML picture element capable of serving responsive images. The group even delivered picture functionality to older browsers via two polyfills: namely, Scott Jehl’s Picturefill and Abban Dunne’s jQuery Picture. The WHATWG has responded by ignoring the community’s work on the picture element, and proposing a more complicated img set element.</p>
<p>Which proposed standard is better, and for whom? Which will win? And what can you do to help avert an “us versus them” crisis that could hurt end-users and turn developers off to the standards process? ALA’s own Mat Marquis explains the ins and outs of responsive images and web standards at the turning point.<br />
<a rel="nofollow" href="http://www.alistapart.com/articles/responsive-images-and-web-standards-at-the-turning-point/">A List Apart</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.franciscosamper.com/?feed=rss2&#038;p=439</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Zocial Button Set: 72 CSS3 Buttons</title>
		<link>http://www.franciscosamper.com/?p=438</link>
		<comments>http://www.franciscosamper.com/?p=438#comments</comments>
		<pubDate>Tue, 15 May 2012 22:33:08 +0000</pubDate>
		<dc:creator>Fran</dc:creator>
				<category><![CDATA[Portfolio]]></category>
		<category><![CDATA[Button]]></category>
		<category><![CDATA[buttons]]></category>
		<category><![CDATA[Zocial]]></category>
		<category><![CDATA[“CSS3”]]></category>

		<guid isPermaLink="false">http://www.franciscosamper.com/?p=438</guid>
		<description><![CDATA[&#160;&#160; The idea behind this project was to produce a consistent set of buttons that could be used for the&#8230;]]></description>
			<content:encoded><![CDATA[<table width="650">
<tr>
<td width="650">
<div style="width:650px;">
      <img src="http://statisches.auslieferung.commindo-media-ressourcen.de/advertisement.gif" alt="" border="0" /><br />
      <a href="http://auslieferung.commindo-media-ressourcen.de/random.php?mode=target&#038;collection=smashing-rss&#038;position=1" target="_blank"><img src="http://auslieferung.commindo-media-ressourcen.de/random.php?mode=image&#038;collection=smashing-rss&#038;position=1" border="0" alt="" /></a>&nbsp;<a href="http://auslieferung.commindo-media-ressourcen.de/random.php?mode=target&#038;collection=smashing-rss&#038;position=2" target="_blank"><img src="http://auslieferung.commindo-media-ressourcen.de/random.php?mode=image&#038;collection=smashing-rss&#038;position=2" border="0" alt="" /></a>&nbsp;<a href="http://auslieferung.commindo-media-ressourcen.de/random.php?mode=target&#038;collection=smashing-rss&#038;position=3" target="_blank"><img src="http://auslieferung.commindo-media-ressourcen.de/random.php?mode=image&#038;collection=smashing-rss&#038;position=3" border="0" alt="" /></a>
    </div>
</td>
</tr>
</table>
<p>The idea behind this project was to produce a consistent set of buttons that could be used for the range of social actions frequently taken in Web applications. These actions are often important goals for users, such as connecting third-party accounts or sharing content to third-party platforms, so their appearance has to be attractive and clear.</p>
<p>The standard buttons provided by third parties (such as Facebook, Twitter and SoundCloud) vary in size, style and interactivity. A consistent button set could reduce a lot of that visual noise and inconsistency. Furthermore, having it in CSS format means that changing the text for certain actions would be a breeze for developers, and it also allows administrators of non-English websites to translate labels into their native languages.</p>
<p>The button set was designed from the beginning to require no extra markup, and the elements used are entirely the choice of the (semantically considerate) designer. All buttons are fully scalable and customizable, and they degrade gracefully on older browsers, although the aesthetics in IE 6 and 7 are admittedly inferior to image-based alternatives.</p>
<p>No raster images or sprites were used. Instead, vector icons were inserted using a custom font file, an @font-face rule and pseudo elements. For more information, John Hicks has an <a href="http://24ways.org/2011/displaying-icons-with-fonts-and-data-attributes">informative write-up</a> on this technique.</p>
<h3>Download The Button Set For Free</h3>
<p>This button set is free to use and extend, personally or commercially. No attribution is required.</p>
<ul>
<li><a href="http://media.smashingmagazine.com/wp-content/uploads/2012/02/Zocial-CSS3-Buttons-full-screenshot.png">Preview</a></li>
<li><a href="http://zocial.smcllns.com/sample.html">Demo</a></li>
<li><a href="http://zocial.smcllns.com/Zocial-CSS-Buttons.zip">Download the package</a> (ZIP, 147 KB)</li>
<li><a href="http://github.com/samcollins/css-social-buttons">GitHub repository</a> (handwritten CSS)</li>
<li><a href="https://github.com/adamstac/zocial">Sass framework</a> (six buttons) (by <a href="https://twitter.com/adamstac">@adamstac</a>)</li>
</ul>
<h3>Features</h3>
<ul>
<li>100%-vector CSS3 buttons</li>
<li>@font-face icons and custom font files</li>
<li>72 services supported</li>
<li>Button and icon versions supported</li>
<li>Em sizing for full scalability</li>
<li>Generic primary and secondary action buttons for consistency</li>
<li>Graceful degradation on older browsers</li>
</ul>
<h3>Preview</h3>
<p>Screenshots of each set are below. Or <a href="http://zocial.smcllns.com/sample.html">view a live demo</a>.</p>
<p><a href="http://media.smashingmagazine.com/wp-content/uploads/2012/02/zocial-screenshot-set-11.png"><img class="alignnone size-full wp-image-124057" title="zocial-screenshot-set-1" src="http://media.smashingmagazine.com/wp-content/uploads/2012/02/zocial-screenshot-set-11.png" alt="" width="500" height="166" /></a></p>
<p><a href="http://media.smashingmagazine.com/wp-content/uploads/2012/02/zocial-screenshot-set-21.png"><img class="alignnone size-full wp-image-124058" title="zocial-screenshot-set-2" src="http://media.smashingmagazine.com/wp-content/uploads/2012/02/zocial-screenshot-set-21.png" alt="" width="500" height="486" /></a></p>
<p><a href="http://media.smashingmagazine.com/wp-content/uploads/2012/02/zocial-screenshot-set-31.png"><img class="alignnone size-full wp-image-124059" title="zocial-screenshot-set-3" src="http://media.smashingmagazine.com/wp-content/uploads/2012/02/zocial-screenshot-set-31.png" alt="" width="500" height="216" /></a></p>
<p><a href="http://media.smashingmagazine.com/wp-content/uploads/2012/02/zocial-screenshot-set-41.png"><img class="alignnone size-full wp-image-124060" title="zocial-screenshot-set-4" src="http://media.smashingmagazine.com/wp-content/uploads/2012/02/zocial-screenshot-set-41.png" alt="" width="500" height="395" /></a></p>
<p><a href="http://media.smashingmagazine.com/wp-content/uploads/2012/02/zocial-screenshot-set-51.png"><img class="alignnone size-full wp-image-124061" title="zocial-screenshot-set-5" src="http://media.smashingmagazine.com/wp-content/uploads/2012/02/zocial-screenshot-set-51.png" alt="" width="500" height="303" /></a></p>
<p><a href="http://media.smashingmagazine.com/wp-content/uploads/2012/02/zocial-screenshot-set-61.png"><img class="alignnone size-full wp-image-124062" title="zocial-screenshot-set-6" src="http://media.smashingmagazine.com/wp-content/uploads/2012/02/zocial-screenshot-set-61.png" alt="" width="500" height="170" /></a></p>
<p><a href="http://media.smashingmagazine.com/wp-content/uploads/2012/02/zocial-screenshot-set-71.png"><img class="alignnone size-full wp-image-124063" title="zocial-screenshot-set-7" src="http://media.smashingmagazine.com/wp-content/uploads/2012/02/zocial-screenshot-set-71.png" alt="" width="500" height="438" /></a></p>
<p><a href="http://media.smashingmagazine.com/wp-content/uploads/2012/02/zocial-screenshot-set-81.png"><img class="alignnone size-full wp-image-124064" title="zocial-screenshot-set-8" src="http://media.smashingmagazine.com/wp-content/uploads/2012/02/zocial-screenshot-set-81.png" alt="" width="500" height="169" /></a></p>
<p><a href="http://media.smashingmagazine.com/wp-content/uploads/2012/02/zocial-screenshot-set-91.png"><img class="alignnone size-full wp-image-124065" title="zocial-screenshot-set-9" src="http://media.smashingmagazine.com/wp-content/uploads/2012/02/zocial-screenshot-set-91.png" alt="" width="500" height="390" /></a></p>
<h3>Usage</h3>
<p>The button set was designed with simplicity and semantics in mind. No unnecessary or extra markup is required, and button types are called through class names. Call the <code>zocial.css</code> file on your page (make sure the font files and the <code>zocial.css</code> file are in the same directory). Buttons can be displayed with the following markup:</p>
<pre class="brush: html">
&lt;button class="zocial facebook"&gt;Sign in with Facebook&lt;/button&gt;
</pre>
<p>The parent element is agnostic, so you may use <code>&lt;a&gt;</code>, <code>&lt;div&gt;</code> or <code>&lt;button&gt;</code><del>, but it must contain a child <code>&lt;span&gt;</code> element</del>. [Thanks, <a href="http://twitter.com/LeaVerou">Lea</a>!]</p>
<p>To choose buttons from the set, include the appropriate class name for the service, such as <code>.dropbox</code>, <code>.linkedin</code> or <code>.twitter</code>.</p>
<p>Icon versions can be displayed by including an extra <code>.icon</code> class, as follows:</p>
<pre class="brush: html">
&lt;a class="zocial quora icon"&gt;Follow me on Quora&lt;/a&gt;
</pre>
<p>More code samples are available on the <a href="http://zocial.smcllns.com">Zocial page</a>.</p>
<p><em>(al)</em></p>
<hr />
<p><small>© Sam Collins for <a href="http://www.smashingmagazine.com">Smashing Magazine</a>, 2012.</small></p>
<p><a rel="nofollow" href="http://www.smashingmagazine.com/2012/05/15/zocial-button-set-72-css3-buttons/">Smashing Magazine Feed</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.franciscosamper.com/?feed=rss2&#038;p=438</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Say No to Faux Bold</title>
		<link>http://www.franciscosamper.com/?p=437</link>
		<comments>http://www.franciscosamper.com/?p=437#comments</comments>
		<pubDate>Mon, 14 May 2012 23:40:25 +0000</pubDate>
		<dc:creator>Fran</dc:creator>
				<category><![CDATA[Portfolio]]></category>
		<category><![CDATA[Bold]]></category>
		<category><![CDATA[Faux]]></category>

		<guid isPermaLink="false">http://www.franciscosamper.com/?p=437</guid>
		<description><![CDATA[Browsers can do terrible things to type. If text is styled as bold or italic and the typeface family does&#8230;]]></description>
			<content:encoded><![CDATA[<p>Browsers can do terrible things to type. If text is styled as bold or italic and the typeface family does not include a bold or italic font, browsers will compensate by trying to create bold and italic styles themselves. The results are an awkward mimicry of real type design, and can be especially atrocious with web fonts. Adobe’s Alan Stearns shares quick tips and techniques to ensure that your @font-face rules match the weight and styles of the fonts, and that you have a @font-face rule for every style your content uses. If you’re taking the time to choose a beautiful web font for your site, you owe it to yourself and your users to make certain you’re actually using the web font — and only the web font — to display your site’s content in all its glory.<br />
<a rel="nofollow" href="http://www.alistapart.com/articles/say-no-to-faux-bold/">A List Apart</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.franciscosamper.com/?feed=rss2&#038;p=437</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Taming The Wild Mind</title>
		<link>http://www.franciscosamper.com/?p=436</link>
		<comments>http://www.franciscosamper.com/?p=436#comments</comments>
		<pubDate>Sun, 13 May 2012 23:03:38 +0000</pubDate>
		<dc:creator>Fran</dc:creator>
				<category><![CDATA[Portfolio]]></category>
		<category><![CDATA[Mind]]></category>
		<category><![CDATA[Taming]]></category>
		<category><![CDATA[Wild]]></category>

		<guid isPermaLink="false">http://www.franciscosamper.com/?p=436</guid>
		<description><![CDATA[&#160;&#160; Myths have developed around and researchers have studied how the human brain juggles creativity and organization. Popular theory tells&#8230;]]></description>
			<content:encoded><![CDATA[<table width="650">
<tr>
<td width="650">
<div style="width:650px;">
      <img src="http://statisches.auslieferung.commindo-media-ressourcen.de/advertisement.gif" alt="" border="0" /><br />
      <a href="http://auslieferung.commindo-media-ressourcen.de/random.php?mode=target&#038;collection=smashing-rss&#038;position=1" target="_blank"><img src="http://auslieferung.commindo-media-ressourcen.de/random.php?mode=image&#038;collection=smashing-rss&#038;position=1" border="0" alt="" /></a>&nbsp;<a href="http://auslieferung.commindo-media-ressourcen.de/random.php?mode=target&#038;collection=smashing-rss&#038;position=2" target="_blank"><img src="http://auslieferung.commindo-media-ressourcen.de/random.php?mode=image&#038;collection=smashing-rss&#038;position=2" border="0" alt="" /></a>&nbsp;<a href="http://auslieferung.commindo-media-ressourcen.de/random.php?mode=target&#038;collection=smashing-rss&#038;position=3" target="_blank"><img src="http://auslieferung.commindo-media-ressourcen.de/random.php?mode=image&#038;collection=smashing-rss&#038;position=3" border="0" alt="" /></a>
    </div>
</td>
</tr>
</table>
<p>Myths have developed around and researchers have studied how the human brain juggles creativity and organization. Popular theory tells us that the left brain is structured and logical, while the right brain is artistic and imaginative, and that all human beings use predominantly one side of the other.</p>
<p>Working in a creative field means challenging that theory, or else challenging the schedules and deadlines that managers impose on writers, designers and other creatives. As a project manager in a UX design agency, as well as a writer, I believe it is necessary to challenge both the assumptions about schedules and the belief that creativity implies disorganization.</p>
<h3>Can Creativity Be Scheduled?</h3>
<p>There’s a quick and easy answer to this question. Yes!</p>
<p>You’re shaking your head now. You’re thinking about how much you hate deadlines and how your designs suffer from the 9:00 to 5:00 schedule imposed by your manager. You’re remembering the sketches or creative writing you did in college at 3:00 in the morning. Sathish Manohar expresses it well in his article “<a href="http://sathishmanohar.com/why-9-to-5/">Why 9 to 5</a>”:</p>
<blockquote>
<p>&#8220;Knowledge work solely depends on creativity of the workers. But, still some how, knowledge work-places got modeled around factories. Employees had to work 9-5, be creative between 9-5, and go home… This is a problem, We cannot schedule the brain to be creative at any given time.&#8221;</p>
</blockquote>
<p>Yet I’ve spent years trying to merge my creative-writing personality with my project-management skill set and day job. Recently I realized that writing by the light of the moon results in over-caffeinated mornings and sloppy grammar, and still I continued&mdash;after all, isn’t that what creativity is all about? I’ve always been able to empathize with my designers, who want nothing more than free reign to be creative when the mood hits. But as a project manager, I also strive to create a working environment where designers and content strategists can be productive and efficient&mdash;and where we can deliver mockups on a deadline.</p>
<p>The solution turned out to be easier than you might expect. Spontaneous creativity is not the only way. In fact, as a content strategist, designer or even developer, you are paid for your ability to turn on the creative faucet. So, what goes into creating on command?</p>
<p><a href="http://media.smashingmagazine.com/wp-content/uploads/2012/02/CalvinHobbes.png"><img class="alignnone  wp-image-125449" title="CalvinHobbes" src="http://media.smashingmagazine.com/wp-content/uploads/2012/02/CalvinHobbes.png" alt="" width="648" height="205" /></a></p>
<h3>1. Create A Routine</h3>
<blockquote>
<p>&#8220;Be regular and orderly in your life so that you may be violent and original in your work.&#8221;</p>
<p>&ndash; Gustave Flaubert, author</p>
</blockquote>
<p>Flaubert did not write on a deadline, and yet he found that following an orderly routine improved his ability to be creative. This holds true for most people. Being able to “do your best work” at 3:00 am is no coincidence: you are training your brain to get those creative juices flowing when the moon is high and the workday is long over. This is fantastic if you don’t have anywhere to be in the morning; but for many of us, 3:00 am is not a great time to be inspired.</p>
<p>Instead, develop a routine that trains your creative juices to kick in at more convenient times. This could mean setting the alarm for 8:00 am, making breakfast and then sitting down with a journal to begin sketching as you eat. It could mean emailing yourself a to-do list before bed, with inspirational quotes to greet you the moment you open your email. Maybe you need a lunchtime scrum every day to energize and focus. Within two weeks, these mini-kickoffs will begin to signal to your brain, “Now is when we begin the creative work of the day.”</p>
<h3>2. Take Your Time</h3>
<blockquote>
<p>&#8220;A single meeting can blow a whole afternoon, by breaking it into two pieces each too small to do anything.&#8221;</p>
<p>&ndash; Paul Graham, essayist and programmer</p>
</blockquote>
<p>Distractions are a powerful creativity-blocker. Even the best routine can be waylaid by mandatory meetings, important phone calls and constant emails. If you are a freelancer in charge of your own schedule, try to relegate meetings to the very beginning or end of the day. If a manager schedules your client meetings and internal reviews, talk to them about the benefits of opening up large blocks of time for creative work.</p>
<p>At Above the Fold, we make a point of scheduling around the “maker’s schedule.” Paul Graham sums up the maker’s schedule in his essay, “<a href="http://www.paulgraham.com/makersschedule.html">Maker’s Schedule, Manager’s Schedule</a>”:</p>
<blockquote>
<p>&#8220;When you’re operating on the maker’s schedule, meetings are a disaster. A single meeting can blow a whole afternoon, by breaking it into two pieces each too small to do anything hard in. Plus you have to remember to go to the meeting. That’s no problem for someone on the manager’s schedule. There’s always something coming on the next hour; the only question is what. But when someone on the maker’s schedule has a meeting, they have to think about it…. I find one meeting can sometimes affect a whole day. A meeting commonly blows at least half a day, by breaking up a morning or afternoon.&#8221;</p>
</blockquote>
<p>Therefore, at Above the Fold, we hold internal reviews at 5:00 pm, check-in meetings at lunchtime, and client calls first thing in the morning. This gives our creative team the time they crave to get engrossed in projects, without interruption.</p>
<p>This doesn’t solve the issue of interruption via email, of course. Try scheduling specific “Check email” times into your day&mdash;again, first thing in the morning, just before your lunch break or at the end of the day works well. Make sure your team is aware that you will not be responding to emails immediately, and suggest they call you or come find you if something is urgent and relevant to the current project. Team members can be surprisingly understanding and can quickly grasp the difference between imperative and interesting.</p>
<h3>3. Use Your Team</h3>
<blockquote>
<p>&#8220;Separate brainstorming (idea generation) from synthesis (putting it all into a flowing post).&#8221;</p>
<p>&ndash; Tim Ferriss, author</p>
</blockquote>
<p>Having large blocks of time available and scheduling them into your day sounds well and good, but how do you convince your brain that the time has come to get in the zone and ignore distractions?</p>
<p><a href="http://media.smashingmagazine.com/wp-content/uploads/2012/02/Jumpingbrain.jpg"><img class="aligncenter  wp-image-126829" title="Jumpingbrain" src="http://media.smashingmagazine.com/wp-content/uploads/2012/02/Jumpingbrain.jpg" alt="" width="491" height="419" /></a></p>
<p>Taking a page out of the Agile development book, try starting with a variation on <a href="http://pivotallabs.com/how/pair_programming">pair programming</a>. Pair programming is designed to help developers break down complex tangles of code with the simple rationale that two heads are better than one. The same is true for kicking off any other sort of creative block of time. Instead of working together all day, kick off the day with a 10-minute group brainstorming session. Nothing focuses the creative mind faster than talking through project details, and 10 minutes can lead to a far more productive three hours of synthesis.</p>
<p>Don’t have a team to kick around ideas with? Hit up a few colleagues on Twitter or Skype. We have found that many in the content and design worlds are happy to help, and you can offer to help in return.</p>
<h3>4. Warm Up Your Muscles</h3>
<blockquote>
<p>&#8220;Major league players aren’t the only professionals that regularly practice. We’ve met musicians, firemen, pilots, and surgeons, all of who regularly practice their skills.&#8221;</p>
<p>&ndash; Jared M. Spool, founding principal of <a href="http://www.uie.com/">User Interface Engineering</a></p>
</blockquote>
<p>Athletes warm up their muscles before starting their real work, and so should creative thinkers. A good warm-up helps you practice basic skills, focus your mind and improve the work to come. In addition, taking 10 minutes to warm up allows you to separate your ideas from the plethora of ideas surrounding you.</p>
<p>A few hundred years ago, visual stimulation was hard to come by, and artists were influenced primarily by their surroundings. Now, our surroundings contain hundreds of representations of our surroundings and of other people’s interpretations of their surroundings. Finding your own voice can be difficult amid the clutter.</p>
<p><a href="http://media.smashingmagazine.com/wp-content/uploads/2012/03/6203341314_22a76e5462.jpg"><img class="aligncenter size-full wp-image-128671" title="6203341314_22a76e5462" src="http://media.smashingmagazine.com/wp-content/uploads/2012/03/6203341314_22a76e5462.jpg" alt="" width="500" height="338" /></a></p>
<p>The following quick <a href="http://www.uie.com/articles/ux_practicing/">warm-ups</a> can bring you back to basics and isolate what makes your creative voice unique. Some of these suggestions even include using someone else’s work as a starting point&mdash;but making it your own.</p>
<ol>
<li>Write your thoughts down in a journal.</li>
<li>Doodle for 10 minutes in a sketchpad.</li>
<li>Copy the first sentence of a book, and then write a one-page story that begins with that sentence.</li>
<li>Create three variations of a landing page based on different mood themes (happy, scary, sad, etc.).</li>
</ol>
<p>None of these warm-ups should take more than 10 minutes, and each offers a different way to reconnect you to your creative spirit. From here, you might find it easier to begin thinking about new and different ideas, and even jumpstarting a project that has felt stale.</p>
<h3>5. Save The Best For Last</h3>
<blockquote>
<p>&#8220;Laziness in a white collar job has nothing to do with avoiding hard physical labor. “Who wants to help me move this box!” Instead, it has to do with avoiding difficult (and apparently risky) intellectual labor.&#8221;</p>
<p>&ndash; Seth Godin, entrepreneur, author and speaker</p>
</blockquote>
<p>Most creative jobs come with a catch, such as having to respond to client emails, send invoices or email writing samples. It’s not uncommon for these boring, “uncreative” tasks to turn into a means of procrastination. You feel as though you can’t set a task aside because it must be done; but because you don’t want to do it, you procrastinate&mdash;effectively avoiding both your creative work and your busywork.</p>
<p>Invoices and emails and bills are quick tasks, so we don’t feel as though delaying them by an hour or two costs much. But the hour you spend avoiding a five-minute task eats away at your creative time. What’s more frightening is the possibility that you’re actively using these tasks to avoid your creative work. As Seth Godin explains, this is <a href="http://sethgodin.typepad.com/seths_blog/2010/01/quieting-the-lizard-brain.html">due to “lizard brain”</a>:</p>
<blockquote>
<p>&#8220;The [lizard brain, or resistance,] is the voice in the back of our head telling us to back off, be careful, go slow, compromise. The resistance is writer’s block and putting jitters and every project that ever shipped late because people couldn’t stay on the same page long enough to get something out the door.&#8221;</p>
</blockquote>
<p>We’ve all dealt with lizard brain, and many of the suggestions in this article can help combat it. But how do you remove the procrastinations that are genuine work, the busywork that must be done but just gets in the way?</p>
<p>Try setting aside one morning a week (Monday is a good day) to devote to the boring tasks. Relegate email reminders of the busywork to a “Monday” folder. Keep all physical folders and to-do lists for that work away from your desk. Of course, you don’t want to wake up one day and realize you forgot to pay the bills, but you won’t forget housekeeping chores like that if you assign them to a specific time slot&mdash;and not that generic “tomorrow.”</p>
<p>One more tip: don’t sit in your creative spot to do the busywork. The area for busywork will quickly get cluttered with to-do notes that have nothing to do with the creative work that you need to accomplish. Do the necessary evils somewhere else to avoid distracting yourself the next time you begin your “real” work.</p>
<h3>Untamed Creativity</h3>
<p>Saying that a wild creative mind can’t be tamed sounds romantic, but romanticism will serve you better in your actual products than in your schedule. The advice above will help you schedule your mind, enhance your creativity and use team members, time constraints and even deadlines to your advantage. Give your creative mind the structure and security it needs to run wild.</p>
<h4>Other Resources</h4>
<p>Here are some more resources on creative productivity:</p>
<ul>
<li>“<a href="http://http://www.uie.com/articles/ux_practicing/">Develop a UX Practice of Practicing</a>,” Jared Spool<br />
Find ways to warm up before work.</li>
<li>“<a href="http://sethgodin.typepad.com/seths_blog/2010/01/quieting-the-lizard-brain.html">Quieting the Lizard Brain</a>,” Seth Godin<br />
Learn more about the dreaded lizard brain and why we get in our own way.</li>
<li><a href="http://www.amazon.com/dp/0596804172?tag=httpdavegraco-20&amp;camp=14573&amp;creative=327641&amp;linkCode=as1&amp;creativeASIN=0596804172&amp;adid=1V9P3RNZR334JMZ2S8CD&amp;&amp;ref-refURL=http%3A%2F%2Fwww.gogamestorm.com%2F"><em>Gamestorming</em></a>, Dave Gray<br />
Explore activities to get you brainstorming in a group. Gray’s book and his <a href="http://www.gogamestorm.com/">Gamestorming</a> website are full of activities and ideas.</li>
<li>“<a href="http://www.npr.org/2012/03/19/148777350/how-creativity-works-its-all-in-your-imagination">How Creativity Works</a>,” Jonah Lehrer<br />
An interview about all different types of creativity.</li>
<li><a href="http://www.cl.cam.ac.uk/~dq209/others/creativetime.pdf"><em>Time Management for Creative People</em></a>, Mark McGuinness<br />
This free eBook deals with how to better structure your creative time.</li>
</ul>
<p>What other tips and tools help you to be creatively productive?</p>
<p><em>(al) (il)</em></p>
<hr />
<p><small>© Marli Mesibov for <a href="http://www.smashingmagazine.com">Smashing Magazine</a>, 2012.</small></p>
<p><a rel="nofollow" href="http://www.smashingmagazine.com/2012/05/11/taming-the-wild-mind/">Smashing Magazine Feed</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.franciscosamper.com/?feed=rss2&#038;p=436</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Application Cache is a Douchebag</title>
		<link>http://www.franciscosamper.com/?p=435</link>
		<comments>http://www.franciscosamper.com/?p=435#comments</comments>
		<pubDate>Sat, 12 May 2012 23:43:10 +0000</pubDate>
		<dc:creator>Fran</dc:creator>
				<category><![CDATA[Portfolio]]></category>
		<category><![CDATA[Application]]></category>
		<category><![CDATA[Cache]]></category>
		<category><![CDATA[Douchebag]]></category>

		<guid isPermaLink="false">http://www.franciscosamper.com/?p=435</guid>
		<description><![CDATA[We’re better connected than we’ve ever been, but we’re not always connected. ApplicationCache lets users interact with their data even&#8230;]]></description>
			<content:encoded><![CDATA[<p>We’re better connected than we’ve ever been, but we’re not always connected. ApplicationCache lets users interact with their data even when they&#8217;re offline, but with great power come great gotchas. For instance, files always come from the ApplicationCache, even when the user is online. Oh, and in certain circumstances, a browser won&#8217;t know that that the online content has changed — causing the user to keep getting old content. And, oh yes, depending on how you cache your resources, non-cached resources may not load even when the user is online. Lanyrd’s Jake Archibald illuminates the hazards of ApplicationCache and shares strategies, techniques, and code workarounds to maximize the pleasure and minimize the pain for user and developer alike. All this, plus a demo. Dig in.<br />
<a rel="nofollow" href="http://www.alistapart.com/articles/application-cache-is-a-douchebag/">A List Apart</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.franciscosamper.com/?feed=rss2&#038;p=435</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How To Build A Real-Time Commenting System</title>
		<link>http://www.franciscosamper.com/?p=434</link>
		<comments>http://www.franciscosamper.com/?p=434#comments</comments>
		<pubDate>Fri, 11 May 2012 23:45:31 +0000</pubDate>
		<dc:creator>Fran</dc:creator>
				<category><![CDATA[Portfolio]]></category>
		<category><![CDATA[Build]]></category>
		<category><![CDATA[Commenting]]></category>
		<category><![CDATA[RealTime]]></category>
		<category><![CDATA[System]]></category>

		<guid isPermaLink="false">http://www.franciscosamper.com/?p=434</guid>
		<description><![CDATA[&#160;&#160; The Web has become increasingly interactive over the years. This trend is set to continue with the next generation&#8230;]]></description>
			<content:encoded><![CDATA[<table width="650">
<tr>
<td width="650">
<div style="width:650px;">
      <img src="http://statisches.auslieferung.commindo-media-ressourcen.de/advertisement.gif" alt="" border="0" /><br />
      <a href="http://auslieferung.commindo-media-ressourcen.de/random.php?mode=target&#038;collection=smashing-rss&#038;position=1" target="_blank"><img src="http://auslieferung.commindo-media-ressourcen.de/random.php?mode=image&#038;collection=smashing-rss&#038;position=1" border="0" alt="" /></a>&nbsp;<a href="http://auslieferung.commindo-media-ressourcen.de/random.php?mode=target&#038;collection=smashing-rss&#038;position=2" target="_blank"><img src="http://auslieferung.commindo-media-ressourcen.de/random.php?mode=image&#038;collection=smashing-rss&#038;position=2" border="0" alt="" /></a>&nbsp;<a href="http://auslieferung.commindo-media-ressourcen.de/random.php?mode=target&#038;collection=smashing-rss&#038;position=3" target="_blank"><img src="http://auslieferung.commindo-media-ressourcen.de/random.php?mode=image&#038;collection=smashing-rss&#038;position=3" border="0" alt="" /></a>
    </div>
</td>
</tr>
</table>
<p>The Web has become increasingly interactive over the years. This trend is set to continue with the next generation of applications driven by the <strong>real-time Web</strong>. Adding real-time functionality to an application can result in a more interactive and engaging user experience. However, setting up and maintaining the server-side real-time components can be an unwanted distraction. But don&#8217;t worry, there is a solution.</p>
<p>Cloud hosted Web services and APIs have come to the rescue of many a developer over the past few years, and real-time functionality is no different. The focus at <a href="http://pusher.com">Pusher</a>, for example, is to let you concentrate on building your real-time Web applications by offering a hosted API which makes it quick and easy to add scalable real-time functionality to Web and mobile apps. In this tutorial, I&#8217;ll show how to convert a basic blog commenting system into a real-time engaging experience where you&#8217;ll see a comment made in one browser window &quot;magically&quot; appear in a second window.</p>
<h3>Why Should We Care About The Real-Time Web?</h3>
<p>Although <a href="http://en.wikipedia.org/wiki/Real-time_web">the Real-Time Web</a> is a relatively recent mainstream phrase, real-time Web technologies have been around for over 10 years. They were mainly used by companies building software targeted at the financial services sector or in Web chat applications. These initial solutions were classed as &quot;hacks&quot;. In 2006 these solutions were given an umbrella term called <a href="http://en.wikipedia.org/wiki/Comet_(programming)">Comet</a>, but even with a defined name the solutions were still considered hacks. <strong>So, what&#8217;s changed?</strong></p>
<p>In my opinion there are a number of factors that have moved real-time Web technologies to the forefront of Web application development.</p>
<h4>Social Media Data</h4>
<p>Social media, and specifically Twitter, has meant that more and more data is becoming instantly available. Gone are the days where we have to wait an eternity for Google to find our data (blog posts, status updates, images). There are now platforms that not only make our data instantly discoverable but also instantly deliver it to those who have declared an interest. This idea of <a href="http://en.wikipedia.org/wiki/Publish%E2%80%93subscribe_pattern">Publish/Subscribe</a> is core to the real-time Web, especially when building Web applications.</p>
<h4>Increased User Expectations</h4>
<p>As more users moved to using applications such as Twitter and Facebook, and the user experiences that they deliver, their perception of what can be expected from a Web application changed. Although applications had become more dynamic through the use of JavaScript, the experiences were seldom truly interactive. Facebook, with it&#8217;s real-time wall (and later other realtime features) and Twitter with it&#8217;s activity stream centric user interface, and focus on conversation, demonstrated how Web applications could be highly engaging.</p>
<h4>WebSockets</h4>
<p><img src="http://media.smashingmagazine.com/wp-content/uploads/2012/03/HTML5_Logo_256.png" alt="HTML5 and WebSockets Rock!" title="HTML5 Logo" width="256" height="256" class="size-full wp-image-119588" align="right" /></p>
<p>Earlier on I stated that previous solutions to let servers instantly push data to Web browsers were considered &quot;hacks&quot;. But this didn&#8217;t remove the fact that there was a requirement to be able to do this in a cross-browser and standardised way. Our prayers have finally been answered with <strong>HTML5</strong> <a href="http://pusher.com/websocket">WebSockets</a>. WebSockets represent a <a href="http://www.w3.org/TR/websockets/">stardardized API</a> and <a href="http://tools.ietf.org/html/rfc6455">protocol</a> that allows realtime server and client (web browser) two way communication over a single connection. Older solutions could only achieve two-way communication using two connections so the fact the WebSockets use a single connection is actually a big deal. It can be a massive resource saving to the server and client, with the latter being particularly important for mobile devices where battery power is extremely valuable.</p>
<h4>How are Real-Time Technologies being used?</h3>
<p>Real-time Web technologies are making it possible to build all sorts of engaging functionality, leading to improved user experiences. Here are a handful of common use cases:</p>
<ul>
<li><strong>Realtime Stats</strong> &#8211; The technology was first used in finance to show stock exchange information so it&#8217;s no surprise that the technology is now used more than ever. It&#8217;s also highly beneficial to sports, betting and analytics.</li>
<li><strong>Notifications</strong> &#8211; when something a user is interested in becomes available or changes.</li>
<li><strong>Activity Streams</strong> &#8211; streams of friend or project activity. This is commonly seen in apps like Twitter, Facebook, Trello, Quora and many more.</li>
<li><strong>Chat</strong> &#8211; the 101 or real-time Web technology but still a very valuable function. It helps delivery instant interaction between friends, work colleagues, customers and customer service etc.</li>
<li><strong>Collaboration</strong> &#8211; Google docs offers this kind of functionality within its docs, spreadsheets and drawing applications and we&#8217;re going to see similar use cases in many more applications.</li>
<li><strong>Multiplayer Games</strong> &#8211; The ability to instantly deliver player moves, game state changes and score updates is clearly important to multiplayer gaming.</li>
</ul>
<p>In the rest of this tutorial I&#8217;ll cover building a basic blog commenting system, how to progressively enhance it using jQuery and finally I&#8217;ll also progressively enhance it using the real-time Web service I work for, Pusher, which will demonstrate not just how easy it can be to use real-time Web technology, but also the value and increased engagement that a real-time factor can introduce.</p>
<h3>Creating Generic Blog Commenting System</h3>
<h4>Start from a Template</h4>
<p>I want to focus on adding real-time commenting to a blog post so <strong>let&#8217;s start from a <a href="https://github.com/pusher/realtime-commenting/zipball/start">template</a></strong>.</p>
<p>This template re-uses the HTML5 layout defined in the post on <a href="http://coding.smashingmagazine.com/2009/08/04/designing-a-html-5-layout-from-scratch/">Coding An HTML 5 Layout From Scratch</a> and the file structure we&#8217;ll start with is as follows (with some additions that we don&#8217;t need to worry about at the moment):</p>
<ul>
<li>css (dir)
<ul>
<li>global-forms.css</li>
<li>main.css</li>
<li>reset.css</li>
</ul>
</li>
<li>images (dir)</li>
<li>index.php</li>
</ul>
<h4>HTML</h4>
<p>The template HTML, found in <em>index.php</em>, has been changed from the HTML5 Layout article to focus on the content being a blog post with comments. You can view the HTML source <a href="https://github.com/pusher/realtime-commenting/blob/start/index.php">here</a>.</p>
<p>The main elements to be aware of are:</p>
<ul>
<li><code>&lt;section id=&quot;content&quot;&gt;</code> &#8211; the blog post content</li>
<li><code>&lt;section id=&quot;comments&quot;&gt;</code> &#8211; where the comments are to appear. This is where the majority of our work will be done</li>
</ul>
<h4>Comments</h4>
<p>
	Now that we&#8217;ve got the HTML in place for our blog post and for displaying the comments we also need a way for our readers to submit comments, so let&#8217;s add a <code>&lt;form&gt;</code> element to collect and submit the comment details to <em>post_comment.php</em>. We&#8217;ll add this at the end of the <code>&lt;section id=&quot;comments&quot;&gt;</code> section wrapped in a <code>&lt;div id=&quot;respond&quot;&gt;</code>.
</p>
<pre class="brush: html">
&lt;div id=&quot;respond&quot;&gt;

	&lt;h3&gt;Leave a Comment&lt;/h3&gt;

	&lt;form action=&quot;post_comment.php&quot; method=&quot;post&quot; id=&quot;commentform&quot;&gt;

		&lt;label for=&quot;comment_author&quot; class=&quot;required&quot;&gt;Your name&lt;/label&gt;
		&lt;input type=&quot;text&quot; name=&quot;comment_author&quot; id=&quot;comment_author&quot; value=&quot;&quot; tabindex=&quot;1&quot; required=&quot;required&quot;&gt;

		&lt;label for=&quot;email&quot; class=&quot;required&quot;&gt;Your email;&lt;/label&gt;
		&lt;input type=&quot;email&quot; name=&quot;email&quot; id=&quot;email&quot; value=&quot;&quot; tabindex=&quot;2&quot; required=&quot;required&quot;&gt;

		&lt;label for=&quot;comment&quot; class=&quot;required&quot;&gt;Your message&lt;/label&gt;
		&lt;textarea name=&quot;comment&quot; id=&quot;comment&quot; rows=&quot;10&quot; tabindex=&quot;4&quot;	 required=&quot;required&quot;&gt;&lt;/textarea&gt;

		&lt;-- comment_post_ID value hard-coded as 1 --&gt;
		&lt;input type=&quot;hidden&quot; name=&quot;comment_post_ID&quot; value=&quot;1&quot; id=&quot;comment_post_ID&quot; /&gt;
		&lt;input name=&quot;submit&quot; type=&quot;submit&quot; value=&quot;Submit comment&quot; /&gt;

	&lt;/form&gt;

&lt;/div&gt;
</pre>
<h4>Comment Form CSS</h4>
<p>Let&#8217;s apply some CSS to make things look a bit nicer by adding the following to <em>main.css</em>:</p>
<pre class="brush: css">
#respond {
	margin-top: 40px;
}

#respond input[type='text'],
#respond input[type='email'],
#respond textarea {
	margin-bottom: 10px;
	display: block;
	width: 100%;

	border: 1px solid rgba(0, 0, 0, 0.1);
	-webkit-border-radius: 5px;
	-moz-border-radius: 5px;
	-o-border-radius: 5px;
	-ms-border-radius: 5px;
	-khtml-border-radius: 5px;
	border-radius: 5px;

	line-height: 1.4em;
}</pre>
<p>Once the HTML structure, the comment form and the CSS are in place our blogging system has started to look a bit more presentable.</p>
<p><img src="http://media.smashingmagazine.com/wp-content/uploads/2012/02/blog_and_comments.png" width="500" alt="Screenshot of blog post and commenting system" /></p>
<h4>Handling Comment Submission</h4>
<p>
	The next step is to write the PHP form submission handler which accepts the request and stores the comment, <em>post_comment.php</em>. You should create this file in the root of your application.</p>
<p>As I said earlier I&#8217;m keen to focus on the real-time functionality so a class exists within the template that you&#8217;ve downloaded which encapsulate some of the standard data checking and persistence functionality. This class is defined in <em>Persistence.php</em> (you can view the source <a href="https://github.com/pusher/realtime-commenting/blob/start/Persistence.php">here</a>), is in no way production quality, and handles:</p>
<ul>
<li>Basic validation</li>
<li>Basic data sanitization</li>
<li>Very simple persistence using a user <code>$  _SESSION</code>. This means that a comment saved by one user will not be available to another user.</li>
</ul>
<p>This also means that we don&#8217;t need to spend time setting up a database and all that goes with it and makes <em>post_comment.php</em> very simple an clean. If you wanted to use this functionality in a production environment you would need to re-write the contents of <em>Persistence.php</em>. Here&#8217;s the code for <em>post_comment.php</em>.
</p>
<pre class="brush: php">
&lt;?php
require('Persistence.php');

$  db = new Persistence();
if( $  db->add_comment($  _POST) ) {
	header( 'Location: index.php' );
}
else {
	header( 'Location: index.php?error=Your comment was not posted due to errors in your form submission' );
}
?&gt;
</pre>
<p>The above code does the following:</p>
<ol>
<li>Includes the <em>Persistence.php</em> class which handles saving and fetching comments.</li>
<li>Creates a new instances of the <code>Persistence</code> object and assigns it to the variable <code>$  db</code>.</li>
<li>Tries to add the comment to the <code>$  db</code>. If the comment is successfully added it redirects back to the blog post. If it fails the redirection also occurs but some error text is appended to an <em>error</em> query parameter.</li>
</ol>
<h4>Displaying the Comments with the Blog Post</h4>
<p>
	The final thing we need to do to have our Generic Blog Commenting System up and running is to update the blog page, <em>index.php</em>, to fetch and display the comments from the <code>Persistence</code> object.</p>
<ul>
<li>Since this isn&#8217;t a real blogging system we&#8217;ll hard code the <code>$  comment_post_ID</code> value to be <code>1</code>.</li>
<li>Include the <em>Persistence.php</em> class and fetch the comments from it. Comments are associated with a blog post using a unique <code>$  comment_post_ID</code>.</li>
</ul>
<pre class="brush: php">
&lt;?php
require('Persistence.php');
$  comment_post_ID = 1;
$  db = new Persistence();
$  comments = $  db->get_comments($  comment_post_ID);
$  has_comments = (count($  comments) > 0);
?&gt;
</pre>
<p>Since we now have the <code>$  comment_post_ID</code> accessible via PHP we should update the HTML for the comment form to use this value.</p>
<pre class="brush: php">
&lt;input type=&quot;hidden&quot; name=&quot;comment_post_ID&quot; value=&quot;&lt;?php echo($  comment_post_ID); ?&gt;&quot; id=&quot;comment_post_ID&quot; /&gt;
</pre>
<p>
	We now have all the comments related to the blog post referenced by the <code>$  comments</code> variable we need to display them on the page. To do this we need to update the PHP in <em>index.php</em> to iterate through them and create the required HTML.
</p>
<pre class="brush: php">
&lt;ol id=&quot;posts-list&quot; class=&quot;hfeed&lt;?php echo($  has_comments?&#39; has-comments&#39;:&#39;&#39;); ?&gt;&quot;&gt;
	&lt;li class=&quot;no-comments&quot;&gt;Be the first to add a comment.&lt;/li&gt;
	&lt;?php
		foreach ($  comments as $  comment) {
			?&gt;
			&lt;li&gt;&lt;article id=&quot;comment_&lt;?php echo($  comment[&#39;id&#39;]); ?&gt;&quot; class=&quot;hentry&quot;&gt;
				&lt;footer class=&quot;post-info&quot;&gt;
					&lt;abbr class=&quot;published&quot; title=&quot;&lt;?php echo($  comment[&#39;date&#39;]); ?&gt;&quot;&gt;
						&lt;?php echo( date(&#39;d F Y&#39;, strtotime($  comment[&#39;date&#39;]) ) ); ?&gt;
					&lt;/abbr&gt;

					&lt;address class=&quot;vcard author&quot;&gt;
						By &lt;a class=&quot;url fn&quot; href=&quot;#&quot;&gt;&lt;?php echo($  comment[&#39;comment_author&#39;]); ?&gt;&lt;/a&gt;
					&lt;/address&gt;
				&lt;/footer&gt;

				&lt;div class=&quot;entry-content&quot;&gt;
					&lt;p&gt;&lt;?php echo($  comment[&#39;comment&#39;]); ?&gt;&lt;/p&gt;
				&lt;/div&gt;
			&lt;/article&gt;&lt;/li&gt;
			&lt;?php
		}
	?&gt;
&lt;/ol&gt;
</pre>
<p>You&#8217;ll notice that if the value of <code>$  has_comments</code> is true an additional CSS class is applied to the ordered list called <em>has-comments</em>. This is so we can hide the list item with the &quot;Be the first to add a comment&quot; message when comments are being displayed using CSS:</p>
<pre class="brush: css">#posts-list.has-comments li.no-comments {
	display: none;
}</pre>
<p>Now that all this is in place we have a functional blog commenting system. If you would like to start writing your code from this basic functioning blog commenting system you can also <a href="https://github.com/pusher/realtime-commenting/zipball/basic">download the code completed up to here</a>.</p>
<p><img src="http://media.smashingmagazine.com/wp-content/uploads/2012/02/functioning_comments.png" width="500" alt="Screenshot of the functioning blog commenting system" /></p>
<h3>Progressive Enhancement With jQuery</h3>
<p>The first step in making our blog commenting system feel less like a Web page and more like an application is to stop page reloads when a user submits a comment. We can do this by submitting the comments to the server using an AJAX request. Since jQuery is probably the defacto standard for cross browser JavaScript functionality we&#8217;ll use it here. Although I&#8217;m using jQuery here, I&#8217;d also like to highlight that it&#8217;s a good idea to <a href="http://www.leggetter.co.uk/2012/02/19/jquery-uk-2012-event-dont-always-use-jquery.html">not always use jQuery</a>. Instead, analyze your scenario and make a considered decision because there are <a href="http://www.leggetter.co.uk/2012/02/12/considerations-when-updating-the-dom-to-display-realtime-data.html">some cases</a> where you are best not to.</p>
<p>In an attempt to try and keep as much scripting (PHP and JavaScript) from the <em>index.php</em> file we&#8217;ll create a new folder for our JavaScript and in there a file for our application JavaScript. The path to this fill should be <em>js/app.js</em>. This file should be included after the jQuery include.</p>
<pre class="brush: html">
&lt;script src=&quot;http://code.jquery.com/jquery-1.7.1.min.js&quot;&gt;&lt;/script&gt;
&lt;script src=&quot;js/app.js&quot;&gt;&lt;/script&gt;
</pre>
<h4>Capture the Comment Form Submission</h4>
<p>
	When the page is ready bind to the <code>submit</code> event of the form.
</p>
<pre class="brush: js">$  (function() {
	$  ('#commentform').submit(handleSubmit);
});</pre>
<p>
	When the form is submitted and the <code>handleSubmit</code> function is called the comment data we want to send to the server is extracted from the form. There are more elegant ways of fetching the data from the form but this approach clearly shows where we&#8217;re getting the values from and the <code>data</code> object we are creating.
</p>
<pre class="brush: js">
function handleSubmit() {
	var form = $  (this);
	var data = {
		"comment_author": form.find('#comment_author').val(),
		"email": form.find('#email').val(),
		"comment": form.find('#comment').val(),
		"comment_post_ID": form.find('#comment_post_ID').val()
	};

	postComment(data);

	return false;
}

function postComment(data) {
	// send the data to the server
}</pre>
<h4>POST the Comment with AJAX</h4>
<p>
	Within the <code>postComment</code> function make a <em>POST</em> request to the server passing the data that we&#8217;ve retrieved from the form. When the request is made an additional HTTP header will be sent to identify the request as being an AJAX request. We want to do this so that we can return a JSON response if it is an AJAX request and maintain our basic functionality if it isn&#8217;t (for more information on this see <a href="http://www.learningjquery.com/2010/03/detecting-ajax-events-on-the-server">Detected AJAX events on the Server</a>). We also define two handlers; <code>postSuccess</code> for handling the comment being successfully stored and <code>postError</code> to handle any failures.
</p>
<pre class="brush: js">
function postComment(data) {
	$  .ajax({
		type: 'POST',
		url: 'post_comment.php',
		data: data,
		headers: {
			'X-Requested-With': 'XMLHttpRequest'
		},
		success: postSuccess,
		error: postError
	});
}

function postSuccess(data, textStatus, jqXHR) {
	// add comment to UI
}

function postError(jqXHR, textStatus, errorThrown) {
	// display error
}
</pre>
<h4>Dynamically Updating the User Interface with the Comment</h4>
<p>
	At this point the comment data is being sent to the server and saved, but the AJAX response isn&#8217;t providing any meaningful response. Also, the comments section isn&#8217;t being updated to show the newly submitted comment so the user would have to refresh the page to see it. Let&#8217;s start by writing the code to update the UI and test that functionality.
</p>
<p>If you are thinking &quot;Hang on a minute! We don&#8217;t have all the data we need from the Web server to display the comment&quot; then you are correct. However, this doesn&#8217;t stop us writing the code to update the UI and also testing that it works. Here&#8217;s how:</p>
<pre class="brush: javascript">
function postSuccess(data, textStatus, jqXHR) {
	$  ('#commentform').get(0).reset();
	displayComment(data);
}

function displayComment(data) {
	var commentHtml = createComment(data);
	var commentEl = $  (commentHtml);
	commentEl.hide();
	var postsList = $  ('#posts-list');
	postsList.addClass('has-comments');
	postsList.prepend(commentEl);
	commentEl.slideDown();
}

function createComment(data) {
	var html = &#39;&#39; +
	&#39;&lt;li&gt;&lt;article id=&quot;&#39; + data.id + &#39;&quot; class=&quot;hentry&quot;&gt;&#39; +
		&#39;&lt;footer class=&quot;post-info&quot;&gt;&#39; +
			&#39;&lt;abbr class=&quot;published&quot; title=&quot;&#39; + data.date + &#39;&quot;&gt;&#39; +
				parseDisplayDate(data.date) +
			&#39;&lt;/abbr&gt;&#39; +
			&#39;&lt;address class=&quot;vcard author&quot;&gt;&#39; +
				&#39;By &lt;a class=&quot;url fn&quot; href=&quot;#&quot;&gt;&#39; + data.comment_author + &#39;&lt;/a&gt;&#39; +
			&#39;&lt;/address&gt;&#39; +
		&#39;&lt;/footer&gt;&#39; +
		&#39;&lt;div class=&quot;entry-content&quot;&gt;&#39; +
			&#39;&lt;p&gt;&#39; + data.comment + &#39;&lt;/p&gt;&#39; +
		&#39;&lt;/div&gt;&#39; +
	&#39;&lt;/article&gt;&lt;/li&gt;&#39;;

	return html;
}

function parseDisplayDate(date) {
	date = (date instanceof Date? date : new Date( Date.parse(date) ) );
	var display = date.getDate() + ' ' +
								['January', 'February', 'March',
								 'April', 'May', 'June', 'July',
								 'August', 'September', 'October',
								 'November', 'December'][date.getMonth()] + ' ' +
								date.getFullYear();
	return display;
}
</pre>
<p>The code above does the following:</p>
<ul>
<li>Within the <code>postSuccess</code> function we clear the form values and call <code>displayComment</code>.</li>
<li><code>displayComment</code> first calls the <code>createComment</code> function to create the list item (<code>&lt;li&gt;</code>) HTML as a <code>String</code>.</li>
<li>We then convert the HTML to a jQuery object using <code>$  (commentHtml)</code> and hide the element.</li>
<li>The comment list item is then prepended to the comments ordered list (<code>&lt;ol&gt;</code>). The list also has a class called <em>has-comments</em> added to it so we can hide the first list item which contains the &quot;Be the first to comment&quot; statement.</li>
<li>Finally, we call <code>commentEl.slideDown()</code> so that the comment is shown in what is becoming the standard &quot;here&#8217;s a new item&quot; way.</li>
</ul>
<p>
	The functionality is now implemented but we want to test it out. This can be achieved in two ways:
</p>
<ul>
<li>The <code>displayComment</code> is a global function so we can call it directly using the JavaScript console of the browser.</li>
<li>We can bind to an event on the page that triggers a fake update which calls the <code>displayComment</code> function</li>
</ul>
<p>
	Let&#8217;s go with the latter and bind to the <em>&quot;u&quot;</em> key being released by binding to the <code>keyup</code> event. When it is, we&#8217;ll create a fake <code>data</code> object containing all the information required to create a new comment and pass it to the <code>displayComment</code> function. That comment will then be displayed in the UI.
</p>
<p>Hit the <em>&quot;u&quot;</em> key a few times and see the comments appear.</p>
<pre class="brush: javascript">
$  (function() {

	$  (document).keyup(function(e) {
		e = e || window.event;
		if(e.keyCode === 85){
			displayComment({
				"id": "comment_1",
				"comment_post_ID": 1,
				"date":"Tue, 21 Feb 2012 18:33:03 +0000",
				"comment": "The realtime Web rocks!",
				"comment_author": "Phil Leggetter"
			});
		}
	});

});
</pre>
<p>
	Great! We now know that our <code>displayComment</code> function works exactly as we expect it to. <strong>Remember to remove the test function</strong> before you go live or you&#8217;ll really confuse your user every time they press <em>&quot;u&quot;</em>.
</p>
<p><img src="http://media.smashingmagazine.com/wp-content/uploads/2012/02/fake_comments1.png" width="500" alt="Screenshot of a bunch of fake comments" /></p>
<h4>Detect and Responding to the AJAX request</h4>
<p>
	All that&#8217;s left to do is update the <em>post_comment.php</em> file to detect the AJAX call and return information about the newly created comment.
</p>
<p>Detecting the AJAX request is done by checking for the <code>X-Requested-With</code> header:</p>
<pre class="brush: php">$  ajax = ($  _SERVER[ 'HTTP_X_REQUESTED_WITH' ] === 'XMLHttpRequest');</pre>
<p>Once we know the request is an AJAX request we can update the code to respond with an appropriate status code and the data representing the comment. We also need to ensure that the original functionality is maintained. The <em>post_comment.php</em> code now looks as follows:</p>
<pre class="brush: php">
&lt;?php
require('Persistence.php');

$  ajax = ($  _SERVER[ 'HTTP_X_REQUESTED_WITH' ] === 'XMLHttpRequest');

$  db = new Persistence();
$  added = $  db->add_comment($  _POST);

if($  ajax) {
	sendAjaxResponse($  added);
}
else {
	sendStandardResponse($  added);
}

function sendAjaxResponse($  added) {
	header("Content-Type: application/x-javascript");
	if($  added) {
		header( 'Status: 201' );
		echo( json_encode($  added) );
	}
	else {
		header( 'Status: 400' );
	}
}

function sendStandardResponse($  added) {
	if($  added) {
		header( 'Location: index.php' );
	}
	else {
		header( 'Location: index.php?error=Your comment was not posted due to errors in your form submission' );
	}
}
?&gt;
</pre>
<p>Key points from the above code are:</p>
<ul>
<li>The <code>$  db->add_comment($  _POST)</code> call returns the data from the added comment which is assigned to the <code>$  added</code> variable.</li>
<li>By setting the response <em>Content-Type</em> to &#8220;application/json&#8221; we tell jQuery to convert the returned string into a JavaScript object. For more information on calling JSON Web services see <a href="http://coding.smashingmagazine.com/2012/02/09/beginners-guide-jquery-based-json-api-clients/">A Beginner’s Guide To jQuery-Based JSON API Clients</a>.</li>
<li>The <em>201</em> status code indicates a successful call and also that a resource (the comment) was created by the call.</li>
</li>
</ul>
<p>The blog commenting system now works in a much more dynamic way, instantly showing the user that their comment has been posted without refreshing the page. In addition, the way the we&#8217;ve added the JavaScript based functionality to the page means that if JavaScript is disabled or a JavaScript file fails to load that the system will fallback to the standard functionality we first implemented.</p>
<h3>Getting Real-Time&mdash;Finally!</h3>
<p>As with any &quot;from scratch&quot; tutorial it can take a bit of time to get to the <strong>really</strong> interesting part, but we&#8217;re finally here. However, <strong>all the work we&#8217;ve up in has been worth it</strong>. Because we&#8217;ve built our commenting system up in a progressively enhanced way, plugging Pusher into it is going to be really easy</p>
<h4>What is Pusher?</h4>
<p>At the start of the tutorial we said that we would use Pusher to add the realtime functionality to the application. But what is Pusher?</p>
<p>Pusher is a hosted service for quickly and easily adding realtime features into Web and mobile applications. It offers a RESTful API that makes it really easy to publish events from any application that can make a HTTP request and a WebSocket API for realtime bi-directional communication. You don&#8217;t even need to use the APIs directly as there are <a href="http://pusher.com/docs/rest_libraries">server</a> (PHP, Ruby, node.js, ASP.NET, Python and more)  and <a href="http://pusher.com/docs/client_libraries">client</a> (JavaScript, iOS, Android, .NET, ActionScript, Arduino and more) libraries available in a host of technologies which means you can add realtime functionality to an app within minutes &dash; I&#8217;m confident you&#8217;ll be surprised just how easy!</p>
<h4>Sign up for Pusher and get your API Credentials</h4>
<p>In order to add Pusher-powered real-time functionality to a Web application you first need to <a href="http://pusher.com/signup">sign up for a free Sandbox account</a>. After you have signed up you&#8217;ll be taken to the Pusher dashboard where you&#8217;ll see that a &quot;Main&quot; application has been created for you. You&#8217;ll also see you are in the &quot;API Access&quot; section for that application where you can grab your API credentials.</p>
<p><img src="http://media.smashingmagazine.com/wp-content/uploads/2012/02/pusher_main_api_access.png" width="500" alt="Screenshot of API Access section in Pusher Dashboard" /></p>
<p>For ease of access create a <em>pusher_config.php</em> file and <code>define</code> the credentials in there so we can refer to them later:</p>
<pre class="brush: php">
&lt;?php
define('APP_ID', 'YOUR_APP_ID');
define('APP_KEY', 'YOUR_APP_KEY');
define('APP_SECRET', 'YOUR_APP_SECRET');
?&gt;
</pre>
<p>In your version of <em>pusher_config.php</em> be sure to replace the values which being <em>&#8216;YOUR_</em> with your actual credentials.</p>
<p>You should also <code>require</code> this in your <em>index.php</em> file. We should also make the <code>APP_KEY</code> available to the JavaScript runtime as we are going to need it to connect to Pusher.</p>
<pre class="brush: php">
&lt;?php
require('pusher_config.php);
?&gt;

&lt;script&gt;
var APP_KEY = '&lt;?php echo(APP_KEY); ?&gt;';
&lt;/script&gt;
</pre>
<h4>Real-time JavaScript</h4>
<p>The first thing you need to do when adding Pusher to a Web application is include the Pusher JavaScript library and connect to Pusher. To connect you&#8217;ll need to use the <em>key</em> which you grabbed from the Pusher dashboard. Below you can see all that is required to hook up the front-end application to Pusher.</p>
<p>Include the Pusher JavaScript library after the <em>app.js</em> include:</p>
<pre class="brush: html">
&lt;script src=&quot;http://code.jquery.com/jquery-1.7.1.min.js&quot;&gt;&lt;/script&gt;
&lt;script src=&quot;http://js.pusher.com/1.11/pusher.min.js&quot;&gt;&lt;/script&gt;
&lt;script src=&quot;js/app.js&quot;&gt;&lt;/script&gt;
</pre>
<p>Add the Pusher functionality to <em>app.js</em>:</p>
<pre class="brush: javascript">
var pusher = new Pusher(APP_KEY);
var channel = pusher.subscribe(&#39;comments-&#39; + $  ('#comment_post_ID').val());
channel.bind(&#39;new_comment&#39;, displayComment);
</pre>
<p>This probably looks too easy to be true, so here are the details about what the above code does:</p>
<ul>
<li><code>var pusher = new Pusher(APP_KEY);</code><br />
	Creates a new instance of a <code>Pusher</code> object and in doing so connects you to Pusher. The application to use is defined by the <code>APP_KEY</code> value that you pass in and that we set up earlier.</li>
<li><code>var channel = pusher.subscribe(&#39;comments-&#39; + $  ('#comment_post_ID').val());</code><br />
	<a href="http://pusher.com/docs/channels">Channels</a> provide a great way of organizing streams of real-time data. Here we are subscribing to comments for the current blog post, uniquely identified by the value of the <code>comment_post_ID</code> hidden form input element.</li>
<li><code>channel.bind(&#39;new_comment&#39;, displayComment);</code><br />
		<a href="http://pusher.com/docs/client_api_guide/client_events">Events</a> are used to further filter data and are ideal for linking updates to changes in the UI. In this case we want to bind to an event which is triggered whenever a new comment is added and display it. Because we&#8217;ve already created the <code>displayComment</code> function we can just pass in a reference to the call to <code>bind</code>.</li>
</ul>
<h4>Sending Real-Time Events using the Event Creator</h4>
<p>We can also test out this functionality without writing any server-side code by using the <strong>Event Creator</strong> for your app which can also be found in the Pusher dashboard. The Event Creator lets you publish events on a channel through a simple user interface. From the code above we can see that we want to publish an event named <em>&quot;new_comment&quot;</em> on the <em>&quot;comments-1&quot;</em> channel. From the earlier test function we also have an example of the test data we can publish.</p>
<p><img src="http://media.smashingmagazine.com/wp-content/uploads/2012/02/event_creator.png" width="500" alt="Screenshot of the Event Creator in Pusher Dashboard" /></p>
<h4>Real-time PHP</h4>
<p>Again, we&#8217;ve proven that our client-side functionality works without having to write any server-side code. Now lets add the PHP code we need to trigger the new comment event as soon as a comment is posted in our comment system.</p>
<p>Pusher offers a number of <a href="http://pusher.com/docs/rest_libraries">server-side libraries</a> which make it easy to publish events in addition to helping with functionality such as <a href="http://pusher.com/docs/private_channels">private channel</a> authentication and providing user information for <a href="http://pusher.com/docs/presence">presence channels</a>. We just want to use the basic event triggering functionality in the <em>post_comment.php</em> file so we need to download the <a href="https://github.com/squeeks/Pusher-PHP">Pusher PHP library</a> (<a href="https://github.com/squeeks/Pusher-PHP/zipball/master">direct zip file download</a>).</p>
<p>Once you&#8217;ve downloaded this zip file, unzip it into the directory along with your other files. Your file structure will now look something like this:</p>
<ul>
<li>index.php</li>
<li>css (dir)</li>
<li>images (dir)</li>
<li>post_comment.php</li>
<li>pusher_config.php</li>
<li>Persistence.php</li>
<li>squeeks-Pusher-PHP (dir)
<ul>
<li>lib (dir)
<ul>
<li>Pusher.php</li>
</ul>
</li>
</ul>
</li>
</ul>
<p>An event can be triggering in just a few lines of code:</p>
<pre class="brush: php">
&lt;?php
require('squeeks-Pusher-PHP/lib/Pusher.php');
require('pusher_config.php');

$  pusher = new Pusher(APP_KEY, APP_SECRET, APP_ID);
$  pusher->trigger('comments-1', 'new_comment', array(
	"comment_post_ID" => 1,
	"date" => "Tue, 21 Feb 2012 18:33:03 +0000",
	"comment" => "The realtime Web rocks!",
	"comment_author" => "Phil Leggetter"
));
?&gt;
</pre>
<p>However, we need to apply a some additional logic before we trigger the event:</p>
<ul>
<li>Check that the comment was added.</li>
<li>Extract the unique comment identifier from the <code>$  added</code> array.</li>
<li>Build the text to identify a channel name for the submitted comment.</li>
<li>Trigger a <em>new_comment</em> event on the channel with the <code>$  added</code> data. <em>Note: The library automatically converts the <code>$  added</code> array variable to JSON to be sent through Pusher.</em></li>
</ul>
<p>Therefore the full <em>post_comment.php</em> file ends up looking as follows:</p>
<pre class="brush: php">
&lt;?php
require(&#39;Persistence.php&#39;);
require(&#39;squeeks-Pusher-PHP/lib/Pusher.php&#39;);
require(&#39;pusher_config.php&#39;);

$  ajax = ($  _SERVER[ &#39;HTTP_X_REQUESTED_WITH&#39; ] === &#39;XMLHttpRequest&#39;);

$  db = new Persistence();
$  added = $  db-&gt;add_comment($  _POST);

if($  added) {
	$  channel_name = &#39;comments-&#39; . $  added[&#39;comment_post_ID&#39;];
	$  event_name = &#39;new_comment&#39;;

	$  pusher = new Pusher(APP_KEY, APP_SECRET, APP_ID);
	$  pusher-&gt;trigger($  channel_name, $  event_name, $  added);
}

if($  ajax) {
	sendAjaxResponse($  added);
}
else {
	sendStandardResponse($  added);
}

function sendAjaxResponse($  added) {
	header(&quot;Content-Type: application/json&quot;);
	if($  added) {
		header( &#39;Status: 201&#39; );
		echo( json_encode($  added) );
	}
	else {
		header( &#39;Status: 400&#39; );
	}
}

function sendStandardResponse($  added) {
	if($  added) {
		header( &#39;Location: index.php&#39; );
	}
	else {
		header( &#39;Location: index.php?error=Your comment was not posted due to errors in your form submission&#39; );
	}
}
?&gt;
</pre>
<p>If you run the app now in two different browser windows you&#8217;ll see that as soon as you submit a comment in one window that comment will instantly (&quot;magically&quot;) appear in the second window. <strong>We now have a real-time commenting system!</strong></p>
<p><strong>But&#8230;</strong>, we&#8217;re not done quite yet. You&#8217;ll also see that the comment is shown twice in the window of the user who submitted it. This is because the comment has been added by the AJAX callback, and by the Pusher event. Because this is a very common scenario, especially if you&#8217;ve built an application in a progressively enhanced way as we have, the Pusher server libraries expose a way of <a href="http://pusher.com/docs/publisher_api_guide/publisher_excluding_recipients">excluding a connection/user</a> from receiving the event via Pusher.</p>
<p>In order to do this you need to send a unique connection identifier called a <code>socket_id</code> from the client to the server. This identifier can then be used to define who will be excluded.</p>
<pre class="brush: js">
function handleSubmit() {
	var form = $  (this);
	var data = {
		"comment_author": form.find('#comment_author').val(),
		"email": form.find('#email').val(),
		"comment": form.find('#comment').val(),
		"comment_post_ID": form.find('#comment_post_ID').val()
	};

	var socketId = getSocketId();
	if(socketId !== null) {
		data.socket_id = socketId;
	}

	postComment(data);

	return false;
}

function getSocketId() {
	if(pusher &#038;&#038; pusher.connection.state === 'connected') {
		return pusher.connection.socket_id;
	}
	return null;
}
</pre>
<p>The changes we&#8217;ve made are:</p>
<ul>
<li>A new function called <code>getSocketId</code> has been added to get the <code>socket_id</code>. It wraps a check to ensure that the <code>pusher</code> variable has been set and also that the client is connected to Pusher.</li>
<li>The <code>handleSubmit</code> has been updated to check to see if a <code>socket_id</code> is available. If it is, this information is posted to the server along with the comment data.</li>
</ul>
<p>On the server we need to use the <code>socket_id</code> parameter if it is present and therefore exclude the connection and user who submitted the comment, or pass in <code>null</code> if it&#8217;s not:</p>
<pre class="brush: php">
$  channel_name = 'comments-' . $  added['comment_post_ID'];
$  event_name = 'new_comment';
$  socket_id = (isset($  _POST['socket_id'])?$  _POST['socket_id']:null);

$  pusher = new Pusher(APP_KEY, APP_SECRET, APP_ID);
$  pusher->trigger($  channel_name, $  event_name, $  added, $  socket_id);
</pre>
<p>And as simple as that we have <strong>a fully realtime enabled blog commenting system</strong> and we only send messages to users who really need to see them. As with the AJAX functionality the realtime functionality has been added in a progressively enhancing way, to ensure it doesn&#8217;t impact on any other functionality. You can find the a demo running <a href="http://www.leggetter.co.uk/pusher/realtime-commenting/">here</a> and the completed solution in the <a href="https://github.com/pusher/realtime-commenting">realtime commenting repository</a> in github.</p>
<h3>Good Real-Time App Development Practices</h3>
<p>Real-time application development shares common good development practices with general Web development. However, I thought I would share a couple of tips that can come in particularly handy.</p>
<h4>Use Browser Developer Tools</h4>
<p>When you start doing a lot of JavaScript development the browser developer tools becomes your best friend. It&#8217;s the same when adding realtime functionality to your Web app, not only because you are using JavaScript, but also because the JavaScript library you are using is likely to be doing some reasonably complex things internally. So, the best way of understanding what is going on and if your code is using it as expect is to enable logging which usually goes to the developer console. All major browser vendors now offer good developer tools which include a console:</p>
<ul>
<li><a href="http://getfirebug.com/">Firebug addon</a> for Firefox</li>
<li><a href="http://code.google.com/chrome/devtools/docs/overview.html">Google Chrome Developer Tools</a></li>
<li>Internet Explorer <a href="http://msdn.microsoft.com/en-us/library/gg589507(v=VS.85).aspx">F12 developer tools</a></li>
<li><a href="http://www.opera.com/dragonfly/documentation/">Opera Dragonfly</a></li>
<li><a href="https://developer.apple.com/library/safari/#documentation/appleapplications/Conceptual/Safari_Developer_Guide/2SafariDeveloperTools/SafariDeveloperTools.html">Safari Developer Tools</a></li>
</ul>
<p>The Pusher JavaScript library provides a way to hook into the logging functionality. All you need to do is assign a function to the <a href="http://pusher.com/docs/client_api_guide/client_global_configuration#pusher_log"><code>Pusher.log</code></a> static property. This function will then receive all log messages. You can do what you like within the function but best practice is to log the messages to the developer console. You can do this as follow, ensuring the code it executed after the Pusher JavaScript library include:</p>
<pre class="brush: javascript">
Pusher.log = function(msg) {
	if(window.console &#038;&#038; window.console.log) {
		window.console.log(new Date().getTime() + ': ' + msg);
	}
};
</pre>
<p>The code above checks to make sure the <code>console</code> and <code>log</code> function is available &#8211; it&#8217;s not in older browsers &#8211; and then logs the messages along with a timestamp to the JavaScript console. This can be incredibly handy in tracking down problems.</p>
<p><img src="http://media.smashingmagazine.com/wp-content/uploads/2012/02/javascript_console.png" width="500" alt="Screenshot of Pusher logging in the Chrome Developer Tools Console" /></p>
<h4>Check Connectivity</h4>
<p>Any good real-time technology will maintain a persistent connection between the client (web browser) and the Web server or service. Sometimes the client will lose connectivity and when the client isn&#8217;t connected to the Internet the real-time functionality won&#8217;t work. This can happen a lot with applications running on mobile devices which rely on mobile networks. So, if your application relies on that connectivity and functionality then it&#8217;s important to deal with scenarios where the client isn&#8217;t connected. This might be by displaying a message to tell the user they are offline or you might want to implement some alternative functionality.</p>
<p>The Pusher JavaScript library exposes <a href="pusher.com/docs/connection_states">connectivity state</a> via the <code>pusher.connection</code> object, which we briefly saw earlier when fetching the <code>socket_id</code>. Binding to state changes and implementing your required functionality is quite simple as it follows the same mechanism as binding to events on channels:</p>
<pre class="brush: javascript">
var pusher = new Pusher(APP_KEY);

pusher.connection.bind('state_change', function(states) {
	Pusher.log('Connection state changed from: ' + states.previous + ' to ' + states.current);
});
</pre>
<h3>Conclusion</h3>
<p>
	We&#8217;re seeing real-time functionality appearing in a large number of high profile applications: some have it at the core of what they offer whilst others use it sparingly. No matter how it is used the end goal is generally the same; to enhance the user experience and keep users engaged with an application. By converting a basic blog commenting system into a more engaging communication platform I hope I&#8217;ve demonstrated that the functionality and experience can easily be layered on existing application.</p>
<p>
	The ease of access to this technology is a relatively new thing and we&#8217;ve only just touched the potential uses for the technology. Real-time stats, instant news updates, activity streams, social interaction, collaboration and gaming are just a few common uses but as more developers become aware of, and comfortable with, the technology I&#8217;m confident that we&#8217;re going to see some truly amazing innovation. An &quot;Internet of Real-Time Things?&quot;?</p>
<hr />
<p><small>© Phil Leggetter for <a href="http://www.smashingmagazine.com">Smashing Magazine</a>, 2012.</small></p>
<p><a rel="nofollow" href="http://www.smashingmagazine.com/2012/05/09/how-to-build-a-real-time-commenting-system/">Smashing Magazine Feed</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.franciscosamper.com/?feed=rss2&#038;p=434</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Interaction Design In The Cloud</title>
		<link>http://www.franciscosamper.com/?p=433</link>
		<comments>http://www.franciscosamper.com/?p=433#comments</comments>
		<pubDate>Fri, 11 May 2012 00:08:17 +0000</pubDate>
		<dc:creator>Fran</dc:creator>
				<category><![CDATA[Portfolio]]></category>
		<category><![CDATA[Cloud]]></category>
		<category><![CDATA[Design]]></category>
		<category><![CDATA[Interaction]]></category>

		<guid isPermaLink="false">http://www.franciscosamper.com/?p=433</guid>
		<description><![CDATA[&#160;&#160; Interaction designers create wireframes in tools such as Adobe Illustrator, OmniGraffle and Microsoft Visio. Originally, these wireframes were primitive&#8230;]]></description>
			<content:encoded><![CDATA[<table width="650">
<tr>
<td width="650">
<div style="width:650px;">
      <img src="http://statisches.auslieferung.commindo-media-ressourcen.de/advertisement.gif" alt="" border="0" /><br />
      <a href="http://auslieferung.commindo-media-ressourcen.de/random.php?mode=target&#038;collection=smashing-rss&#038;position=1" target="_blank"><img src="http://auslieferung.commindo-media-ressourcen.de/random.php?mode=image&#038;collection=smashing-rss&#038;position=1" border="0" alt="" /></a>&nbsp;<a href="http://auslieferung.commindo-media-ressourcen.de/random.php?mode=target&#038;collection=smashing-rss&#038;position=2" target="_blank"><img src="http://auslieferung.commindo-media-ressourcen.de/random.php?mode=image&#038;collection=smashing-rss&#038;position=2" border="0" alt="" /></a>&nbsp;<a href="http://auslieferung.commindo-media-ressourcen.de/random.php?mode=target&#038;collection=smashing-rss&#038;position=3" target="_blank"><img src="http://auslieferung.commindo-media-ressourcen.de/random.php?mode=image&#038;collection=smashing-rss&#038;position=3" border="0" alt="" /></a>
    </div>
</td>
</tr>
</table>
<p>Interaction designers create wireframes in tools such as Adobe Illustrator, OmniGraffle and Microsoft Visio. Originally, these wireframes were primitive shapes drawn to represent various UI elements. Many of us cannot imagine life without them.</p>
<p>There are, however, reasons to consider moving to the cloud to do interaction design. In short, today’s cloud-based tools are:</p>
<ul>
<li>Optimized for collaboration,</li>
<li>Editable anywhere,</li>
<li>Interactive,</li>
<li>Published in real time,</li>
<li>Self-maintaing (the user doesn’t need to update software),</li>
<li>Payable monthly,</li>
</ul>
<p>Emailing your old static designs will feel old fashioned once you see what these tools can do. Going a step further, there are tools for the user review process, too. Just upload your ideas, from simple mockups to final layouts, link them together, and share them for comment.</p>
<p><a href="http://www.flickr.com/photos/baldiri/5735003580/sizes/l/in/photostream/"><img src="http://media.smashingmagazine.com/wp-content/uploads/2012/05/ipad_wire.jpg" alt="iPad Wireframe" title="iPad Wireframe" width="500" height="350" class="alignnone size-full wp-image-112085" /></a><br /><em>(Image credit: <a href="http://www.flickr.com/photos/baldiri/5735003580/sizes/l/in/photostream/" title="iPad Wireframe">baldiri</a>)</em></p>
<p>This article walks you through the current selection of <strong>cloud-based tools and provides some recommendations</strong>. The number of offerings and amount of functionality are pretty vast. For the sake of brevity, we’ll address two functions: prototyping and wireframing. But if you’re intrigued, you might want to explore cloud-based image editing, mind-mapping tools and other UX activities. These tools are already out there, and surprisingly good.</p>
<h3>Prototyping</h3>
<p>For our purposes, prototyping involves uploading images (screens) and linking them together via hotspots. Once these are set up, the prototype is published and available to reviewers for usability testing, commenting or both.</p>
<p><strong>Review criteria</strong><br />
Here are the <strong>fundamentals that a product should support</strong> in order to compete in this space:</p>
<ul>
<li>Quick uploading process,</li>
<li>Support for several source image file formats,</li>
<li>Easy linking between pages,</li>
<li>Support for feedback from end users.</li>
</ul>
<p>Some items aren’t available as of this writing:</p>
<ul>
<li>The ability to nudge images in line without having to recreate them;</li>
<li>The ability to create interactive objects and layer them (such as a menu bar that appears on every page).</li>
</ul>
<h4>InVision</h4>
<p><strong>What it does</strong><br />
Create your screens in your favorite tool and upload them to <a href="http://www.invisionapp.com">InVision</a>. Then add hotspots; a hotspot links to another page. This is great if you live and die by the comp (Photoshop file). For example:</p>
<ol>
<li>Create a new project. Think of a project as a collection of previously generated comps that you are going to tie together as a prototype via InVision.</li>
<p><img class="size-full wp-image-112025 aligncenter" title="create a project - invision" src="http://media.smashingmagazine.com/wp-content/uploads/2012/04/create-a-project-invision5.png" alt="" width="244" height="266" /></p>
<li>Upload your files to this new project (the images in this article are PNGs).</li>
<p><img class="aligncenter size-full wp-image-112024" title="fille drag - upload2" src="http://media.smashingmagazine.com/wp-content/uploads/2012/04/fille-drag-upload21.png" alt="" width="341" height="330" /></p>
<li>In “Build” mode, create the hotspots. Basically, you are linking together the prototype. If you have all of the collateral that you need, this will go quite fast &mdash; exactly as you’d want it to work.</li>
<p><img src="http://media.smashingmagazine.com/wp-content/uploads/2012/05/smashing.jpg" alt="Smashing Magazine Example" title="Smashing Magazine Example" width="500" height="350" class="alignnone size-full wp-image-112096" /></p>
</ol>
<p><strong>Observations</strong><br />
The application <strong>works as advertised</strong>. It enables the user to quickly wire up prebuilt comps, wireframes and sketches. The tutorials also explain useful actions, such as creating hotspots that will be the same on multiple pages (these are called “templates” in InVision).</p>
<p>Speaking of templates, they expose both a major advantage and a major disadvantage of this tool: if the uploaded images are not placed perfectly, then the templates will not line up properly. One would want the ability to adjust the x and y coordinates of any image so that they line up perfectly without having to change the source files. On the upside, if you’ve done the prep work right or you’ve made your hotspots large enough, you can fudge this a bit, and the templates really accelerate the build process.</p>
<p>A number of usability issues have made me scratch my head. For example, the first time I tried adding a hotspot to the search input field, the “Link to…” modal dialog was off to the left side of the browser, which made it impossible to save or cancel the dialog. I then tapped the “Update screen” at the bottom of app to refresh the screen. It turns out that in InVision speak, “Update” = “Replace.” I was afraid to refresh the browser because there is no indication of whether the application saves automatically. So, in the end, I switched to “Preview” and then back to “Build.”</p>
<p>Once you’re familiar with the quirks, however, the application is useful. If you’re a designer or want to work offline to generate wireframes, then give this app a hard look.</p>
<ul>
<li><strong>Upload process</strong><br />
Drag and drop, or browse the file system</li>
<li><strong>Supported file formats</strong><br />
JPG, PNG and GIF</li>
<li><strong>Linking pages</strong><br />
Easier than the others tested because of templates</li>
<li><strong>User feedback</strong><br />
Easy, nested</li>
<li><strong>Marquee clients</strong><br />
eBay, Google, Intuit, Whole Foods and many others. Very impressive.</li>
</ul>
<h4>FieldTest</h4>
<p>In spirit, <a href="http://www.fieldtestapp.com">FieldTest</a> (in private beta) serves the same space as InVision. The designer uploads prebuilt comps, wireframes and the like to FieldTest, ties them together, and then publishes them for review. One advantage is that FieldTest <strong>leverages device gestures</strong>. In short, you can “play” FieldTest prototypes on your iOS, Android or Windows Phone 7 device and have it respond to gestures. Combined with the built-in screen transitions, this is a powerful function for mobile app designers.</p>
<p>As with InVision, screens are grouped into “prototypes” (projects). Including them in a project means that they can be linked to and from other screens. The process is the same, too: create the prototype collateral, link it together via hotspots, and publish it for review. For comparison’s sake, here are the hotspot configurations for the two apps.</p>
<p><img class="aligncenter size-full wp-image-112022" title="create hotspots - fieldTest- tighter full size" src="http://media.smashingmagazine.com/wp-content/uploads/2012/04/create-hotspots-fieldTest-tighter1.png" alt="" width="355" height="124" /><br />
<img class="aligncenter size-full wp-image-112021" title="create hotspots - invision - tighter full screen" src="http://media.smashingmagazine.com/wp-content/uploads/2012/04/create-hotspots-invision-tighter1.png" alt="" width="370" height="158" /></p>
<p>This demonstrates the differences in approach. On the top is FieldTest. It allows a user to choose between gestures (the prototype I built was an iPhone app). The gestures are tap, long tap, swipe, swipe left and swipe right. Multiple gestures can be active for the same hotspot, which is particularly cool and gives a <strong>realistic experience</strong> of various actions. On the bottom is InVision, whose ace is templates. The author can create a template for several controls that appear together, and they can reuse that template on several screens.</p>
<p><strong>Observations</strong><br />
If I were to choose between these prototyping tools, FieldTest would be my choice, largely because I build mobile applications. Having listeners for multiple gesture types makes for a more realistic prototype. If the app were Web-based, then InVision is more mature.</p>
<p>FieldTest still has work to do, though. In the beta, gestures such as up and down are missing. Templating as InVision does is really useful. It streamlines the addition of hotspots. Another area for improvement is in comments, and allowing a prototype’s end user to provide feedback.</p>
<p>There are other usability nits. For example, FieldTest includes a status bar at the top of each screen. I have yet to figure out why someone would want this, and it’s not optional. So, if you take a screenshot on an iPhone, you’ll have to edit it to remove this status bar, only for FieldTest to put it back.</p>
<p>Try it out for yourself on the <a href="https://go.fieldtestapp.com/13d3izk">prototype built for this review</a>. Please note, there is no down gesture, so if you want to try that, gesture from right to left (like when advancing through pictures in iPhoto).</p>
<ul>
<li><strong>Upload process</strong><br />
Browse the file system</li>
<li><strong>Supported file formats</strong><br />
JPG, PNG and GIF</li>
<li><strong>Linking pages</strong><br />
Fairly easy</li>
<li><strong>User feedback</strong><br />
Enables gestures on the device, which is great.</li>
<li><strong>Marquee clients</strong><br />
In private beta</li>
</ul>
<h4>ClickDummy</h4>
<p><a href="http://www.clickdummy.com">ClickDummy</a> is another competitor in this space and has the <strong>same process as the others</strong>. The user uploads materials and then links them together through hotspots. The link function is a “tool” contained in a drawer (i.e. a UI element that slides in and out from one side of the screen).</p>
<p><img class="size-full wp-image-111675 alignnone" title="clickdummy drawer" src="http://media.smashingmagazine.com/wp-content/uploads/2012/04/clickdummy-drawer.png" alt="" width="213" height="732" /></p>
<p><strong>Observations</strong><br />
This drawer seems innocent enough, but it creates unnecessary hurdles for the user. In an attempt to simplify the problem, it has added confusion and multiple steps to an easy process. How? The user has to toggle between this tool drawer and the page-picker drawer a lot. The page picker also has to be overloaded in order to provide both functions (selecting a page, as in navigation, and selecting a page, as in a hotspot target).</p>
<p>A second issue: the website says that the user can drag and drop images onto the pages drawer. This doesn’t work in my (Chrome) browser. It instead replaces the current page with the image. After a panicked “Backspace,” the user is restored to their project but has lost their location and has to start over.</p>
<p>Another point: this all-important drawer is closed when the app launches. It took about five minutes to determine that the app was working, and this after weeks of looking at apps in this space.</p>
<p>Lastly, unlike both of the apps reviewed above, this one has no compelling feature that makes the additional effort worth the time. In future, hopefully, the addition of some product differentiation, combined with a rework of the primary use case, would make this application worth another look.</p>
<p>You can see the <a href="http://clickdummy.com/projects/nayres">output from this exploration</a> for yourself.</p>
<ul>
<li><strong>Upload process</strong><br />
Drag and drop, or browse the file system.</li>
<li><strong>Supported file formats</strong><br />
JPG, PNG and GIF</li>
<li><strong>Linking pages</strong><br />
Most difficult of those tested</li>
<li><strong>User feedback</strong><br />
Easy to test, but comments require registration</li>
<li><strong>Marquee clients</strong><br />
Not provided</li>
</ul>
<h3>Wireframes</h3>
<p>Think of a wireframe as a black and white low-fidelity screen mockup. The mockups I create also include call-outs to give the development team additional context.</p>
<p>In the process, the user will create an account, create a project, and then land on a blank screen. The user then drag and drops UI controls (radio buttons, text input fields and so forth) onto the page.</p>
<p>Once the project is saved, a permalink can be given out for people to see your work. If you change a screen, it will auto-magically show your updates the next time that URL is opened (or refreshed) by a team member. This last point <strong>is what the cloud is all about</strong>: everyone always has the same (i.e. current) version of your work. Changes are instantaneously available whenever the wireframe is saved.</p>
<p>Compared to most offline tools, the library of available objects is focused on low-fidelity UX. Don’t expect to create gradients or to use a pencil tool.</p>
<p><strong>Review criteria</strong><br />
Here are some basics that are fairly universal in my experience:</p>
<ul>
<li><strong>Robust set of standard UI controls</strong><br />
If the tool doesn’t have off-the-shelf drop-downs, toggles, cover flows and the rest, then creating those controls will require additional work.</li>
<li><strong>Good as a documentation medium</strong><br />
Plan on your development team using your wireframes to dictate the logic and layout of the application.</li>
<li><strong>Good for making wireframe clones, templates or whatever you want to call them</strong><br />
Not surprisingly, all of the iPhone wireframes I create have the app’s name at the top. I want to do this on the first wireframe and not have to do it again.</li>
<li><strong>Responsive</strong><br />
It all takes place in a Web browser. If the application is slower than a locally running application, then your productivity will suffer. Case in point: a year or two ago, I created about 50 wireframes for a project. Each page took a minute to load. To see my changes reflected, another minute. Trust me, this gets old quickly.</li>
<li><strong>Not written in Flash</strong><br />
“Dear development teams who write these tools: I love Flash, Flex and the rest. Not as much as I love my iPad, however. I want to edit my work across form factors. It’s all drag and drop, right?”</li>
</ul>
<p>Here’s what you won’t see right away from the tools out there:</p>
<ul>
<li><strong>An extensive stencil library or the ability to easily create and reuse stencils</strong><br />
OmniGraffle excels at this. Don’t expect Yahoo to create a stencil library for Mockingbird anytime soon.</li>
<li><strong>A wide user base</strong><br />
Momentum is building, and there are believers. This is still a minority position and will be for some time. I would say customer support is great, but the more people use these tools, the better the tools will become.</li>
<li><strong>Font selection</strong><br />
I won’t dwell on this, but you can tell there is still some lively debate about what a wireframe should and should not communicate just by looking at what features are included in any given product.</li>
</ul>
<h4>Balsamiq</h4>
<p>As with the prototyping tools, wireframes &mdash; or “mockups” in <a href="http://www.mybalsamiq.com">Balsamiq</a>-speak &mdash; are organized into projects. From there, things change. Tools like InVision and FieldTest assume that you have created your pages or screens in another tool. In Balsamiq (and Mockingbird, discussed next), the tool is designed for wireframe creation, with extremely limited functionality for prototyping.</p>
<ol>
<li>Create a new mockup.</li>
<p><img class="aligncenter size-full wp-image-112020" title="new mockup - balsamiq" src="http://media.smashingmagazine.com/wp-content/uploads/2012/04/new-mockup-balsamiq1.png" alt="" width="210" height="222" /></p>
<li>Drag and drop an off-the-shelf UI control from the ones available.</li>
<p><img src="http://media.smashingmagazine.com/wp-content/uploads/2012/05/balsamiq2.jpg" alt="Balsamiq controls" title="Balsamiq controls" width="500" height="300" class="alignnone size-full wp-image-112099" /></p>
<li>Configure the control to your needs. This is noteworthy, because Balsamiq <strong>provides a number of important options</strong>. For example, there is one toggle to put the iPhone in landscape orientation instead of portrait.</li>
<p><img src="http://media.smashingmagazine.com/wp-content/uploads/2012/05/balsamiq1.jpg" alt="Toggle" title="Toggle" width="500" height="350" class="alignnone size-full wp-image-112100" /></p>
<li>Add the rest of your UI controls; document for the development team; and publish.</li>
</ol>
<p><strong>Observations</strong><br />
Having worked with some other tools, I’ve become a fan of Balsamiq. A great UI control library and easy object configuration are two areas where this tool excels. There are some areas for improvement, though. First, and I’m sure the development team is tired of hearing it, the sketching style is fine for those who understand low-fidelity mockups, but you probably wouldn’t want to show the mockups to your CEO.</p>
<p>A second gripe is that the editing tool is built in Flash, so work is limited to platforms that support it.</p>
<p>On the upside, a few non-obvious pros:</p>
<ul>
<li>The icon set is great. I’ve noticed that only one icon is not in the box: Bluetooth. Anything else I’ve needed has been available.</li>
<li>In addition to drag and drop, there’s a great quick-add feature. After typing in a few characters of the name of a UI control, a filtered list appears, allowing you to add controls quickly.</li>
<li>Balsamiq has an odd markup language that, once mastered, allows the user to add common things. For example, <code>+ Add and sub-menu, &gt;</code> translates to:</li>
<p><img class="aligncenter size-full wp-image-112016" title="iphone list item markup full screen" src="http://media.smashingmagazine.com/wp-content/uploads/2012/04/iphone-list-item-markup1.png" alt="" width="212" height="27" /></p>
</ul>
<p>And here’s the rundown:</p>
<ul>
<li><strong>UI controls</strong><br />
More than 70, including iPhone-specific</li>
<li><strong>Good for documentation?</strong><br />
Call-outs are one of the controls; drag and drop them onto the canvas.</li>
<li><strong>Good at duplicating screens?</strong><br />
Yes.</li>
<li><strong>Responsive?</strong><br />
Yes. You will forget you are working in the cloud.</li>
<li><strong>Written in Flash?</strong><br />
Yes.</li>
</ul>
<h4>Mockingbird</h4>
<p><a href="http://gomockingbird.com">Mockingbird</a> is also a wireframing tool, and <strong>a good one</strong> at that. In some ways, it compares favorably to Balsamiq: Mockingbird’s editor isn’t Flash-based; it uses an unobtrusive font; and adding UI controls is (almost) comparable to Balsamiq.</p>
<p>The process is similar, too. Here’s the outcome:</p>
<p><img src="http://media.smashingmagazine.com/wp-content/uploads/2012/05/mockingbird1.jpg" alt="Mockingbird Wireframe" title="Mockingbird Wireframe" width="500" height="350" class="alignnone size-full wp-image-112102" /></p>
<p><strong>Observations</strong><br />
More professional, right? On the surface, it is more polished, but there are some subtle shortcomings. For example, one cannot left-justify text in an input field. Also, I couldn’t get the icons to all be exactly the same size (36 pixels). And so forth.</p>
<p>There are some logistical hurdles as well. Many of the controls are primitive. To add a call-out, like ones in yellow above, you actually have to add two objects: the yellow circle and the black text. And when a control is added via the quick-add function, the filtering text is not cleared, so after every addition, one has to clear the previous query. Put practically, this mockup took about four times as long to create as the Balsamiq version.</p>
<ul>
<li><strong>UI controls</strong><br />
Fewer than Balsamiq, and no mobile-specific controls.</li>
<li><strong>Good for documentation?</strong><br />
Call-outs are created with circles and overlaid text.</li>
<li><strong>Good at duplicating screens?</strong><br />
Yes.</li>
<li><strong>Responsive?</strong><br />
Mostly &mdash; don’t use Chrome.</li>
<li><strong>Written in Flash?</strong><br />
No.</li>
</ul>
<h4>Mockup Builder</h4>
<p>Another entry in the wireframing space is <a href="http://www.mockupbuilder.com">Mockup Builder</a>. Functionally, it lies somewhere between Mockingbird and Balsamiq. It has a fairly good library of controls &mdash; in fact, it’s the only cloud-based solution with native Android controls (Ha!). Moreover, I find its aesthetic better than that of competitors.</p>
<p>Like the others, Mockup Builder starts with a blank canvas, and the user drag and drops controls onto the canvas for configuration.</p>
<p>Here’s the mockup created for this review:</p>
<p><img src="http://media.smashingmagazine.com/wp-content/uploads/2012/05/mockingbird2.jpg" alt="Mockingbird Wireframe 2" title="Mockingbird Wireframe 2" width="500" height="350" class="alignnone size-full wp-image-112103" /></p>
<p>Again, the mockup is fairly clean, but there are some issues: the icons use some funny clipping, and they do not scale properly. The user cannot toggle the various defaults for the iPhone, such as the gray bars at the top and bottom of the screen.</p>
<p><strong>Observations</strong><br />
This tool is a little too buggy for everyday use. For example, the notes to accompany illustrations are in Lorem Ipsum text. Also, when copying text from the Web and pasting into a multi-line text area, the text does not wrap to the control’s width &mdash; meaning that the text shows exactly one line, and the user has to use the control’s handles to wrap it. I also wanted to show two paragraphs of text but could not figure out how to insert a “Return” in the text.</p>
<p>Another grievance: the tool could use more polish. For example, the screen surface on the iPhone control is narrower than the keyboard, so the user has to resize the keyboard by hand. When that’s done, the “e” is missing in the button. I understand that these are minor, but one would expect these t’s to be crossed off before moving away from a beloved tool like OmniGraffle.</p>
<ul>
<li><strong>UI controls</strong><br />
More than the others, including iPhone- and Android-specific ones</li>
<li><strong>Good for documentation?</strong><br />
Call-outs are one of the controls; drag and drop them onto the canvas.</li>
<li><strong>Good at duplicating screens?</strong><br />
Yes.</li>
<li><strong>Responsive?</strong><br />
Yes.</li>
<li><strong>Written in Flash?</strong><br />
No.</li>
</ul>
<h3>Conclusion</h3>
<p>Cloud-based tools are now available and <strong>well designed for UX work</strong>. Many of the features in the offerings above are not available in software running locally on your machine. While this space is still growing, I’ve been working in the cloud for the past two years and cannot imagine going back.</p>
<p><strong>Collaboration is instantaneous</strong>, and the tools are optimized for the right activities: wireframing and testing with users. In fact, these apps have several unexpected and delightful features, and you might find yourself walking away from your favorites, too.</p>
<p>Of course, there are valid reasons to avoid working in the cloud. Stay with your old standbys if any of the following apply:</p>
<ul>
<li><strong>Your IT department disapproves.</strong><br />
This is a hot-button issue. All of these tools protect your information, but this is still worth considering.</li>
<li><strong>You expect the polish of offline tools.</strong><br />
These tools are for early adopters. Still, they are Web applications, so they will evolve. That’s what happens on the Web. You’ll just wake up one morning to find some annoyance removed or a key feature added.</li>
<li><strong>Your project is <em>big</em>.</strong><br />
If you plan on a 200-screen flow, you will feel a steady degradation in performance. That said, I’ve just completed a 70-pager with one of these tools and was just starting to notice some minor falloff.</li>
<li><strong>You think in terms of “deliverables,” with a complete set of create-once mockups.</strong><br />
Many of these tools have coauthoring functionality (if the roles are set up that way). In my experience, however, no one has actually changed anything, even if I wanted them to.</li>
<li><strong>Your Internet connection is a problem.</strong><br />
But that’s not to say that you’ll lose data whenever the network is interrupted.</li>
</ul>
<p>These could be a deal-breaker for some. But these tools <strong>are free to try</strong>, and some are so simple that you might get hooked in five minutes (as I did a few years ago). Almost all of the research for this article was done with free trials. Given the ease with which you can try these out, you have every reason to go out and see whether one or more is right for you.</p>
<p>If you have another favorite, we’d love to learn about it. The space is ever changing!</p>
<p><em>(al)</em></p>
<hr />
<p><small>© Erik Perotti for <a href="http://www.smashingmagazine.com">Smashing Magazine</a>, 2012.</small></p>
<p><a rel="nofollow" href="http://www.smashingmagazine.com/2012/05/10/interaction-design-in-the-cloud/">Smashing Magazine Feed</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.franciscosamper.com/?feed=rss2&#038;p=433</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

