<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:content="http://purl.org/rss/1.0/modules/content/"  xmlns:atom="http://www.w3.org/2005/Atom">
	<channel>
		<title>Adactio: Journal</title>
		<description>The online journal of Jeremy Keith, an author and web developer living and working in Brighton, England.</description>
		<language>en</language>
		<link>http://adactio.com/journal/</link>
		<managingEditor>jeremy@adactio.com (Jeremy Keith)</managingEditor>
		<webMaster>jeremy@adactio.com (Jeremy Keith)</webMaster>
		<image>
			<title>Adactio: Journal</title>
			<link>http://adactio.com/journal/</link>
			<url>http://adactio.com/images/rssbutton.gif</url>
			<width>88</width>
			<height>19</height>
		</image>
		<atom:link href="http://adactio.com/journal/rss" rel="self" type="application/rss+xml" />
		<item>
			<title>Secret src</title>
			<link>http://adactio.com/journal/5474/</link>
			<description>
<![CDATA[
<p>There&#8217;s been quite a brouhaha over the past couple of days around the subject of standardising responsive images. There are two different matters here: the process and the technical details. I&#8217;d like to address both of them.</p>

<h3>Ill communication</h3>

<p>First of all, there&#8217;s a number of very smart developers who feel that they&#8217;ve been sidelined by the <abbr title="Web Hypertext Application Technology Working Group">WHATWG</abbr>. <cite class="vcard"><a href="http://timkadlec.com" class="url" rel="friend met colleague"><abbr class="fn" title="Tim Kadlec">Tim</abbr></a></cite> has put together <a href="http://timkadlec.com/2012/05/wtfwg/">a timeline of what happened</a>:</p>

<blockquote>
  <ol>
  <li>Developers got involved in trying to standardize a solution to a common and important problem.</li>
  <li>The WHATWG told them to move the discussion to a community group.</li>
  <li>The discussion was moved (back in February), a general consenus (not unanimous, but a majority) was reached about the picture element.</li>
  <li>Another (partial) solution was proposed directly on the WHATWG list by an Apple employee.</li>
  <li>A discussion ensued regarding the two methods, where they overlapped, and how the general opinions of each. The majority of developers favored the picture element and the majority of implementors favored the srcset attribute.</li>
  <li>While the discussion was still taking place, and only 5 days after it was originally proposed, the srcset attribute (but not the picture element) was added to the draft.</li>
  </ol>
</blockquote>

<p>A few points in that timeline have since been clarified. That second step&#8212;&#8220;The WHATWG told them to move the discussion to a community group&#8221;&#8212;turns out to be untrue. Some <a href="http://lists.w3.org/Archives/Public/public-whatwg-archive/2012Feb/0194.html">random person</a> on the WHATWG mailing list (which is open to everyone) suggested forming a Community Group at the W3C. Alas, nobody else on the WHATWG mailing list corrected that suggestion.</p>

<p>Then there&#8217;s apparent causality between step 4 and 6. Initially, I also assumed that this was what happened: that <span class="vcard"><a href="http://edward.oconnor.cx/" class="url" rel="friend met colleague"><abbr class="fn" title="Edward O'Connor">Ted</abbr></a></span> had proposed the <code>srcset</code> solution without even being aware of the <code>picture</code> solution that the Community Group had independently come up with it. It turns out that&#8217;s not the case. Ted had another email about the <code>picture</code> proposal but he never ended up sending it. In fact, his email about <code>srcset</code> had been sitting in draft for quite a while and he only sent it out when he saw that Hixie was finally collating feedback on responsive images.</p>

<p>So from the outside it looked like there was preferential treatment being given to Ted&#8217;s proposal because it came from within the WHATWG. That&#8217;s not the case, but it must be said: the fact that <code>srcset</code> was so quickly added to the spec (albeit in a different form) doesn&#8217;t look good. It&#8217;s easy to understand why the smart folks in the <a href="http://www.w3.org/community/respimg/">Responsive Images Community Group</a> felt miffed.</p>

<p>But let&#8217;s be clear: this is exactly how the WHATWG is supposed to work. Use-cases are evaluated and whatever Hixie thinks is best solution gets put in the spec, regardless of how popular or unpopular it is.</p>

<p>Now, if that sounds abhorrent to you, I completely understand. A dictatorship <em>should</em> cause us to recoil.</p>

<p>That&#8217;s where the W3C come in. Their model is completely different. Everything is done by committee there.</p>

<p>Steve Faulkner chimed in on Tim&#8217;s post with <a href="http://timkadlec.com/2012/05/wtfwg/comment-page-1/#div-comment-71618">his take on the two groups</a>:</p>

<blockquote>
  <p>It seems like the development of HTML has turned full circle, the WHATWG was formed to overthrow the hegemony of the W3C, now the W3C acts as a counter to the hegemony of the WHATWG.</p>
</blockquote>

<p>I think he&#8217;s right. The W3C keeps the rapid, sometimes anarchic approach of the WHATWG in check. But the opposite is also true. Without the impetus provided by the WHATWG, I&#8217;m not sure that the W3C HTML Working Group would ever get anything done. There&#8217;s a balance that actually works quite well in practice.</p>

<p>Back to the situation with responsive images&#8230;</p>

<p>Unfortunately, it appears to people within the Responsive Images Community Group that all their effort was wasted because their proposed solution was summarily rejected. In actuality all the use-cases they gathered were immensely valuable. But it&#8217;s certainly true that the WHATWG didn&#8217;t make it clearer how and where developers could best contribute.</p>

<p>Community Groups are a W3C creation. They don&#8217;t have anything to do with the WHATWG, who do all their work on their own mailing list, their own wiki and their own IRC channel.</p>

<p>I do think that the W3C Community Groups offer a good place to go bike-shedding on problems. That&#8217;s a term that&#8217;s usually used derisively but sometimes it&#8217;s good to have a good ol&#8217; bike-shedding without clogging up the mailing list for everyone. But it needs to be clear that there&#8217;s a big difference between a Community Group and a Working Group.</p>

<p>I wish the WHATWG had done a better job of communicating to newcomers how best to contribute. It would have avoided a lot of the frustrations <a href="http://www.alistapart.com/articles/responsive-images-and-web-standards-at-the-turning-point/">articulated by Wilto</a>:</p>

<blockquote>
  <p>Unfortunately, we were laboring under the impression that Community Groups shared a deeper inherent connection with the standards bodies than it actually does.</p>
</blockquote>

<p>But in any case, <a href="http://html5doctor.com/html5-adaptive-images-end-of-round-one/">as Doctor Bruce writes</a> at least now there&#8217;s a proposed solution for responsive images in HTML: The Living Standard:</p>

<blockquote>
  <p>I don’t really care which syntax makes the spec, as long as it addresses the majority of use cases and it is usable by authors. I’m just glad we’re discussing the adaptive image problem at all.</p>
</blockquote>

<p>So let&#8217;s take a look at the technical details.</p>

<h3>src code</h3>

<p>The Responsive Images Community Group came up with a proposal based off the idea of minting a new element, called say <code>picture</code>, that mimics the behaviour of <code>video</code></p>

<pre><code>&lt;picture alt="image description"&gt;
  &lt;source src="/path/to/image.png" media="(min-width: 600px)"&gt;
  &lt;source src="/path/to/otherimage.png" media="(min-width: 800px)"&gt;
  &lt;img src="/path/to/image.png" alt="image description"&gt;
&lt;/picture&gt;
</code></pre>

<p>One of the reasons why a new element was chosen rather than extending the existing <code>img</code> element was due to a misunderstanding. The WHATWG had explained that the <em>parsing</em> of <code>img</code> couldn&#8217;t be easily altered. That means that <code>img</code> must remain a self-closing element&#8212;any solution that requires a closing <code>/img</code> tag wouldn&#8217;t work. Alas, that was taken to mean that extending the <code>img</code> element in any way was off the cards.</p>

<p>The <code>picture</code> proposal has a number of things going for it. Its syntax is easily understandable for authors: if you know media queries, then you know how to use <code>picture</code>. It also has a good fallback for older browsers : a regular <code>img</code> element. This fallback mechanism (and the idea of multiple <code>source</code> elements with media queries) is exactly how the <code>video</code> element is specced.</p>

<p>Unfortunately using media queries on the <code>source</code>s of videos has proven to be very tricky for implementors, so they don&#8217;t want to see that pattern repeated.</p>

<p>Another issue with multiple <code>source</code> elements is that parsers must wait until the closing <code>/picture</code> tag before they can even begin to evaluate which image to show. That&#8217;s not good for performance.</p>

<p>So the alternate solution, based on Ted&#8217;s proposal, extends the <code>img</code> element using a new <code>srcset</code> attribute that takes a comma-separated list of values:</p>

<pre><code>&lt;img alt="image description"
src="/path/to/fallbackimage.png"
srcset="/path/to/image.png 800w, /path/to/otherimage.png 600w"&gt;
</code></pre>

<p>Not nearly as pretty, I think you&#8217;ll agree. But it is actually nice and compact for the &#8220;retina display&#8221; use-case:</p>

<pre><code>&lt;img alt="image description" src="/path/to/image.png" srcset="/path/to/otherimage.png 2x"&gt;
</code></pre>

<p>Just to be clear, that does not mean that <code>otherimage.png</code> is twice the size of <code>image.png</code> (though it could be). What you&#8217;re actually declaring is &#8220;Use <code>image.png</code> unless the <em>device</em> supports double-pixel density, in which case, use <code>otherimage.png</code>.&#8221;</p>

<p>Likewise, when I declare:</p>

<pre><code>srcset="/path/to/image.png 600w 400h"
</code></pre>

<p>&#8230;it does <em>not</em> mean that <code>image.png</code> is 600 pixels wide by 400 pixels tall. Instead, it means that an action should be taken if the <em>viewport</em> matches those dimensions.</p>

<p>It took me a while to wrap my head around that distinction: I&#8217;m used to attributes describing the element they&#8217;re attached to, not the viewport.</p>

<p>Now for the really tricky bit: what do those numbers&#8212;600w and 400h&#8212;mean? Currently <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/embedded-content-1.html#attr-img-srcset">the spec is giving conflicting information</a>.</p>

<p>Each image that&#8217;s listed in the <code>srcset</code> comma-separated list can have up to three values associated with it: <code>w</code>, <code>h</code>, and x. The x is pretty clear: that&#8217;s the pixel density of the device. The <code>w</code> and <code>h</code> values refer to the width and height of the viewport &#8230;but it&#8217;s not clear if they mean min-width/height or max-width/height.</p>

<p>If I&#8217;m taking a &#8220;Mobile First&#8221; approach to development, then <code>srcset</code> will meet my needs <em>if</em> <code>w</code> and <code>h</code> refer to min-width and min-height.</p>

<p>In this example, I&#8217;ll just use <code>w</code> to keep things simple:</p>

<pre><code>&lt;img src="small.png" srcset="medium.png 600w, large.png 800w"&gt;
</code></pre>

<p>(Expected behaviour: use small.png unless the viewport is wider than 600 pixels, in which case use medium.png unless the viewport is wider than 800 pixels, in which case use large.png).</p>

<p>If, on the other hand, <code>w</code> and <code>h</code> refer to max-width and max-height, I <em>have to</em> take a &#8220;Desktop First&#8221; approach:</p>

<pre><code>&lt;img src="large.png" srcset="medium.png 800w, small.png 600w"&gt;
</code></pre>

<p>(Expected behaviour: use large.png unless the viewport is narrower than 800 pixels, in which case use medium.png unless the viewport is narrower than 600 pixels, in which case use small.png).</p>

<p>One of the advantages of media queries is that, because they support both min- and max- width, they can be used in either use-case: &#8220;Mobile First&#8221; or &#8220;Desktop First&#8221;.</p>

<p>Because the <code>srcset</code> syntax will support <em>either</em> min- or max- width (but not both), it will therefore favour one case at the expense of the either.</p>

<p>Both use-cases are valid. Personally, I happen to use the &#8220;Mobile First&#8221; approach, but that doesn&#8217;t mean that other developers shouldn&#8217;t be able to take a &#8220;Desktop First&#8221; approach if they want. By the same logic, I don&#8217;t much like the idea of <code>srcset</code> forcing me to take a &#8220;Desktop First&#8221; approach.</p>

<p>My only alternative, if I want to take a &#8220;Mobile First&#8221; approach, is to duplicate image paths <em>and</em> declare ludicrous breakpoints:</p>

<pre><code>&lt;img src="small.png" srcset="small.png 600w, medium.png 800w, large.png 99999w"&gt;
</code></pre>

<p>I <em>hope</em> that this part of the spec offers a way out:</p>

<blockquote>
  <p>for the purposes of this requirement, omitted width descriptors and height descriptors are considered to have the value &#8220;Infinity&#8221;</p>
</blockquote>

<p>I think that means I should be able to write this:</p>

<pre><code>&lt;img src="small.png" srcset="small.png 600w, medium.png 800w, large.png"&gt;
</code></pre>

<p>It&#8217;s all quite confusing and <code>srcset</code> doesn&#8217;t have anything approaching the extensibility of media queries, but I hope we can get it to work somehow.</p>

<hr />
<p>
Tagged with
<a rel="tag" href="http://adactio.com/journal/tags/responsive">responsive</a>
<a rel="tag" href="http://adactio.com/journal/tags/images">images</a>
<a rel="tag" href="http://adactio.com/journal/tags/standards">standards</a>
<a rel="tag" href="http://adactio.com/journal/tags/browsers">browsers</a>
<a rel="tag" href="http://adactio.com/journal/tags/whatwg">whatwg</a>
<a rel="tag" href="http://adactio.com/journal/tags/w3c">w3c</a>
<a rel="tag" href="http://adactio.com/journal/tags/process">process</a>
<a rel="tag" href="http://adactio.com/journal/tags/markup">markup</a>
<a rel="tag" href="http://adactio.com/journal/tags/html">html</a>
<a rel="tag" href="http://adactio.com/journal/tags/adaptive">adaptive</a>
</p>
]]>
			</description>
			<pubDate>Wed, 16 May 2012 17:33:18 GMT</pubDate>
			<guid>http://adactio.com/journal/5474/</guid>
			<category>responsive</category>
			<category>images</category>
			<category>standards</category>
			<category>browsers</category>
			<category>whatwg</category>
			<category>w3c</category>
			<category>process</category>
			<category>markup</category>
			<category>html</category>
			<category>adaptive</category>
		</item>
		<item>
			<title>Your local mobile device lab</title>
			<link>http://adactio.com/journal/5446/</link>
			<description>
<![CDATA[
<p>Last week I described how I go about <a href="http://adactio.com/journal/5433/">getting hold of mobile devices to test with</a> at <a href="http://clearleft.com/">Clearleft</a>. I finished by throwing open the door to any other web devs in Brighton who want to test on our devices:</p>

<blockquote>
  <p>We’ve always had an open-door policy here, so if you want to pop around, use our WiFi, and test on our devices, you’re more than welcome.</p>
</blockquote>

<p>There was a great response from my fellow Brightonians offering to add some of their devices to the collection:</p>

<blockquote class="twitter-tweet" data-in-reply-to="197024655930957824"><p>@<a href="https://twitter.com/adactio">adactio</a> I have a Nokia N9 and a 3GS that I can share, if it&#8217;d be ok to leave them there?</p>— Aegir Hallmundur (@aegirthor) <a href="https://twitter.com/aegirthor/status/197027086131671040" data-datetime="2012-04-30T18:18:12+00:00">April 30, 2012</a></blockquote>

<blockquote class="twitter-tweet" data-in-reply-to="197024655930957824"><p>@<a href="https://twitter.com/adactio">adactio</a> @<a href="https://twitter.com/clearleft">clearleft</a> I&#8217;ve got a few phones that you don&#8217;t that I&#8217;m happy to leave in your capable hands. WP7, B2G, etc</p>— Remy Sharp (@rem) <a href="https://twitter.com/rem/status/197025990629801986" data-datetime="2012-04-30T18:13:51+00:00">April 30, 2012</a></blockquote>

<script src="//platform.twitter.com/widgets.js" charset="utf-8"></script>

<p><span class="vcard"><a href="http://ministryoftype.co.uk/" class="url" rel="friend met colleague"><abbr title="Aegir Hallmundir" class="fn">Aegir</abbr></a></span> popped &#8216;round yesterday and dropped off an iPhone 3GS and a very cute <a href="http://swipe.nokia.com/">Nokia N9</a>.</p>

<p><a href="http://www.flickr.com/photos/adactio/6993106580/" title="Getting some testing devices from @aegirthor by adactio, on Flickr"><img src="http://farm9.staticflickr.com/8027/6993106580_dafffb7a0d_m.jpg" width="240" height="240" alt="Getting some testing devices from @aegirthor"></a></p>

<p>This morning I arrived in to the office to find that <span class="vcard"><a href="http://aroncarroll.com/" class="url" rel="acquaintance met colleague"><abbr class="fn" title="Aron Carroll">Aron</abbr></a></span> had dropped off a Samsung Galaxy Tab.</p>

<p>This is great! Just by opening up the testing suite to everyone, it has now expanded beyond what I had been able to gather together by myself.</p>

<p><span class="vcard"><a href="http://joshemerson.co.uk/" class="url" rel="friend met co-worker"><abbr class="fn" title="Josh Emerson">Josh</abbr></a></span> has put together <a href="http://clearleft.com/testlab/">a page on the Clearleft site</a> that we&#8217;ll keep updated with a list of the devices we&#8217;ve got.</p>

<p>We&#8217;ve ordered <a href="http://www.ebay.co.uk/itm/Mobile-phone-stand-easel-new-style-ideal-charging-/330580811355">some nice stands</a> for the phones so that we can clear away some of the cable clutter. We don&#8217;t want the experience of testing to be any more unpleasant than it needs to be. To that end, I&#8217;ve installed <a href="http://labs.adobe.com/technologies/shadow/">Adobe Shadow</a> on the iOS and Android devices.</p>

<p>If you want to test a site that isn&#8217;t live yet, I find that services like <a href="https://showoff.io/">showoff.io</a> and <a href="http://progrium.com/localtunnel/">localtunnel</a> are handy for previewing local sites. Do bear in mind that these devices are intended for testing <em>websites</em>: if you want to install apps or update software, sorry; that&#8217;s not what the test lab is for.</p>

<p>If you&#8217;re based in Brighton, <a href="http://clearleft.com/canhelp/">pop &#8216;round</a> whenever you want to use <a href="http://clearleft.com/testlab/">our devices</a>.</p>

<p>If you&#8217;re not based in Brighton, maybe you could kick-start a similar sharing scheme with a local company or co-working space. Belfast, Bristol, Manchester, Birmingham &#8230;you&#8217;ve got loads of smart geeks and I bet they&#8217;ve got plenty of devices they could be sharing.</p>

<p>There are potential pitfalls to opening up a testing suite like this. What about the insurance? What about theft? What about breakage? But the thing about potential pitfalls is that they&#8217;re just that: potential. I&#8217;m treating all of them as <a href="http://en.wikipedia.org/wiki/You_ain't_gonna_need_it" rel="tag"><abbr title="You Ain't Gonna Need It">YAGNI</abbr></a> issues. I&#8217;ll address any problems if and when they occur rather than planning for worst-case scenarios.</p>

<p>&#8220;What&#8217;s the worst that could happen?&#8221; is really only valuable as a rhetorical question.</p>

<hr />
<p>
Tagged with
<a rel="tag" href="http://adactio.com/journal/tags/mobile">mobile</a>
<a rel="tag" href="http://adactio.com/journal/tags/testing">testing</a>
<a rel="tag" href="http://adactio.com/journal/tags/devices">devices</a>
<a rel="tag" href="http://adactio.com/journal/tags/clearleft">clearleft</a>
<a rel="tag" href="http://adactio.com/journal/tags/brighton">brighton</a>
</p>
]]>
			</description>
			<pubDate>Fri, 04 May 2012 15:45:49 GMT</pubDate>
			<guid>http://adactio.com/journal/5446/</guid>
			<category>mobile</category>
			<category>testing</category>
			<category>devices</category>
			<category>clearleft</category>
			<category>brighton</category>
		</item>
		<item>
			<title>Questions for Mobilism</title>
			<link>http://adactio.com/journal/5442/</link>
			<description>
<![CDATA[
<p><span class="vevent">I’m going to <span class="location">Amsterdam</span> <abbr class="dtstart" title="2012-05-10">next week</abbr> for the <a href="http://mobilism.nl/2012" class="url summary">Mobilism</a> conference.</span> Bizarrely, there are <a href="http://mobilism.nl/2012/tickets">still tickets available</a>. I say “bizarrely&#8221; because it’s such an excellent event—it&#8217;s like the European equivalent of the <a href="http://bdconf.com/">Breaking Development</a> conference.</p>

<p>Don’t worry; I won’t be giving a presentation. I’ll leave that to experts like <span class="vcard"><a href="http://remysharp.com/" class="url" rel="friend met colleague"><abbr class="fn" title="Remy Sharp">Remy</abbr></a></span>, <span class="vcard"><a href="http://www.lyza.com/" class="url" rel="friend met colleague"><abbr class="fn" title="Lyza Danger Gardner">Lyza</abbr></a></span>, <span class="vcard"><a href="http://bradfrostweb.com/" class="url" rel="friend met colleague"><abbr class="fn" title="Brad Frost">Brad</abbr></a></span>, and <span class="vcard"><a href="http://jakearchibald.com/" class="url" rel="friend met colleague"><abbr class="fn" title="Jake Archibald">Jake</abbr></a></span>. But I will be getting up on the stage. I’m going to moderating not one, but two, panels. I think it’s going to be fun.</p>

<p>We’ll be reprising the Mobile Browser panel <a href="http://adactio.com/articles/4661/">from last year</a>. Once again, there will be representatives from Opera, RIM, and Nokia. This year Google is also joining the line-up. As usual, Apple will not be present.</p>

<p>The new addition to the schedule is <a href="http://mobilism.nl/2012/programme#api-panel">a panel on device and network APIs</a>. I will be playing the part of a curious but clueless web developer interested in such things …because, well, that’s what I am.</p>

<p>I plan to open up both panels to questions from the audience. While I don’t quite fall into <a href="http://www.cennydd.co.uk/2011/sorry-no-questions/">Cennydd’s camp</a>, it would be great if more people would read this article on <a href="http://chronicle.com/blogs/innovations/how-to-ask-a-question/32095">how to ask a question</a>:</p>

<blockquote>
  <p>You have not been invited to give a speech. Before you stand up, boil your thoughts down to a single point. Then ask yourself if this point is something you want to assert or something you want to find out. There are exceptions, but if your point falls into the category of assertion, you should probably remain seated.</p>
</blockquote>

<p>But I’m not planning to leave the questions entirely to the people in the room. Just as <a href="http://adactio.com/journal/4559/">I did last year</a>, I’d like to ask <em>you</em> to tell me what topics are burning in your mind when it comes to mobile browsers or device APIs.</p>

<p>Comments are open for one week. Let fly with your questions.</p>

<hr />
<p>
Tagged with
<a rel="tag" href="http://adactio.com/journal/tags/mobilism">mobilism</a>
<a rel="tag" href="http://adactio.com/journal/tags/conference">conference</a>
<a rel="tag" href="http://adactio.com/journal/tags/panel">panel</a>
<a rel="tag" href="http://adactio.com/journal/tags/questions">questions</a>
<a rel="tag" href="http://adactio.com/journal/tags/event">event</a>
</p>
]]>
			</description>
			<pubDate>Wed, 02 May 2012 18:45:25 GMT</pubDate>
			<guid>http://adactio.com/journal/5442/</guid>
			<category>mobilism</category>
			<category>conference</category>
			<category>panel</category>
			<category>questions</category>
			<category>event</category>
		</item>
		<item>
			<title>dConstruct optimisation</title>
			<link>http://adactio.com/journal/5439/</link>
			<description>
<![CDATA[
<p>When I was helping <span class="vcard"><a href="http://www.bevanstephens.com/" class="url" rel="friend met co-worker"><abbr class="fn" title="Bevan Stephens">Bevan</abbr></a></span> with making <a href="http://2012.dconstruct.org/">the dConstruct site</a>, I kept banging on to him about the importance of performance.</p>

<p>Don’t get me wrong: I wanted the site to <em>look</em> great, but I also very much wanted it to <em>feel</em> great …and nothing affects the feel of a site (the user’s experience, if you will) more than performance. As <a href="http://blog.cloudfour.com/first-thing-you-should-do-to-optimize-your-desktop-site-for-mobile/">Jason wrote</a>:</p>

<blockquote>
  <p>If you could only do one thing to prepare your desktop site for mobile and had to choose between employing media queries to make it look good on a mobile device or optimizing the site for performance, you would be better served by making the desktop site blazingly fast.</p>
</blockquote>

<p>And yet this fundamental aspect of how performant a site is going to be is all too often left until the development phase. I’d really like to see it taken into account much earlier on, during the UX and visual design phases.</p>

<p>Anyway, as the dConstruct site came together, I just kept asking “What would <span class="vcard"><a href="http://stevesouders.com/" class="fn url" rel="met acquaintance colleague">Steve Souders</a></span> do?”</p>

<p>For a start, that meant ripping out any <a href="http://html5boilerplate.com/">boilerplate</a> markup and CSS that was there “just in case.” I very much agree with <cite class="vcard"><a href="http://www.rachelandrew.co.uk/" class="url" rel="friend met colleague"><abbr class="fn" title="Rachel Andrew">Rachel</abbr></a></cite> when she says <a href="http://www.rachelandrew.co.uk/archives/2012/03/21/stop-solving-problems-you-dont-yet-have/"><cite>stop solving problems you don’t yet have</cite></a>. But one of the areas where the unfortunately-named <a href="http://html5boilerplate.com/">HTML5 Boilerplate</a> excels is in its suggestions for <a href="http://html5boilerplate.com/docs/htaccess/"><code>.htaccess</code> rules</a> so I made sure to rip off the best bits.</p>

<p>Initially jQuery was being included, but given how far browsers have come in their <a href="http://sharedfil.es/js-48hIfQE4XK.html">JavaScript support</a>, I was able to ditch it and <a href="http://2012.dconstruct.org/js/script.js">streamline the JavaScript</a> a bit.</p>

<p>Wherever possible, I made sure that background images in CSS were <a href="https://en.wikipedia.org/wiki/Base64">Base64</a> encoded as <a href="http://www.nczonline.net/blog/2010/07/06/data-uris-make-css-sprites-obsolete/">data URIs</a>; icons, textures, and the like. That helped to <a href="http://developer.yahoo.com/performance/rules.html">reduce the number of HTTP requests</a>—one of the easy wins for improving performance.</p>

<p>I’ve already mentioned the <a href="http://adactio.com/journal/5414/">conditional loading</a> that’s going on.</p>

<p>Then there’s the thorny issue of <a href="http://adactio.com/journal/4997/">responsive images</a>. The <a href="http://2012.donstruct.org/">dConstruct 2012 site</a> is similar to <a href="http://archive.dconstruct.org/">the dConstruct archive</a> in that there is no correlation between browser width and image: quite often, a <em>smaller</em> image is required for wider screens than for narrower viewports because of the presence of a grid. So instead of trying to come up with some complex interplay of client and server cross-communication to figure out which size image would be appropriate to serve up, I instead took the same approach as I did for the archive site: optimise the hell out of images, regardless of whether they’re going to be viewed in a desktop or a mobile device.</p>

<p>Take a look at <a href="http://www.flickr.com/photos/29022619@N03/6116801279/">the original image of Kevin Slavin</a> compared to <a href="http://archive.dconstruct.org/i/speakers/2011_kevin_slavin.jpg">the version that appears on the dConstruct archive</a>.</p>

<p><a href="http://www.flickr.com/photos/29022619@N03/6116801279/"><img src="http://farm7.staticflickr.com/6086/6116801279_0397a79aeb.jpg" alt="Kevin Slavin"></a>
<a href="http://archive.dconstruct.org/2011/realityisplenty"><img src="http://archive.dconstruct.org/i/speakers/2011_kevin_slavin.jpg" alt="Kevin Slavin, retouched"></a></p>

<p>See how everything except the face is so much blurrier in the final version? That isn’t just an attempt to introduce some cool <a href="https://en.wikipedia.org/wiki/Bokeh">bokeh</a>. It makes for much smaller JPGs with fewer <a href="http://en.wikipedia.org/wiki/Jaggies">jaggy</a> artefacts. And because human beings tend to focus on other human faces, the technique isn’t really consciously noticeable (although you’ll notice it now that I’ve pointed it out to you).</p>

<p>The design of <a href="http://2012.dconstruct.org/">the 2012 dConstruct site</a> called for monochrome images with colour filters applied.</p>

<p><a href="http://2012.dconstruct.org/conference/hammersley/"><img src="http://2012.dconstruct.org/img/speakers/ben.png" alt="Ben Hammersley"></a></p>

<p>That turned out to be a fortunate boon for optimising the images. This time we were using PNGs rather than JPGs and we were able to get the number of colours down to 32 or even 16. Run them through <a href="http://imageoptim.com/">Image Optim</a> or <a href="http://www.smushit.com/">Smushit</a> and you can squeeze even more bytes out of them.</p>

<p>The funny thing is that sweating the file sizes of images used to be part and parcel of web development. Back in the nineties, there was something of <a href="http://www.zeldman.com/icon.html">an aesthetic</a> that grew out of the need to optimise images with limited (<a href="http://www.webdesign.org/web-design-basics/color-theory/web-safe-colours.5953.html">web-safe</a>!) colour palettes. That was because bandwidth was at a premium and you could be pretty sure that plenty of people were accessing your site on slow connections.</p>

<p>Well, here we are fifteen years later and thanks to the rise of mobile, bandwidth is once again at a premium and we can be pretty sure that plenty of people are accessing our sites on slow connections. Yet again, mobile is highlighting issues that were always there. When did we get so lazy and decide it was acceptable to send giant unoptimised images down the pipe to our long-suffering visitors?</p>

<p><a href="http://www.thewatchmakerproject.com/post/throwing-out-the-kitchen-sink/">Mathew Pennell recently wrote</a>:</p>

<blockquote>
  <p>…it’s certainly true that the golden rule I grew up with – no page should ever be over 100Kb – has long since been mothballed.</p>
</blockquote>

<p>But why? That seems like a perfectly good and still-relevant rule to me.</p>

<p>Alas, on <a href="http://2012.dconstruct.org/">the dConstruct site</a> I wasn’t able to hit that target. With an unprimed cache, the home page comes in at around 300<abbr title="Kilobytes">K</abbr> (it’s 17<abbr title="Kilobytes">K</abbr> with a primed cache). By far the largest file is the CSS, weighing at 113<abbr title="Kilobytes">K</abbr>, followed by the web font, <a href="http://fontdeck.com/font/futura/boldoblique">Futura bold oblique</a>, at 32<abbr title="Kilobytes">K</abbr>.</p>

<p>By the way, when it comes to analysing performance in the browser, this <a href="http://jtaby.com/2012/04/23/modern-web-development-part-1.html">missing manual for the Webkit inspector</a> is really, really handy. I also ran the site <a href="https://developers.google.com/pagespeed/#url=http://2012.dconstruct.org/">through Google Page Speed</a> but it seems that the user-agent chooses an arbitrary browser width (960? 1024?) so some of the advice about scaling images needs to be taken with a pinch of salt when applied to responsive designs.</p>

<p>I took a look at some other conference sites too. The <a href="http://2012.buildconf.com/">beautiful site for the Build conference</a> comes in at just under a megabyte for the homepage—it has quite a few fonts and images. It also has a monochrome aesthetic going on so I suspect quite a few of those images could be squeezed down (and some far-future expiry dates would help for repeat visitors).</p>

<p>Then there’s <a href="http://mobilism.nl/2012">site for this year’s Mobilism conference</a> which is blazingly fast. The combined file size on the homepage isn’t that different to the dConstruct site (although the CSS is significantly smaller) and I suspect there’s some server-side wizardry going on. I’ll have to corner <span class="vcard"><a href="http://www.the-haystack.com/" class="url" rel="friend met colleague"><abbr class="fn" title="Stephen Hay">Stephen</abbr></a></span> at the conference next week and quiz him about it.</p>

<p>For now, server-side performance optimisation is something beyond my ken. I should really do something about that, especially as I’m expecting the dConstruct site to take a hammering the day that tickets go sale (May 29th—save the date).</p>

<p>In the meantime, there’s still plenty I can do on the front end. <a href="http://www.brucelawson.co.uk/2012/what-users-want-from-mobile-and-what-we-can-re-learn-from-them/">As Bruce put it</a>:</p>

<blockquote>
  <p>It seems to me that old-fashioned, oh-so-dull techniques might not be ready for retirement yet. You know: well-crafted HTML, keeping JavaScript for progressive enhancement rather than a pre-requisite for the page even displaying, and testing across browsers.</p>
</blockquote>

<p>All those optimisation techniques we learned in the 90s—and even wacky ideas like <a href="http://adactio.com/journal/5208/"><code>lowsrc</code></a>—are back in fashion. Everything old is new again.</p>

<hr />
<p>
Tagged with
<a rel="tag" href="http://adactio.com/journal/tags/performance">performance</a>
<a rel="tag" href="http://adactio.com/journal/tags/optimisation">optimisation</a>
<a rel="tag" href="http://adactio.com/journal/tags/development">development</a>
<a rel="tag" href="http://adactio.com/journal/tags/images">images</a>
<a rel="tag" href="http://adactio.com/journal/tags/responsive">responsive</a>
</p>
]]>
			</description>
			<pubDate>Tue, 01 May 2012 17:24:31 GMT</pubDate>
			<guid>http://adactio.com/journal/5439/</guid>
			<category>performance</category>
			<category>optimisation</category>
			<category>development</category>
			<category>images</category>
			<category>responsive</category>
		</item>
		<item>
			<title>Left to our own devices</title>
			<link>http://adactio.com/journal/5433/</link>
			<description>
<![CDATA[
<p>In the final part of his series on responsive design in .net magazine, <a href="http://www.netmagazine.com/tutorials/build-responsive-site-week-going-further-part-5">Paul talks about testing</a>:</p>

<blockquote>
  <p>The key thing to remember here is that <em>any testing is better than no testing</em>. Build up a test suite as large as you can afford, and find opportunities to test on other devices whenever you can.</p>
</blockquote>

<p>I agree wholeheartedly and I think that any kind of testing with real devices should be encouraged. I find it disheartening when somebody blogs or tweets about testing on a particular device, only to be rebuffed with sentiments like “<a href="http://twitter.com/klayon/status/189745118436278272">it isn’t enough</a>.” It’s true—it <strong>isn’t</strong> enough …but it’s <em>never</em> enough. And the fact that a developer is doing any testing at all is a good thing.</p>

<p>There are some good resources out there to help you get started in putting together a collection of test devices.</p>

<ul>
<li><a href="http://mobiletestingfordummies.tumblr.com/">Testing for dummies</a> is a great blog devoted specifically to testing responsive designs on mobile devices.</li>
<li><span class="vcard"><a href="http://www.lukew.com/" class="url" rel="friend met colleague"><abbr class="fn" title="Luke Wroblewski">Luke</abbr></a></span> gathered a number of links to device arsenals on <a href="https://bagcheck.com/blog/22-mobile-device-testing-the-gear">this Bagcheck post</a>.</li>
<li><span class="vcard"><a href="http://stephanierieger.com/" class="url" rel="friend met colleague"><abbr class="fn" title="Stephanie Rieger">Stephanie</abbr></a></span> wrote about <a href="http://stephanierieger.com/strategies-for-choosing-test-devices/">strategies for choosing test devices</a>.</li>
</ul>

<p>Actually, you should probably just read everything on Stephanie’s site: it’s all thoughtful and useful. In her post on <a href="http://stephanierieger.com/the-value-of-1000-androids/">the value of 1000 Androids</a> she wrote:</p>

<blockquote>
  <p>The dirty little secret is that the more you test—the more accurately you will determine <em>when it’s ok not to</em>.</p>
</blockquote>

<p>That’s crucial. I think there’s <a href="http://twitter.com/klayon/status/189742828551798785">a common misunderstanding</a> that <em>testing</em> on many different devices means <em>developing</em> for many different devices. Nothing could be further from the truth. Just as in the world of the desktop, we shouldn’t be developing for <strong>any</strong> specific devices or browsers. That’s why we develop with standards.</p>

<p>In fact I’ve found that one of the greatest benefits of testing on as many different platforms as possible is that it stops me from straying down the path of device-specific development. When I come across a problem in my testing, my reaction isn’t to think “how can I fix this problem on this particular device?”, which would probably involve throwing more code at it. Instead I think “how can I avoid this problem?” The particular device may have <em>highlighted</em> the issue, but there’s almost always a more fundamental problem to be tackled …and it’s very rarely tackled by throwing more code at it.</p>

<p>I wish I had more devices to test on …even if it might increase the risk of me <a href="http://www.theregister.co.uk/2008/03/06/anti_terrorist_hotline/">getting reported to the police</a>. At the same time, I realise that it’s a pretty crumby and <a href="http://twitter.com/Malarkey/status/189739052549931010">expensive situation for developers</a>, particularly freelancers. As <a href="http://www.netmagazine.com/tutorials/build-responsive-site-week-going-further-part-5">Paul wrote</a>:</p>

<blockquote>
  <p>Not only does it present a potential barrier to entry for anyone wanting to build responsive websites, but it encourages the purchase of yet more devices and gadgets.</p>
</blockquote>

<p>I’ve been keeping my costs down by shopping in <a href="http://en.wikipedia.org/wiki/CeX">dodgy second-hand electronics shops</a> that sell devices that have fallen off the back of a lorry. Most of them sell phones with a classification of A, B, or C. If something is labelled A, it is mint condition. If something is labelled C, there might be something wrong with it or you might not get all the cables or the box. But for my purposes, that’s absolutely fine. If anything, I’m usually hunting for outdated devices with older versions of operating systems.</p>

<p>So far I’ve got:</p>

<ul>
<li>An HTC thingy running Windows Phone 7.5,</li>
<li>Another HTC thingy running Android 2.3.4,</li>
<li>A little Samsung running Android 2.2,</li>
<li>A Blackberry 9800 (Torch, right?),</li>
<li>A Blackberry Playbook,</li>
<li>A Kindle,</li>
<li>An iPod running iOS 3.1.3,</li>
<li>An iPad running iOS 5.something,</li>
<li>And I’ve got my own iPhone 4 and Kindle Touch.</li>
</ul>

<p><a href="http://www.flickr.com/photos/adactio/6800969243/"><img src="http://farm8.staticflickr.com/7167/6800969243_7338e86ee7_n.jpg" alt="Devices"></a></p>

<p>I don’t know about you, but my eyes glaze over when it comes to phone models and operating system numbers, especially when they just end up <a href="http://blog.intercom.io/whats-in-a-name/">sounding like condoms</a>. Luckily we’ve got people like <span class="vcard"><a href="http://quirksmode.org/" class="url" rel="friend met colleague"><abbr class="fn" title="Peter-Paul Koch">PPK</abbr></a></span> to help us figure out <a href="http://www.alistapart.com/articles/smartphone-browser-landscape/">the smartphone browser landscape</a>.</p>

<p>You’ll notice plenty of glaring omissions in my paltry list—there’s nary a Nokia device to be found—but I aim to plug those gaps as soon as I can.</p>

<p>In the meantime I’ve been setting up a desk at the <a href="http://clearleft.com/">Clearleft</a> office for these devices so that they can stay charged up and within reach.</p>

<p><a href="http://www.flickr.com/photos/adactio/6982600162/"><img src="http://farm8.staticflickr.com/7109/6982600162_7cc1f230e1_n.jpg" alt="Devices"></a></p>

<p>We’ve always had an open-door policy here, so if you want to pop around, use our WiFi, and test on our devices, you’re more than welcome. Give me some advance warning <a href="http://twitter.com/adactio" rel="me">on Twitter</a> and I can put the kettle on for a cup of tea. We&#8217;re at <a href="http://maps.google.com/maps?q=BN14AJ">28 Kensington Street</a>, Suite 2.</p>

<p>Think of it as a quick’n’dirty, much smaller-scale version of <a href="http://mobileportland.com/device-lab">Mobile Portland’s Device Lab</a>.</p>

<hr />
<p>
Tagged with
<a rel="tag" href="http://adactio.com/journal/tags/testing">testing</a>
<a rel="tag" href="http://adactio.com/journal/tags/devices">devices</a>
<a rel="tag" href="http://adactio.com/journal/tags/mobile">mobile</a>
<a rel="tag" href="http://adactio.com/journal/tags/responsive">responsive</a>
<a rel="tag" href="http://adactio.com/journal/tags/development">development</a>
</p>
]]>
			</description>
			<pubDate>Mon, 30 Apr 2012 18:53:34 GMT</pubDate>
			<guid>http://adactio.com/journal/5433/</guid>
			<category>testing</category>
			<category>devices</category>
			<category>mobile</category>
			<category>responsive</category>
			<category>development</category>
		</item>
		<item>
			<title>Conditional CSS</title>
			<link>http://adactio.com/journal/5429/</link>
			<description>
<![CDATA[
<p>I got some great comments on my post about <a href="http://adactio.com/journal/5414/">conditionally loading content</a>.</p>

<p>Just to recap, I was looking for a way of detecting from JavaScript whether media queries have been executed in CSS without duplicating my breakpoints. That bit is important: I’m not looking for MatchMedia, which involves making media queries in JavaScript. Instead I’m looking for some otherwise-useless CSS property that I can use to pass information to JavaScript.</p>

<p><span class="vcard"><a href="http://tantek.com/" class="url" rel="friend met colleague"><abbr class="fn" title="Tantek Çelik">Tantek</abbr></a></span> initially suggested using good ol’ <code>voice-family</code>, which he has used for <a href="http://tantek.com/CSS/Examples/boxmodelhack.html">hacks in the past</a>. But, alas, that unsupported property isn’t readable from JavaScript.</p>

<p>Then Tantek suggested that, whatever property I end up using, I could apply it to an element that’s never rendered: <code>meta</code> or perhaps <code>head</code>. I like that idea.</p>

<p>A number of people suggested using <code>font-family</code>, citing <a href="https://github.com/adamdbradley/foresight.js">Foresight.js</a> as prior art. I tried combining that idea with Tantek’s suggestion of using an invisible element:</p>

<pre><code>@media screen and (min-width: 45em) {
    head {
        font-family: widescreen;
    }
}
</code></pre>

<p>Then I can read that in JavaScript:</p>

<pre><code>window.getComputedStyle(document.head,null).getPropertyValue('font-family')
</code></pre>

<p>It works! …except in Opera. Where every other browser returns whatever string has been provided in the <code>font-family</code> declaration, Opera returns the font that ends up actually getting used (Times New Roman by default).</p>

<p>I guess I could just wait a little while for Opera to <a href="http://www.netmagazine.com/news/opera-confirms-webkit-prefix-usage-121923">copy whatever Webkit browsers do</a>. (Ooh! Controversial!)</p>

<p>Back to the drawing board.</p>

<p><span class="vcard"><a href="http://stephaniehobson.ca" class="url" rel="friend met colleague"><abbr class="fn" title="Stephanie Hobson">Stephanie</abbr></a></span> suggested using <code>z-index</code>. I wouldn’t to do that in the body of my document for fear of screwing up any complex positioning I’ve got going on, but I could apply that idea to the <code>head</code> or a <code>meta</code> element:</p>

<pre><code>@media screen and (min-width: 45em) {
    head {
        z-index: 2;
    }
}
</code></pre>

<p>Alas, that doesn’t seem to work in Webkit; I just get back a value of <code>auto</code>. Curses! It works fine if it’s applied to an element in the <code>body</code> but like I said, I’d rather not screw around with the z-indexing of page elements. Ironically, it works fine in Opera</p>

<p>A number of people suggested using generated content! “But how’s that supposed to work?” I thought. “I won’t be able to reference the generated DOM node from my JavaScript, will I?”</p>

<p>It turns out that I’m an idiot. That second argument in <a href="https://developer.mozilla.org/en/DOM/window.getComputedStyle">the <code>getComputedStyle</code> method</a>, which I always just blindly set to <code>null</code>, is there precisely so that you <em>can</em> access pseudo-elements like generated content.</p>

<p><span class="vcard"><a href="http://davemcdermid.co.uk" class="fn url">Dave McDermid</a></span>, <span class="vcard"><a href="http://aarontgrogg.com/" class="fn url">Aaron T. Grogg</a></span>, <span class="vcard"><a href="http://collino.me/" class="fn url">Colin Olan</a></span>, <span class="vcard"><a href="http://elwin.nu" class="fn url">Elwin Schmitz</a></span>, <span class="vcard"><a href="http://music.emilbjorklund.com/" class="url" rel="friend met colleague"><abbr class="fn" title="Emil Björklund">Emil</abbr></a></span>, and <span class="vcard"><a href="http://andyrossi.me/" class="fn url">Andy Rossi</a></span> arrived at the solution roundabout the same time.</p>

<p>Here’s <a href="http://seesparkbox.com/foundry/breakpoint_checking_in_javascript_with_css_user_values">Andy’s write-up</a> <a href="https://gist.github.com/2482049">and code</a>. His version uses transition events to fire the <code>getComputedStyle</code> check: probably overkill for what I want to do, but very smart thinking.</p>

<p>Here’s <a href="https://gist.github.com/2481019">Emil’s code</a>. I was initially worried about putting unnecessary generated content into the DOM but the <code>display:none</code> he includes should make sure that it’s never seen (or read by screenreaders).</p>

<p>I could just generate the content on the <code>body</code> element:</p>

<pre><code>@media all and (min-width: 45em) {
    body:after {
        content: 'widescreen';
        display: none;
    }
}
</code></pre>

<p>It isn’t visible, but it <em>is</em> readable from JavaScript:</p>

<pre><code>var size = window.getComputedStyle(document.body,':after').getPropertyValue('content');
</code></pre>

<p>And with that, I can choose whether or not to load some secondary content into the page depending on the value returned:</p>

<pre><code>if (size == 'widescreen') {
    // Load some more content.
}
</code></pre>

<p>Nice!</p>

<p>As to whether it’s an improvement over what I’m currently doing (testing for whether columns are floated or not) …probably. It certainly seems to maintain a nice separation between style and behaviour while at the same time allowing a variable in CSS to be read in JavaScript.</p>

<p>Thanks to everyone who responded. Much appreciated.</p>

<p><strong>Update</strong>: If you&#8217;re finding that some browsers are including the quotes in the returned <code>:after</code> value, try changing 
 <code>if (size == 'widescreen')</code> to <code>if (size.indexOf("widescreen") !=-1)</code>. Thanks to multiple people who pointed this out.</p>

<hr />
<p>
Tagged with
<a rel="tag" href="http://adactio.com/journal/tags/css">css</a>
<a rel="tag" href="http://adactio.com/journal/tags/javascript">javascript</a>
<a rel="tag" href="http://adactio.com/journal/tags/conditional">conditional</a>
<a rel="tag" href="http://adactio.com/journal/tags/loading">loading</a>
<a rel="tag" href="http://adactio.com/journal/tags/responsive">responsive</a>
<a rel="tag" href="http://adactio.com/journal/tags/code">code</a>
</p>
]]>
			</description>
			<pubDate>Fri, 27 Apr 2012 14:35:42 GMT</pubDate>
			<guid>http://adactio.com/journal/5429/</guid>
			<category>css</category>
			<category>javascript</category>
			<category>conditional</category>
			<category>loading</category>
			<category>responsive</category>
			<category>code</category>
		</item>
		<item>
			<title>Fanfare for the common breakpoint</title>
			<link>http://adactio.com/journal/5425/</link>
			<description>
<![CDATA[
<p><a href="http://www.netmagazine.com/">.net Magazine</a> is running a series of articles on their site right now as part of their responsive week. There&#8217;s some great stuff in there: <span class="vcard"><a href="http://paulrobertlloyd.com/" class="url" rel="friend met co-worker"><abbr class="fn" title="Paul Robert Lloyd">Paul</abbr></a></span> is writing a series of articles&#8212;one a day&#8212;going <a href="http://www.netmagazine.com/tutorials/build-responsive-site-week-designing-responsively-part-1">step-by-step</a> through the design and development of <a href="http://www.netmagazine.com/files/tutorials/demos/2012/04/build-a-responsive-site-in-a-week-media-queries-part-4/demo/demo.html">a responsive site</a>, and <span class="vcard"><a href="http://twitter.com/wilto" class="url" rel="colleague"><abbr class="fn" title="Mat Marquis">Wilto</abbr></a></span> has written a great summation of <a href="http://www.netmagazine.com/features/state-responsive-images">the state of responsive images</a>.</p>

<p>There&#8217;s also <a href="http://www.netmagazine.com/interviews/ethan-marcotte-answers-your-responsive-web-design-questions">an interview with Ethan</a> in which he answers some reader-submitted questions. The final question is somewhat leading:</p>

<blockquote>
  <p>What devices (smartphones/tablets) and breakpoints do you typically develop and test with?</p>
</blockquote>

<p>Ethan rightly responds:</p>

<blockquote>
  <p>Well, I&#8217;m a big, big believer of matching breakpoints to the design, not to individual devices. If we&#8217;re after more future-proof responsive designs, we should stop thinking in terms of &#8216;320px&#8217;, &#8216;480px&#8217;, &#8216;768px&#8217;, or whatever – the web&#8217;s so much more flexible than that, and those pixels are a snapshot of the web as we know it today. Instead, we should focus on breakpoints tailored to the design we&#8217;re working on.</p>
</blockquote>

<p>He&#8217;s right. If we&#8217;re truly taking a <a href="http://adactio.com/journal/4523/">Content First</a> approach then we need to <a href="http://www.markboulton.co.uk/journal/comments/a-richer-canvas">&#8220;Start designing from the content out, rather than the canvas in.&#8221;</a></p>

<p>If we begin with some specific canvases (devices), they&#8217;re always going to be arbitrary. There are <a href="http://mobiletestingfordummies.tumblr.com/post/20056227958/testing">so many different screen sizes and ratios</a> out there that it doesn&#8217;t make sense to favour a handful of them out of tradition. 320, 480, 640 &#8230;those numbers aren&#8217;t any more special than any other screen widths.</p>

<p>But I now realise that I have been also been guilty of strengthening the hallowed status of those particular pixel widths. When <a href="http://www.flickr.com/photos/adactio/sets/72157625017847324/">I post screenshots to Flickr</a> or include <a href="http://adactio.com/articles/4938/">screenshots in presentations</a> I automatically do what <a href="http://mediaqueri.es/">the Media Queries site</a> does: I take snapshots at &#8220;traditional&#8221; widths like 320, 480, 640, 800, and 1024 pixels.</p>

<p>Physician, heal thyself.</p>

<p>So I&#8217;ve started taking screenshots at different widths. For the screenshots I posted of the new dConstruct site, I took a series of screenshots from <a href="http://www.flickr.com/photos/adactio/6959746674/in/set-72157625017847324">200</a> to <a href="http://www.flickr.com/photos/adactio/6959745886/in/set-72157625017847324">1200</a> pixels in increments of 100.</p>

<p><a href="http://www.flickr.com/photos/adactio/6959746682/" title="dConstruct2012-300 by adactio, on Flickr"><img src="http://farm8.staticflickr.com/7222/6959746682_ffa90a6eeb_m.jpg" alt="dConstruct2012-300"></a>
<a href="http://www.flickr.com/photos/adactio/7105816155/" title="dConstruct2012-600 by adactio, on Flickr"><img src="http://farm9.staticflickr.com/8168/7105816155_d6bf2696db_m.jpg" alt="dConstruct2012-600"></a>
<a href="http://www.flickr.com/photos/adactio/7105815447/" title="dConstruct2012-900 by adactio, on Flickr"><img src="http://farm8.staticflickr.com/7222/7105815447_389661c2b3_m.jpg" alt="dConstruct2012-900"></a>
<a href="http://www.flickr.com/photos/adactio/6959745886/" title="dConstruct2012-1200 by adactio, on Flickr"><img src="http://farm8.staticflickr.com/7242/6959745886_b4b12fa5c0_m.jpg" alt="dConstruct2012-1200"></a></p>

<p>But really I should be illustrating the responsive nature of the design by taking screenshots at truly arbitrary widths: 173, 184, 398, 467, 543, 678, 832 &#8230;the sheer randomness of those kinds of numbers would better reflect <a href="http://stephanierieger.com/the-trouble-with-android/">the diversity of screen sizes</a> out there.</p>

<p>Of course what I should really be doing is posting <a href="http://www.flickr.com/photos/adactio/6960604182/">pictures of the website on actual devices</a>.</p>

<p><a href="http://www.flickr.com/photos/adactio/6960610178/" title="Devices by adactio, on Flickr"><img src="http://farm8.staticflickr.com/7200/6960610178_bf2d1f9398_n.jpg" width="320" height="239" alt="Devices"></a></p>

<p>I think our collective obsession with trying to nail down <a href="http://stuffandnonsense.co.uk/projects/320andup/">&#8220;common&#8221; breakpoints</a> has led to a fundamental misunderstanding about the nature of responsive design: it&#8217;s not about what happens at the breakpoints&#8212;it&#8217;s about what happens <em>between</em> the breakpoints.</p>

<p>I think <span class="vcard"><a href="http://www.zeldman.com/" class="url" rel="friend met colleague muse"><abbr class="fn" title="Jeffrey Zeldman">Jeffrey</abbr></a></span> demonstrated this misunderstanding when <a href="http://www.zeldman.com/2011/12/29/state-of-the-web-of-apps-devices-and-breakpoints/">he wrote about devices and breakpoints</a>:</p>

<blockquote>
  <p>Of course, if breakpoints are dead, responsive design is dead, because responsive design relies on breakpoints both in creative workflow and as a key to establishing user-need-and-context-based master layouts, i.e. a minimal layout for the user with a tiny screen and not much bandwidth, a more fleshed-out one for the netbook user, and so on.</p>
</blockquote>

<p>I was surprised that he suggested the long-term solution would be a shake-out of screen widths resulting in a de-facto standardisation:</p>

<blockquote>
  <p>But designers who persist in responsive or even adaptive design based on iPhone, iPad, and <em>leading</em> Android breakpoints will help accelerate the settling out of the market and its resolution toward a semi-standard set of viewports. This I believe.</p>
</blockquote>

<p>I don&#8217;t think that will happen. If anything, I think we will see even <em>more</em> diversity in screen sizes and ratios.</p>

<p>But more importantly, I don&#8217;t think it&#8217;s <em>desirable</em> to have a &#8220;standard&#8221; handful of screen widths, any more than it&#8217;s desirable to have a single rendering engine in every browser (yes, I know some developers actually wish for that: <a href="http://www.brucelawson.co.uk/2010/in-praise-of-ie6/">they know not what they do</a>).</p>

<p>I agree with <span class="vcard"><a href="http://stephanierieger.com/" class="url" rel="friend met colleague"><abbr class="fn" title="Stephanie Rieger">Stephanie</abbr></a></span>: <a href="http://stephanierieger.com/diversity-is-not-a-bug/">diversity is not a bug …it’s an opportunity</a>.</p>

<hr />
<p>
Tagged with
<a rel="tag" href="http://adactio.com/journal/tags/responsive">responsive</a>
<a rel="tag" href="http://adactio.com/journal/tags/design">design</a>
<a rel="tag" href="http://adactio.com/journal/tags/development">development</a>
<a rel="tag" href="http://adactio.com/journal/tags/breakpoints">breakpoints</a>
<a rel="tag" href="http://adactio.com/journal/tags/diversity">diversity</a>
<a rel="tag" href="http://adactio.com/journal/tags/devices">devices</a>
<a rel="tag" href="http://adactio.com/journal/tags/mobile">mobile</a>
<a rel="tag" href="http://adactio.com/journal/tags/mediaqueries">mediaqueries</a>
</p>
]]>
			</description>
			<pubDate>Thu, 26 Apr 2012 13:21:16 GMT</pubDate>
			<guid>http://adactio.com/journal/5425/</guid>
			<category>responsive</category>
			<category>design</category>
			<category>development</category>
			<category>breakpoints</category>
			<category>diversity</category>
			<category>devices</category>
			<category>mobile</category>
			<category>mediaqueries</category>
		</item>
		<item>
			<title>Conditionally loading content</title>
			<link>http://adactio.com/journal/5414/</link>
			<description>
<![CDATA[
<p><span class="vcard"><a href="http://www.bevanstephens.com/" class="url" rel="friend met co-worker"><abbr class="fn" title="Bevan Stephens">Bevan</abbr></a></span> did a great job on <a href="http://2012.dconstruct.org/">the dConstruct website</a>. I tried to help him out along the way, which mostly involved me doing a swoop’n&#8217;poop code review every now and then.</p>

<p>I was particularly concerned about performance so I suggested base-64 encoding background images wherever possible and squeezing inline images through <a href="http://imageoptim.com/">ImageOptim</a>. I also spotted an opportunity to do a bit of <a href="http://adactio.com/articles/5043/">conditional loading</a>.</p>

<p>Apart from the home page, just about every other page on the site features a fairly hefty image in the header …if you view it in a wide enough browser window. If you’re visiting with a narrow viewport, an image <a href="http://2012.dconstruct.org/img/conference/conference.png">like this</a> would just interfere with the linearised layout and be an annoying thing to scroll past.</p>

<p>So instead of putting the image in the markup, I put a <code>data-img</code> attribute on the <code>body</code> element:</p>

<pre><code>&lt;body data-img="/img/conference.png"&gt;</code></pre>

<p>Then in a JavaScript file that’s executed after the DOM has loaded, I check to see if the we’re dealing with a wide-screen viewport or not. Now, the way I’m doing this is to check to see if the header is linearised or if it’s being floated at all—if it’s being floated, that means the layout styles within my media queries are being executed, ergo this is a wide-screen view, and so I inject the image into the header.</p>

<p>I could’ve just put the image in the markup and used <code>display: none</code> in the CSS to hide it on narrow screens but:</p>

<ol>
<li>that won’t work for small-screen devices that don’t support media queries, and</li>
<li>the image would still be downloaded by everyone even if it isn’t displayed (a big performance no-no).</li>
</ol>

<p>I’m doing something similar with videos.</p>

<p>If you look at <a href="http://2012.dconstruct.org/conference/scott/">a speaker page</a> you’ll see that in the descriptions I’ve written, I link to a video of the speaker at a previous conference. So that content is available to everyone—it&#8217;s just a click away. On large viewports, I decided to pull in that content and display it in the page, kind of like I’m doing with the image in the header.</p>

<p>This time, instead of adding a <code>data-</code> attribute to the body, I’ve put in a <code>div</code> (with a <code>class</code> of “embed&#8221; and a <code>data-src</code> attribute) at the point in the document where I want to the video to potentially show up:</p>

<pre><code>&lt;div class="embed" data-src="http://www.youtube.com/embed/-2ZTmuX3cog"&gt;&lt;/div&gt;</code></pre>

<p>There are multiple video providers—YouTube, Vimeo, Blip—but their embed codes all work in much the same way: an <code>iframe</code> with a <code>src</code> attribute. That <code>src</code> attribute is what I’ve put in the <code>data-src</code> attribute of the <code>embed</code> <code>div</code>.</p>

<pre><code>&lt;div class="embed" data-src="http://player.vimeo.com/video/33692624"&gt;&lt;/div&gt;</code></pre>

<p>Once again, I use JavaScript after the DOM has loaded to see if the wide-screen media queries are being applied. This time I’m testing to see if the parent of the <code>embed</code> <code>div</code> is being floated at all. If it is, we must be viewing a widescreen layout rather than the linearised content. In that case, I generate the <code>iframe</code> and insert it into the <code>div</code>:</p>

<pre><code>(function(win){
    var doc=win.document;
    if (doc.getElementsByClassName &&amp; win.getComputedStyle) {
        var embed = doc.getElementsByClassName('embed')[0];
        if (embed) {
            var floating = win.getComputedStyle(embed.parentNode,null).getPropertyValue('float');
            if (floating != 'none') {
                var src = embed.getAttribute('data-src');
                embed.innerHTML = '&lt;iframe src="'+src+'" width="320" height="180" frameborder="0">&lt;/iframe&gt;';
            }
        }
    }
})(this);
</code></pre>

<p>In my CSS, I’m then using <span class="vcard"><a href="http://www.tjkdesign.com/" class="fn url">Thierry Koblentz</a></span>’s excellent technique for <a href="http://www.alistapart.com/articles/creating-intrinsic-ratios-for-video/">creating intrinsic ratios for video</a> to make sure the video scales nicely within its flexible container. The initial video proportion of 320x180 is maintained as a percentage: 180/320 = 0.5625 = 56.25%:</p>

<pre><code>.embed {
    position: relative;
    padding-bottom: 56.25%;
    height: 0;
}
.embed iframe {
    position: absolute;
    top:  0;
    left: 0;
    width: 100%;
    height: 100%;
}
</code></pre>

<p>The conditional loading is working fine for the header images and the embedded videos, but I still feel a bit weird about <a href="http://adactio.com/journal/5042/">testing for the presence of floating</a>.</p>

<p>I could use <a href="https://developer.mozilla.org/en/DOM/window.matchMedia">matchMedia</a> instead but then I’d probably have to use a <a href="https://github.com/paulirish/matchMedia.js/">polyfill</a> (another performance hit), and I’d still end up maintaining my breakpoints in two places: once in CSS, and again in JavaScript. Likewise, if I just used <code>documentElement.clientWidth</code>, I’d have to declare my breakpoints twice.</p>

<p><cite class="vcard"><a href="http://www.paulrhayes.com/" class="fn url">Paul Hayes</a></cite> <a href="http://www.paulrhayes.com/2011-11/use-css-transitions-to-link-media-queries-and-javascript/">wrote about this issue</a> a while back:</p>

<blockquote>
  <p>We need a way of testing media query rules in JavaScript, and a way of generating events when a new rule matches.</p>
</blockquote>

<p>He came up with the ingenious solution of using <code>transitionEnd</code> events that are fired by media queries. The resulting <a href="https://github.com/fofr/matchMedia.js"><code>matchMedia</code> polyfill</a> he made is very clever, but probably overkill for what I’m trying to do—I don’t really need to check for resize events for what I’m doing.</p>

<p>What I really need is some kind of otherwise-useless CSS declaration just so that I can test for it in JavaScript. Suppose there were a CSS <code>foo</code> declaration that I could use inside a media query:</p>

<pre><code>@media screen and (min-width: 45em) {
    body {
        foo: bar;
    }
}
</code></pre>

<p>…then in JavaScript I could test its value:</p>

<pre><code>var foovalue = window.getComputedStyle(document.body,null).getPropertyValue('foo');
if (foovalue == 'bar') {
    // do something
}
</code></pre>

<p>Of course that won’t work because <code>foo</code> wouldn’t be recognised by the browser so it wouldn’t be available to interrogate in JavaScript.</p>

<p>Any ideas? Maybe something like <code>zoom:1</code> ? If you can think of a suitable CSS property that could be used in this way, leave a comment.</p>

<p><small>Of course, now that I’m offering you a textarea to fill in with your comments, you’re probably just going to use it to tell me what’s wrong with the JavaScript I’ve written …those “comments&#8221; might mysteriously vanish.</small></p>

<hr />
<p>
Tagged with
<a rel="tag" href="http://adactio.com/journal/tags/dconstruct2012">dconstruct2012</a>
<a rel="tag" href="http://adactio.com/journal/tags/dconstruct">dconstruct</a>
<a rel="tag" href="http://adactio.com/journal/tags/responsive">responsive</a>
<a rel="tag" href="http://adactio.com/journal/tags/design">design</a>
<a rel="tag" href="http://adactio.com/journal/tags/development">development</a>
<a rel="tag" href="http://adactio.com/journal/tags/css">css</a>
<a rel="tag" href="http://adactio.com/journal/tags/javascript">javascript</a>
<a rel="tag" href="http://adactio.com/journal/tags/conditional">conditional</a>
<a rel="tag" href="http://adactio.com/journal/tags/loading">loading</a>
</p>
]]>
			</description>
			<pubDate>Tue, 24 Apr 2012 13:28:08 GMT</pubDate>
			<guid>http://adactio.com/journal/5414/</guid>
			<category>dconstruct2012</category>
			<category>dconstruct</category>
			<category>responsive</category>
			<category>design</category>
			<category>development</category>
			<category>css</category>
			<category>javascript</category>
			<category>conditional</category>
			<category>loading</category>
		</item>
		<item>
			<title>Announcing dConstruct 2012</title>
			<link>http://adactio.com/journal/5410/</link>
			<description>
<![CDATA[
<p>I was up in the big smoke last week for <a href="http://2012.uxlondon.com/">UX London</a>. It was excellent: a thoroughly superb line-up of smart speakers and lovely attendees. <span class="vcard"><a href="http://clearleft.com/is/katebulpitt/" class="url" rel="friend met co-worker"><abbr class="fn" title="Kate Bulpitt">Kate</abbr></a></span> did a great job of making sure everything ran smoothly.</p>

<p>But there&#8217;s no rest for the wicked. With UX London done, <a href="http://clearleft.com/does/teach/">Clearleft</a> is gearing up for the other two events we&#8217;ve got lined up: <span class="vevent"><a href="http://2012.ampersandconf.com/" class="summary url">Ampersand</a> in <abbr class="dtstart" title="2012-06-15">June</abbr></span>&#8212;there are still <a href="http://ampersand2012.eventbrite.com/">some tickets available</a>&#8212;and <span class="vevent"><a href="http://2012.dconstruct.org/" class="summary url">dConstruct</a> in <abbr class="dtstart" title="2012-09-07">September</abbr></span>.</p>

<p>We sneakily soft-launched <a href="http://2012.dconstruct.org/">the dConstruct website</a> while we were manning the front desk at UX London. It was put together by our current intern, <span class="vcard"><a href="http://www.bevanstephens.com/" rel="friend met co-worker" class="fn url">Bevan Stephens</a></span>, and as you can see, he&#8217;s done a superb job. I offered some guidance on the mobile-first approach which he implemented beautifully.</p>

<p>I&#8217;ll write some more later about some of the specifics of the site, but for now, I just want to say: <a href="http://2012.dconstruct.org/">check out that line-up</a>!</p>

<p>Usually <span class="vcard"><a href="http://andybudd.com/" class="url" rel="friend met co-worker"><abbr class="fn" title="Andy Budd">Andy</abbr></a></span> is responsible for putting together the roster of speakers but this year it was my turn. It was a lot of work and I have a renewed appreciation for the great job Andy has done every year in putting together a kick-ass conference. I&#8217;ve always felt that one of the strengths of dConstruct is the way the day is curated.</p>

<p>There&#8217;s a lot to live up to: <a href="http://archive.dconstruct.org/">seven years worth of fantastic talks</a>. But I couldn&#8217;t be happier about the line-up we&#8217;ve got for dConstruct 2012:</p>

<p>One of my favourite writers, <a href="http://2012.dconstruct.org/conference/beukes/">Lauren Beukes</a>; local genius <a href="http://2012.dconstruct.org/conference/lee-delisle/">Seb Lee-Delisle</a>; brilliant London lads <a href="http://2012.dconstruct.org/conference/armitage/">Tom Armitage</a> and <a href="http://2012.dconstruct.org/conference/hammersley/">Ben Hammersley</a>; my hero <a href="http://2012.dconstruct.org/conference/scott/">Jason Scott</a>; brain-the-size-of-a-planet <a href="http://2012.dconstruct.org/conference/jenson/">Scott Jenson</a>; my super-smart friends <a href="http://2012.dconstruct.org/conference/waldman/">Ariel Waldman</a> and <a href="http://2012.dconstruct.org/conference/lukas/">Jenn Lukas</a>; and, wait for it &#8230;<a href="http://2012.dconstruct.org/conference/burke/">James. Fucking. Burke</a>.</p>

<p>Your reaction to that last one will either be &#8220;who?&#8221; or &#8220;OMGWTFBBQ!&#8221; depending on your age and/or penchant for <a href="http://www.youtube.com/view_play_list?p=79184D14F872B80D">the greatest popular science television shows ever broadcast</a>.</p>

<p>I realise it&#8217;s a very self-indulgent line-up&#8212;I&#8217;ve basically put together my wish list of the smartest, funniest, most eloquent people I know, but it&#8217;s all in service of the theme for this year: <cite>Playing With The Future</cite>.</p>

<p>(Yeah, I came up with that one. Can you tell?)</p>

<p>Lest there be any misunderstanding about the kind of event dConstruct 2012 will be, I&#8217;ve written <a href="http://2012.dconstruct.org/conference/">a few words about what to expect</a>:</p>

<blockquote>
  <p>The presentations may not contain any practical tips you can take back to work on Monday morning but you will gain insights into the direction our digital technology is taking. You might just find yourself showing up at work on Monday morning with an altered perspective on the world.</p>
</blockquote>

<p>Tickets go on sale at the end of May. They&#8217;ll be a very affordable £130 plus <abbr title="Value Added Tax">VAT</abbr>.</p>

<p>Oh, and did I mention <a href="http://2012.dconstruct.org/workshops/">the workshops</a> that will precede the day of the conference? <a href="http://2012.dconstruct.org/workshops/marcotte/">Ethan Marcotte</a>, <a href="http://2012.dconstruct.org/workshops/sharp/">Remy Sharp</a>, <a href="http://2012.dconstruct.org/workshops/gardner/">Lyza Danger Gardner</a>, and <a href="http://2012.dconstruct.org/workshops/snook/">Jonathan Snook</a>: Kick. Ass!</p>

<p>I am so ridiculously excited. I cannot <em>wait</em> until September!</p>

<p>I hope to see you there.</p>

<hr />
<p>
Tagged with
<a rel="tag" href="http://adactio.com/journal/tags/dconstruct2012">dconstruct2012</a>
<a rel="tag" href="http://adactio.com/journal/tags/dconstruct">dconstruct</a>
<a rel="tag" href="http://adactio.com/journal/tags/conference">conference</a>
<a rel="tag" href="http://adactio.com/journal/tags/brighton">brighton</a>
<a rel="tag" href="http://adactio.com/journal/tags/event">event</a>
</p>
]]>
			</description>
			<pubDate>Mon, 23 Apr 2012 11:05:08 GMT</pubDate>
			<guid>http://adactio.com/journal/5410/</guid>
			<category>dconstruct2012</category>
			<category>dconstruct</category>
			<category>conference</category>
			<category>brighton</category>
			<category>event</category>
		</item>
		<item>
			<title>AudioGO</title>
			<link>http://adactio.com/journal/5405/</link>
			<description>
<![CDATA[
<p>You never forget your first DMCA takedown notice. In my case it was the <a href="http://adactio.com/journal/1623/">Perfect Pitch</a> incident, in which an incompetent business was sending out automatic takedown notices to Google for any website that contained a combination of the words <a href="http://adactio.com/journal/1624/">Burge Pitch Torrent</a>. That situation, which affected <a href="http://www.thesession.org/">The Session</a>, was resolved with an apology from the offending party.</p>

<p>Now I&#8217;ve received my second DMCA takedown notice. Or rather, <a href="http://segpub.net/">my hosting company</a> has. This time it involves <a href="http://huffduffer.com/">Huffduffer</a>.</p>

<p>When I created Huffduffer, I thought about offering hosting for audio files. One of the reasons I decided not to is because of the potential legal pitfalls. As it stands, Huffduffer is pretty much entirely text&#8212;it just links to audio files elsewhere on the web. That&#8217;s basically what an RSS enclosure is: another form of hypertext.</p>

<p><a href="http://www.chillingeffects.org/linking/">Linking</a> is simply the act of pointing to a resource, and <a href="http://www.chillingeffects.org/linking/faq.cgi#QID152">apart from a few extreme cases</a>, it isn&#8217;t illegal.</p>

<p>Now it could be argued that pointing to an audio file on another site through a Flash player (or HTML5 <code>audio</code> element) is more like <em>hot</em>linking with an <code>img</code> element than regular linking through an <code>a</code> element. The legal status of hotlinking isn&#8217;t quite as clear cut as plain ol&#8217; linking, as <a href="http://www.chillingeffects.org/linking/faq.cgi#QID230">explained on the Chilling Effects site</a>:</p>

<blockquote>
  <p>When people complain about inline images, they are most often complaining about web pages that include graphics from external sources. The legal status of inlining images without permission has not been settled.</p>
</blockquote>

<p>So the situation with inline audio is similarly murky.</p>

<p>Here&#8217;s the threatening email that was sent to the hosting company:</p>

<blockquote>
  <p>Notice of Copyright Infringement. {Our ref: [$#121809/228552]}</p>
  
  <p>Sender: Robert Nichol<br>
  AudioGO Ltd<br>
  The Home of BBC Audiobooks<br>
  St James House, The Square, Lower Bristol Road<br>
  Bath<br>
  BA2 3BH<br>
  Phone number not available</p>
  
  <p>Recipient: Rackspace Hosting</p>
  
  <p>RE: Copyright Infringement.</p>
  
  <p>This notice complies with the Digital Millennium Copyright Act (17 U.S.C. Ã‚Â§512(c)(3))</p>
  
  <p>I, Robert Nichol, swear under penalty of perjury that I am authorised to act on behalf of AudioGO Ltd, the owner(s) of the copyright or of an exclusive licence in the work(s) The Moving Finger by Agatha Christie BBC Audio.</p>
  
  <p>It has come to my attention that the website <a href="http://huffduffer.com/">huffduffer.com</a> is engaged in the electronic distribution of copies of these works. It is my good faith belief that the use of these works in this manner is not authorised by the copyright owner, his agent or the law. This is in clear violation of United States, European Union, and International copyright law, and I now request that you expeditiously remove this material from <a href="http://huffduffer.com/">huffduffer.com</a>, or block or disable access to it, as required under both US and EU law.</p>
  
  <p>The works are The Moving Finger by Agatha Christie BBC Audio.</p>
  
  <p>The following URLs identify the infringing files and the means to locate them. </p>
  
  <p><a href="http://huffduffer.com/TimesPastOTR/68635">http://huffduffer.com/TimesPastOTR/68635</a> (IP: 67.192.7.4)</p>
  
  <p>The information in this notice is accurate and I request that you expeditiously remove or block or disable access to all the infringing material or the entire site.</p>
  
  <p>/Robert Nichol/<br>
  Robert Nichol</p>
  
  <p>Wednesday April 18, 2012</p>
</blockquote>

<p>Initially, my hosting company rebutted Robert Nichol&#8217;s claim but he&#8217;s not letting it go. He insists that the offending URL be removed or he will get the servers taken offline. So now I&#8217;ve been asked by my host to delete the relevant page on Huffduffer.</p>

<p>But the question of whether audio hotlinking counts as copyright infringement is a moot point in this case&#8230;</p>

<p>Go to <a href="http://huffduffer.com/TimesPastOTR/68635">the page in question</a>. If you try to play the audio file, or click on the &#8220;download&#8221; link, you will find yourself at <a href="http://www.4shared.com/linkError.jsp?nowww=436">a 404 page</a>. Whatever infringing material may have once been located at the end of the link is long gone &#8230;and yet <a href="http://www.audiogo.co.uk/">AudioGO Ltd</a> are <em>still</em> insisting that the Huffduffer page be removed!</p>

<p>Just to be clear about this, Robert Nichol is using the Digital Millennium Copyright Act&#8212;and claiming &#8220;good faith belief&#8221; while doing so&#8212;to have a site removed from the web that <em>mentions</em> the name of a work by his client, and yet that site not only doesn&#8217;t host any infringing material, it doesn&#8217;t even link to any infringing material!</p>

<p>It seems that, once again, the DMCA is being used in a scattergun approach like a machine-gun in the hands of a child. There could be <a href="https://www.eff.org/cases/online-policy-group-v-diebold">serious repercussions</a> for Robert Nichol in abusing a piece of legislation in this way.</p>

<p>If I were to remove <a href="http://huffduffer.com/TimesPastOTR/68635">the page in question</a>, even though it just contains linkrot, it would set a dangerous precedent. It would mean that if someone else&#8212;like you, for instance&#8212;were to create a page that contains the text &#8220;Agatha Christie &#8212; The Moving Finger&#8221; while pointing to <a href="http://dc436.4shared.com/img/892695085/b3c907d3/dlink__2Fdownload_2FaKhc8m9b_3Ftsid_3D20120318-72646-b4a59ab0/preview.mp3">a dead link</a> &#8230;well, your hosting company might find themselves slapped with a takedown notice.</p>

<p>In that situation, you wouldn&#8217;t be able to copy and paste this markup into your blog, Tumblr, Facebook, or Google+ page:</p>

<pre><code>&lt;a href="http://dc436.4shared.com/img/892695085/b3c907d3/dlink__2Fdownload_2FaKhc8m9b_3Ftsid_3D20120318-72646-b4a59ab0/preview.mp3"&gt;Agatha Christie — The Moving Finger&lt;/a&gt;
</code></pre>

<p>Remember: that link does <strong>not</strong> point to any infringing material. It points to nothing but a 404 page. There&#8217;s absolutely no way that you could have your site taken offline for pointing to a file that doesn&#8217;t exist, right?</p>

<p>That would be crazy.</p>

<hr />
<p>
Tagged with
<a rel="tag" href="http://adactio.com/journal/tags/dmca">dmca</a>
<a rel="tag" href="http://adactio.com/journal/tags/copyright">copyright</a>
<a rel="tag" href="http://adactio.com/journal/tags/law">law</a>
<a rel="tag" href="http://adactio.com/journal/tags/audio">audio</a>
<a rel="tag" href="http://adactio.com/journal/tags/huffduffer">huffduffer</a>
<a rel="tag" href="http://adactio.com/journal/tags/audiogo">audiogo</a>
<a rel="tag" href="http://adactio.com/journal/tags/hosting">hosting</a>
</p>
]]>
			</description>
			<pubDate>Sat, 21 Apr 2012 16:05:35 GMT</pubDate>
			<guid>http://adactio.com/journal/5405/</guid>
			<category>dmca</category>
			<category>copyright</category>
			<category>law</category>
			<category>audio</category>
			<category>huffduffer</category>
			<category>audiogo</category>
			<category>hosting</category>
		</item>

   </channel>
</rss>
