<?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>Kyle Schaeffer - Web Design and SharePoint Branding &#187; Web Browsers</title>
	<atom:link href="http://kyleschaeffer.com/tag/web-browsers/feed/" rel="self" type="application/rss+xml" />
	<link>http://kyleschaeffer.com</link>
	<description>Web Design &#38; SharePoint Branding</description>
	<lastBuildDate>Wed, 01 Feb 2012 23:01:50 +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>10 Things a Website Should Never, Ever Do</title>
		<link>http://kyleschaeffer.com/best-practices/10-things-a-website-should-never-ever-do/</link>
		<comments>http://kyleschaeffer.com/best-practices/10-things-a-website-should-never-ever-do/#comments</comments>
		<pubDate>Thu, 22 Sep 2011 21:19:15 +0000</pubDate>
		<dc:creator>Kyle</dc:creator>
				<category><![CDATA[Best Practices]]></category>
		<category><![CDATA[CSS]]></category>
		<category><![CDATA[CSS3]]></category>
		<category><![CDATA[Images]]></category>
		<category><![CDATA[JavaScript]]></category>
		<category><![CDATA[jQuery]]></category>
		<category><![CDATA[SharePoint]]></category>
		<category><![CDATA[Web Browsers]]></category>

		<guid isPermaLink="false">http://kyleschaeffer.com/?p=994</guid>
		<description><![CDATA[As a designer of the world wide web, you are armed with the power to amaze, enlighten, entice, and captivate. The web is an easel for your creative aspirations, and the content you design for is the foundation of your &#8230; <a href="http://kyleschaeffer.com/best-practices/10-things-a-website-should-never-ever-do/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>As a designer of the world wide web, you are armed with the power to amaze, enlighten, entice, and captivate. The web is an easel for your creative aspirations, and the content you design for is the foundation of your creativity. With so much power at the tips of your fingers, you also possess the ability to deter, annoy, anger, and infuriate. Your users are yours to command, their emotions yours to pluck like the strings of a harp.<span id="more-994"></span></p>
<p>It&#8217;s the latter of these powers that we discuss today: your ability to destroy the desire for users to stay on your site. We&#8217;ll examine the causes of user strife on the web, and see clear examples of common mistakes that designers and developers all-too-often seem to make.</p>
<h2>1. Never interfere with the ability to scroll</h2>
<p>The browser window is a fairly simple application: an address/search bar, a few buttons, and a big window where users read, scroll, and click. Sure, most browsers have other bells and whistles, but it really boils down to these essential elements of the browsing experience. Rule number one: never, ever (ever, ever) interfere with these most basic features of the browser window.</p>
<h3>Example: Microsoft SharePoint 2010</h3>
<p><img class="alignright" title="Microsoft SharePoint 2010" src="http://kyleschaeffer.com/wordpress/wp-content/uploads/2011/09/sharepoint-2010.jpg" alt="Microsoft SharePoint 2010" width="300" height="175" />One of the most preposterous features of an interface that I&#8217;ve seen is SharePoint 2010&#8242;s new ribbon interface. The default SharePoint 2010 interface includes a simple CSS style that disables the scrollbar on the <code>&lt;body&gt;</code> element. Microsoft chooses to remedy this by adding a scrollbar to other division elements in the interface instead. This results in a fairly impressive &#8220;fixed&#8221; ribbon, but it has some infuriating side-effects.</p>
<ul>
<li>When a SharePoint 2010 page loads, users will not be able to scroll until all JavaScript has loaded.  On slow servers or on large pages, this can take up to 2-3 seconds, which can be quite infuriating.</li>
<li>Some devices don&#8217;t execute the JavaScript in the expected fashion, resulting in the complete inability to scroll on mobile devices and tablets.</li>
</ul>
<h3>An easy solution</h3>
<p>The truth is, creating a &#8220;fixed&#8221; element is a fairly simple CSS technique that has become extremely popular in the last few months. The complexity of Microsoft&#8217;s interface is it&#8217;s downfall. Always practice in simplicity, because fewer things can go wrong in the end. Build simple interfaces, and <em>never</em> disable the scroll bar. Do this, and you&#8217;ll know at least one person who doesn&#8217;t hate your guts.</p>
<h2>2. Never allow form resubmissions</h2>
<p>Forms are a fairly standard feature of the web. Users see them and use them all the time: to sign up, sign in, order, update, and the like. With so much familiarity, it&#8217;s a wonder that forms are one of the largest sources of frustration to users. Between data, validation, formatting, handling errors, and all the auxiliary things that seem to surround web forms, things can get pretty complex for designers and developers. All the while, you try to keep it simple for your users. It&#8217;s a tall order, to be sure, but there is at least one thing that you can do to help users stay calm.</p>
<h3>Example: The Form Resubmission Prompt</h3>
<p><img class="alignnone size-medium wp-image-1008" title="Form Resubmission" src="http://kyleschaeffer.com/wordpress/wp-content/uploads/2011/09/form-resubmission.jpg" alt="Form Resubmission" /></p>
<p>This is Google Chrome&#8217;s form resubmission prompt. Most browsers have something very similar. This appears when users click on the &#8220;Back&#8221; and &#8220;Forward&#8221; buttons in the browser, or when they &#8220;Refresh&#8221; a page on which they have submitted a form. As web junkies, we might know what this means, but it has a more elusive meaning to your every-day internet users. Most of the time, you&#8217;ll find that users simply click the default option (in this case, &#8220;Continue&#8221;), which can lead to duplication of orders, data, requests, and all sorts of things that would be better off if avoided. Also, it&#8217;s just another annoying prompt that users encounter while they&#8217;re using your site.</p>
<h3>A Simple Solution</h3>
<p>The solution to form resubmissions really depends on the platform your website runs on. In most cases, a simple fix is to separate the script that submits the form data, and the script that receives and processes that data. For example, if you&#8217;re using a PHP-based platform, you might have a form that looks like this:</p>
<pre>&lt;form action="submit.php"&gt;
  &lt;input type="text" name="user" required /&gt;
  &lt;input type="password" name="pass" required /&gt;
  &lt;input type="submit" value="Log in" /&gt;
&lt;/form&gt;</pre>
<p>To avoid the resubmission prompt, your <code>submit.php</code> script would <strong>forward</strong> to another page, rather than displaying a page in the browser.</p>
<pre>if(isset($_POST['user']) &amp;&amp; isset($_POST['pass'])){
  // do something with the form data
  <strong>header('Location:/login/form.php?success=true');</strong>
}</pre>
<p>This receiving script never actually displays anything in the browser window. Instead, it receives the form data, does something with it, and then forwards the user somewhere else. Using this technique, when users click on the &#8220;Back&#8221; or &#8220;Forward&#8221; button, the browser will skip the <code>submit.php</code> page completely, and never see the annoying form resubmission prompt.</p>
<h2>3. Never disable keyboard support</h2>
<p><img class="alignright size-full wp-image-1009" title="Sprint Sign-In" src="http://kyleschaeffer.com/wordpress/wp-content/uploads/2011/09/sprint-sign-in.jpg" alt="Sprint Sign-In" width="179" height="357" />While we&#8217;re on the topic of forms, let&#8217;s look at another deviation from web standards you&#8217;ll want to avoid. To the right, you&#8217;ll see a screenshot of the login form at <a href="http://mysprint.sprint.com">mysprint.sprint.com</a>. I have a Sprint mobile phone, and I occasionally use this login form to sign in and review my account, see my bill, or (more commonly) daydream about all the fancy new mobile phones that I don&#8217;t have.</p>
<h3>What went wrong</h3>
<p>The font sizes are a little small for my taste, but the appearance of this form is not the worst I&#8217;ve seen (yes, that was a compliment). Design and aesthetics aside, there&#8217;s one feature of this form that drives me absolutely crazy. It&#8217;s an extremely simple form, one that I&#8217;ve encountered on countless other websites before. As usual, I would expect to enter my username and password to sign in without a fuss.</p>
<p>Unfortunately, this is not the case. While focusing in either the username or password textbox, pressing the ENTER key does absolutely nothing. I&#8217;m not the type of user that wastes time after filling out a form by lifting my hand from the keyboard and finding the submit button with my mouse cursor. I&#8217;m all about speed: on most websites, it&#8217;s type, type, ENTER, and the form has been submitted. On Sprint&#8217;s website, however, they&#8217;ve removed this behavior, and thus they&#8217;ve earned a place on my list of don&#8217;t-do&#8217;s.</p>
<h2>4. Never fail to give feedback</h2>
<p><img class="alignright size-full wp-image-1016" title="Facebook - Add Favorite" src="http://kyleschaeffer.com/wordpress/wp-content/uploads/2011/09/facebook-add-favorites.jpg" alt="Facebook - Add Favorite" width="201" height="344" />Feedback is important, especially if you&#8217;re working with the awesomeness of AJAX. Traditionally, you knew what was going on in a web page, because any time you clicked on something, you had to wait while the next page loaded. There was a very apparent interaction period, and very obvious feedback from that interaction. With the introduction of new technology like AJAX, however, that feedback is not always so obvious. Today&#8217;s websites are much more interactive, and the result of those interactions (whether successful or not) needs to be communicated to the user.</p>
<h3>Example: Facebook</h3>
<p>There&#8217;s an easy way to test this: visit a web page, turn off your wireless adapter, and then click on things and see what happens. Obviously, because you&#8217;re not online, anything you do should be very obviously followed by a &#8220;no connection&#8221; message or some sort of indication that you&#8217;ve failed to do something. Facebook, a website that makes gratuitous use of AJAX for interaction, is not so good about warning users when things have failed.</p>
<p><strong>Editor&#8217;s note:</strong> yes, I am using pirate Facebook.</p>
<p>One particular example is the new &#8220;lists&#8221; feature that allows you to mark a list as &#8220;favorite.&#8221; Even when you&#8217;re offline, Facebook gives you no indication that the action has failed. Never assume that users will have a fast connection, or that AJAX requests will complete. You should always provide feedback if something fails, especially when no page loads are involved.</p>
<h2>5. Never disable keyboard navigation</h2>
<p>Different strokes for different folks. That&#8217;s a saying that I like to spew off at random times, usually in a failed attempt at humor, but the lesson of this silly quip is tried and true: everyone has their own way of doing things. This can also be applied to navigation on the internet. Some people prefer to use their cursor for absolutely everything, and only resort to keyboard use when absolutely necessary. Others use the keyboard almost entirely, tabbing, backspacing, and scrolling their way through the world of the world wide web. Others, still, use gestures and touch screens to flick and fly their way through the internet. As a crafter of the interactive, you must adhere to all of these people. Never detract from your users&#8217; ability to navigate in whatever way they damn well please.</p>
<h3>Example: No, I don&#8217;t want to search</h3>
<p><img class="alignright size-full wp-image-1027" title="eBay Auto-focus" src="http://kyleschaeffer.com/wordpress/wp-content/uploads/2011/09/ebay-search.jpg" alt="eBay Auto-focus" width="202" height="101" />I&#8217;m going to use eBay as an example, just because they&#8217;re so big, but many websites <em>out there</em> are guilty of this annoyance. Upon arriving at eBay&#8217;s website, they use JavaScript to auto-focus on the search bar. I guess they&#8217;ve already decided, before you even visit, that you want to search their website. For some users, however, this can be incredibly annoying. A common and simple way to scroll down the page, in all browsers, is to press the space key. Pressing this key will advance the screen about one page, so you can continue reading without having to worry about scroll bars and the like. If you&#8217;re auto-focused on a search box, however, it disables your ability to do this. Even if it&#8217;s only a minor annoyance, it can be incredibly frustrating to users who like to navigate in this fashion. Likewise, I often use the backspace key instead of the back button to go back when I didn&#8217;t find what I was looking for. With the focus on a search field, backspace navigation simply doesn&#8217;t work.</p>
<p>The fix for this one is easy: don&#8217;t do it. It&#8217;s annoying.</p>
<h2>6. Never move content without user interaction</h2>
<p>Websites can be so damn sneaky. I guess they need to make a buck, but who doesn&#8217;t? One thing that will drive your users bonkers is anything that moves without a prompt from the user. Yes, I&#8217;m talking about you, &#8220;auto-expanding-advertisement-that-plays-a-stupid-video-of-a-guy-who-walks-across-my-screen-when-I-just-want-to-read-the-damn-article&#8221; guy. I also dislike anything that happens on hover (including drop-down menus). Hover is so 2000&#8242;s, get with the times, people. The only time your website should &#8220;move&#8221; or &#8220;do something&#8221; is when users tell it to. Most simply, any time they click, drag, or scroll. That sounds simple and obvious, but not everyone adheres to this most basic of principles.</p>
<h3>Example: Digg.com</h3>
<p><img class="alignnone size-full wp-image-1028" title="Digg Advertisement" src="http://kyleschaeffer.com/wordpress/wp-content/uploads/2011/09/digg-advertisement.jpg" alt="Digg Advertisement" width="600" height="300" /></p>
<p>While the quality of Digg&#8217;s content is another concern, one thing that does drive me crazy is the sponsored links that appear in the rollup. Notice the promotion from NewEgg.com. This link does not actually appear on page load, but rather when users hover their mouse cursor into the rollup of popular stories. This means that if you&#8217;re a fast clicker (aren&#8217;t we all?), you will often accidentally click on the advertisement instead of the story you&#8217;re interested in. Good for Digg, bad for users. Stop being so shifty, internet.</p>
<h2>7. Never use fixed position without a fallback</h2>
<p>A &#8220;fixed&#8221; element in the browser window is one that stays on the screen, even as you scroll down the page. It&#8217;s a simple CSS technique, but it&#8217;s been amazingly popular in recent months. One thing I&#8217;ve noticed in all these fixed designs is the failure to provide a fallback for users who are on smaller screens. The truth of the matter is that the web isn&#8217;t just for desktops any more. Internet connectivity is coming in all sorts of shapes and sizes: desktops, laptops, mobiles, tablets, e-readers, gaming consoles, and even refrigerators (yes, even refrigerators). The future promises only more diversity in internet-connected devices, and that means you can&#8217;t assume users will have a large viewing area on which to see your website.</p>
<h3>Example: Pandora.com</h3>
<p><img class="alignright size-full wp-image-1035" title="Pandora Fixed" src="http://kyleschaeffer.com/wordpress/wp-content/uploads/2011/09/pandora-fixed-nav.jpg" alt="Pandora Fixed" width="403" height="269" />This is a screenshot of Pandora&#8217;s fancy new HTML5/CSS3 design. First of all, I&#8217;ll say that I love Pandora.  Maybe too much. It&#8217;s pretty awesome, and it even lets me give all of my radio stations quirky little names like &#8220;Harmonizatorasaurous&#8221; (eat that, spell-check).</p>
<p>Pandora&#8217;s new design includes a fixed header, like many new designs, but it seems the header does not provide a fallback for users on a smaller screen. When reducing the window width, it clips the player controls off the edge of the screen. If a fixed element is clipped, users can&#8217;t see it, even if they try to scroll to see more, which can be a huge problem.</p>
<h3>A simple solution</h3>
<p>An easy solution to this problem is to make the default behavior of your site&#8217;s header to maintain a static position, but when users have a large enough screen, you can make things fixed for a more impressive presentation.  The following jQuery snippet does the trick quite nicely:</p>
<pre>$(window).resize(function(){
  resizeUI();
}); 
$(document).ready(function(){
  resizeUI();
});

<strong>// resize on page load AND window resize</strong>
<strong>function resizeUI(){</strong>
<strong> if($(window).width() &gt; 500){</strong>
<strong> $('#header').css('position', 'fixed');</strong>
<strong> }</strong>
<strong> else{</strong>
<strong> $('#header').css('position', 'static');</strong>
<strong> }</strong>
<strong>} </strong></pre>
<p>This script runs both on page load AND as users resize the window, so no matter what happens, you can decide whether or not to use fixed elements. You&#8217;ll have to mess with the values that the script looks at (width and height) to determine what works best for your site&#8217;s design, but it&#8217;s a useful technique to use.</p>
<h2>8. Never use pop-up windows</h2>
<p>Do I really even have to mention this one? I thought that pop-ups were notorious for the infuriating behavior that have on users, but I still see them &#8220;pop up&#8221; from time to time (pun <em>intended</em>).</p>
<h3>Example: TinyMCE</h3>
<p><img class="alignright size-full wp-image-1036" title="TinyMCE" src="http://kyleschaeffer.com/wordpress/wp-content/uploads/2011/09/tinymce.jpg" alt="TinyMCE" width="185" height="98" />I never use pop-ups. I always recommend against them. A common excuse is that <em>your</em> site should stay open, in it&#8217;s own tab, even if users click a link that takes them away from your site. I&#8217;ve got a simple response to that: wrong! Don&#8217;t let your head grow so big that you think your website is god&#8217;s gift to the internet. Users have gotten pretty comfortable with the idea of tabbed browsing, and they know how to manage their windows. Unless you&#8217;re Google, you&#8217;re not allowed to use pop-ups. It&#8217;s that simple.</p>
<p>Imagine my surprise when I attempted to implement the TinyMCE JavaScript editor into a web application I was building, and realized it still used pop-up windows for things like links and images. I am building a PHP application, and I have had stars in my eyes for WordPress the entire time, so TinyMCE was the obvious choice. I was so taken aback by this behavior that I ended up switching to CKEditor, another popular editor that has recognized the need to rid the world of these annoying little boxes, and I&#8217;m all the happier for it.</p>
<h2>9. Never get quirky (well, not <em>too</em> quirky)</h2>
<p>I love websites that are different, but not <em>too</em> different. There&#8217;s a fine balance to be made between adhering to expectations, and getting so weird that users have no idea what&#8217;s going on. As with most users, if I visit a website and am prompted to &#8220;explore this insanely huge image of nonsense to learn how to navigate our site,&#8221; I&#8217;m going to leave and never return. I&#8217;ve never been a proponent of Flash, for this very reason, but I also recognize that it has it&#8217;s place. Flash can enhance a website&#8217;s content with some awesome features, but it should never be used to present content in its entirety.</p>
<h3>Example: Sony.com</h3>
<p><img class="alignright size-full wp-image-1038" title="Sony" src="http://kyleschaeffer.com/wordpress/wp-content/uploads/2011/09/sony.jpg" alt="Sony" width="305" height="133" />Check out <a href="http://www.sony.com">Sony.com</a>, and you&#8217;ll realize that a full 5-8 seconds will go by before you actually see anything on the screen that you can click on. Almost the entire site is in Flash, and it breaks about five of the ten &#8220;don&#8217;t do&#8217;s&#8221; that I&#8217;ve described in this article. All that aside, Sony has provided a non-Flash version of their site, which also subsequently presents a loading spinner for about 2-3 seconds that covers all of the content on the page. I&#8217;m not entirely sure why the designer who created the Sony website was so fond of things that come between users and consuming the content they came to read, but I do know this: it&#8217;s annoying. Don&#8217;t do it.</p>
<h2>10. Never do THIS&#8230;</h2>
<p>Okay, this last one is really just for fun, but never do THIS&#8230;</p>
<pre>body * {
  -webkit-transition: all 0.5s ease;
  -moz-transition: all 0.5s ease;
  -o-transition: all 0.5s ease;
  transition: all 0.5s ease;
}
body *:hover {
  -webkit-transform: rotate(180deg);
  -moz-transform: rotate(180deg);
  -o-transform: rotate(180deg);
  transform: rotate(180deg);
}</pre>
<p>Try it out by clicking on this button (you&#8217;ve been warned):</p>
<input id="crazy-button" type="button" value="Let's get crazy" />
<script src="/wordpress/wp-content/themes/shakefive/js/crazy.js"></script></p>
]]></content:encoded>
			<wfw:commentRss>http://kyleschaeffer.com/best-practices/10-things-a-website-should-never-ever-do/feed/</wfw:commentRss>
		<slash:comments>23</slash:comments>
		</item>
		<item>
		<title>From &#8220;Developer&#8221; to &#8220;Designer&#8221;</title>
		<link>http://kyleschaeffer.com/best-practices/from-developer-to-designer/</link>
		<comments>http://kyleschaeffer.com/best-practices/from-developer-to-designer/#comments</comments>
		<pubDate>Thu, 25 Aug 2011 16:34:16 +0000</pubDate>
		<dc:creator>Kyle</dc:creator>
				<category><![CDATA[Best Practices]]></category>
		<category><![CDATA[Design]]></category>
		<category><![CDATA[Web Browsers]]></category>

		<guid isPermaLink="false">http://kyleschaeffer.com/?p=964</guid>
		<description><![CDATA[It&#8217;s easy to forget how a website really works. I mean really works. I&#8217;ve had the pleasure of working with many brilliant and talented developers (programmers) who could bend the functionality of any application or server-side platform at the drop &#8230; <a href="http://kyleschaeffer.com/best-practices/from-developer-to-designer/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>It&#8217;s easy to forget how a website really works. I mean <em>really works</em>. I&#8217;ve had the pleasure of working with many brilliant and talented developers (programmers) who could bend the functionality of any application or server-side platform at the drop of a hat. They are problem-solvers, as is everyone in this industry of the online.<span id="more-964"></span></p>
<p>With most developers, I&#8217;ve found that there can be a disconnect between how I understand websites, and how they&#8217;ve come to understand them. Not just <em>a </em>disconnect: <em>The Disconnect</em>. If you work in a team environment, you know the feeling. I say &#8220;element,&#8221; and you say &#8220;control.&#8221; I say &#8220;script,&#8221; and you say &#8220;method.&#8221; Most developers are ultimately, completely, and entirely focused on the server-side application.</p>
<p>That&#8217;s okay. I need my developers, and they need me. It&#8217;s a good relationship for all of us, with our complimentary skills, tools, and techniques. They make it work, and I make it look good.</p>
<h2>How to Connect</h2>
<p>Overcoming the <em>Disconnect</em> is all about education, on both sides of the fence. Developers and designers alike would benefit from understanding how the technology that they use comes together. The grand finale of everything that we do online ends up in a single place, where it can be seen, read, clicked, and tested: the browser window.</p>
<p>As a designer, that&#8217;s where my beautiful designs will end up, and they somehow need to be translated from Photoshop into HTML and CSS that works well with the server-side application. Good designers understand the technology before they create the designs. Likewise, as developers, the controls and methods that you create are all somehow translated into HTML, whether you&#8217;ve recognized that or not. Understanding the output of what you do in the application is just as important as making the application work.</p>
<h2>Don&#8217;t Forget the Browser</h2>
<p>This is where it all ends up. Everything that we do as designers, developers, project managers, or architects: it all comes together in the browser window. The browser is the tool that is used to present all of your hard work, everything that you&#8217;ve done throughout an entire project. With so much responsibility resting upon the shoulders of the browser, why is it that so many people ignore it completely?</p>
<p>Back in <em>The Day</em>, the browser is all there was. In 1989, Tim Berners-Lee created the world&#8217;s first web server. When requested, it <em>served</em> up documents to be viewed inside the very first web browser. These documents were pure HTML, and the browser interpreted that language in order to create Hyper-Text documents that could be <em>linked</em> together. As you probably know, this simple concept caught on, and by the mid 1990&#8242;s, the Internet had become arguably the most influential product of Man in the 20th century.</p>
<p>Everyone that works in the industry of the world wide web should pay their respects to the oft-neglected browser. It has so much power, and it is the tool that allows us to do what we do. The browser is everything. The W3C and WHATWG can make all the recommendations they want: nothing really happens until browsers support it. In the mid 2000&#8242;s, the W3C started working on a recommendation called XHTML 2.0. It failed. The browser manufacturers didn&#8217;t like it, and that&#8217;s why we&#8217;re now working with HTML5 instead of XHTML2. Similarly, Microsoft created something called the XMLHTTPRequest in the early- to mid-2000&#8242;s, and everyone loved it. The major browsers quickly adopted this technology, and AJAX was born.</p>
<p>The point is, the browser truly has the power in web application development. It doesn&#8217;t matter if you&#8217;re a programmer or a designer: you need to understand how technology works inside the confines of this little window. In all the amazing technology that surrounds the Internet, it&#8217;s really based on a few simple languages: HTML, CSS, and JavaScript.</p>
<h2>Making Requests</h2>
<p>Web browsers are fairly simple applications. In essence, they do two things: make requests, and handle responses. A request might be something like &#8220;show me the document at KyleSchaeffer.com,&#8221; or &#8220;give me the image at /images/kittens.jpg.&#8221; The server that you&#8217;re requesting from then responds and the browser does something with the response. It all sounds very simple, but it&#8217;s so easy to forget this fundamental layer of web technology. I&#8217;ve helped troubleshoot dozens of web applications, and my first question is always &#8220;What request is the browser making?&#8221;</p>
<p>This entire process is called an <strong>HTTP request</strong>. HTTP requests are sent by your browser every time you type something into the address bar. The first requests is almost always an HTML document, and then the browser subsequently makes additional requests for things like CSS files, JavaScript, and images. Even if your web application is running on PHP or ASP.NET or SharePoint, the server is returning an HTML document, which subsequently loads additional resources. Simple, right?</p>
<h3>1. The Request</h3>
<p>Every HTTP request has a <strong>URI</strong>, or Uniform Resource Identifier. That&#8217;s a fancy way of saying the <em>address</em> of the resource you&#8217;re requesting. The address can be both absolute (<code>http://kyleschaeffer.com/images/kittens.jpg</code>) or relative (<code>/images/kittens.jpg</code>). The browser sends this request to the &#8220;Internet,&#8221; which routes the request to the appropriate server, somewhere <em>out there</em>. The browser then waits for a response.</p>
<h3>2. The Response</h3>
<p>After sending a request, the server that you requested the document from will send back a <em>response</em>. Again, the browser handles the responses, and each resource that is requested is handled differently. First of all, the browser reads the HTTP <strong>response code</strong>, which is an indication of the status of your request. The most common HTTP response codes are:</p>
<ol>
<li><strong>200 OK</strong> - The most common response; the resource you requested was found</li>
<li><strong>301 Moved Permanently</strong> - The resources has moved, and the browser will redirect the request to the new location</li>
<li><strong>304 Not Modified</strong> - The resource was found, and your browser already has the most recent version in the browser cache (yay!)</li>
<li><strong>401 Unauthorized</strong> - You need to sign in to see this resource</li>
<li><strong>403 Forbidden</strong> - You&#8217;re not allowed to see this</li>
<li><strong>404 Not Found</strong> - The resource you requested does not exist</li>
<li><strong>408 Request Time-Out</strong> - That took too long, sorry</li>
<li><strong>500 Internal Server Error</strong> - Something went wrong!</li>
</ol>
<p>My descriptions of each response are less than technical, but you get the idea. If you&#8217;ve ever wondered what the &#8220;404&#8243; in &#8220;404 Not Found&#8221; meant, it&#8217;s the HTTP response code for &#8220;not found.&#8221; For a more comprehensive list of HTTP response codes, visit the <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec6.html">W3C&#8217;s documentation</a>.</p>
<p>Another important element of the HTTP response is the <strong>Content Type</strong>. This tells your browser how to handle the requested resource when it&#8217;s downloaded. Unlike on your computer, your browser does not decide how to use a resource based on it&#8217;s file extension! It&#8217;s all about the content type. Some of the more clever server-side programmers can actually utilize this element of the HTTP response to create server-side scripts that actually disguise themselves as other types of content (like a PHP script pretending to be JSON or XML).</p>
<h3>3. Execution</h3>
<p>At this point, the browser now knows the HTTP response code, and the resource content type. Using this information, it&#8217;s time to make something happen. The browser downloads the resource, and presents it inside the browser window. Browsers can sometimes handle resource requests differently, so this is where you get into the nuances of browser testing. One browser might handle HTML and CSS requests slightly different from another, so testing your applications is merely a practice of testing how these HTTP responses are handled.</p>
<h2>From &#8220;Developer&#8221; to &#8220;Designer&#8221;</h2>
<p>Bridging the divide between developers and designers is all about understanding how the different technologies of the web come together. The browser window is the one place where the user experience, the architecture, the design, the program, the database, and everything else that goes on behind the scenes comes to fruition and is finally presented. Clients pay for you to meet needs and requirements, but what they ultimately expect is something that appears inside the little box that they call the Internet. Embrace it, learn it, love it, know it inside and out, and you&#8217;ll find that disconnecting from <em>The Disconnect</em> is not so difficult after all.</p>
]]></content:encoded>
			<wfw:commentRss>http://kyleschaeffer.com/best-practices/from-developer-to-designer/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>Responsive Design Testing with Screenfly</title>
		<link>http://kyleschaeffer.com/news/responsive-design-testing-with-screenfly/</link>
		<comments>http://kyleschaeffer.com/news/responsive-design-testing-with-screenfly/#comments</comments>
		<pubDate>Tue, 07 Jun 2011 17:04:28 +0000</pubDate>
		<dc:creator>Kyle</dc:creator>
				<category><![CDATA[News]]></category>
		<category><![CDATA[jQuery]]></category>
		<category><![CDATA[Layout]]></category>
		<category><![CDATA[Mobile]]></category>
		<category><![CDATA[Responsive Design]]></category>
		<category><![CDATA[Web Browsers]]></category>

		<guid isPermaLink="false">http://kyleschaeffer.com/?p=933</guid>
		<description><![CDATA[Responsive design is all the rage. Ethan Marcotte, just today, released a new book on the subject, of which I&#8217;m quite excited. My last post was all about responsive web design, and after writing the article, I couldn&#8217;t help but &#8230; <a href="http://kyleschaeffer.com/news/responsive-design-testing-with-screenfly/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Responsive design is all the rage. <a href="http://unstoppablerobotninja.com/">Ethan Marcotte</a>, just today, released <a href="http://www.abookapart.com/products/responsive-web-design">a new book</a> on the subject, of which I&#8217;m quite excited. My <a title="Responsive Layouts Using CSS Media Queries" href="http://kyleschaeffer.com/best-practices/responsive-layouts-using-css-media-queries/">last post</a> was all about responsive web design, and after writing the article, I couldn&#8217;t help but ask myself: what now? Designing and implementing experiences for an unknown number of devices can be an intimidating task, especially when you don&#8217;t have the opportunity to test your designs on many (or any) of them. The answer, for me, was to create a new web app that aids in this testing process. It&#8217;s called <strong>Screenfly</strong>, and it&#8217;s the first of many apps that will be available on QuirkTools.com.<span id="more-933"></span></p>
<p><a href="http://quirktools.com/screenfly/"><img class="alignnone size-full wp-image-934" title="Screenfly" src="http://kyleschaeffer.com/wordpress/wp-content/uploads/2011/06/screenfly-screenshot.jpg" alt="" width="539" height="152" /></a></p>
<p>As you can see, it&#8217;s an incredibly simple application. Simply type in a web address and you&#8217;re off and running. The entire thing, from concept to complete, took less than eight hours of work to complete – don&#8217;t expect all the wiz-bang bells and whistles for that type of investment, but I do have to say that I&#8217;m quite proud of what this little thing can do.</p>
<h2>How it Works</h2>
<p>When you type in a web address and hit &#8220;Go,&#8221; Screenfly builds an <code>&lt;iframe&gt;</code> and displays it on the screen. The frame contains the web document you specified, and once it has loaded, testing can ensue. While viewing your web document, you will see buttons near the top left corner of the browser window, allowing you to select different devices from which to view your web document.  Most of the application is just a few lines of jQuery that affect the frame as it appears in the middle of the page.</p>
<h2>Why it&#8217;s Useful</h2>
<p>What&#8217;s really cool about the application is that I use a proxy to request your web document. Basically, I send a request from my server, which allows me to &#8220;pretend&#8221; like I&#8217;m an iPhone, an iPad, or an Android tablet when I make the request. What comes back is the actual content that would display <em>if</em> you were really browsing on that device. This works great on most websites, but you&#8217;ll find that some don&#8217;t play well with the proxy (things like JavaScript, Flash, Silverlight, and server configuration can break the proxy), so I also give you the option of disabling the proxy altogether. Unfortunately, this also disables the ability to &#8220;mimic&#8221; the devices you&#8217;ve selected, but it still gives you the opportunity to see your web layouts in different screen sizes.</p>
<h2>What it&#8217;s Not</h2>
<p>Keep in mind that Screenfly does <em>not</em> emulate the behavior or capabilities of the device it&#8217;s trying to mimic. That means that if you are running Screenfly on Internet Explorer 6, you&#8217;re only going to see the web document as if it were requested from the selected device, running on Internet Explorer 6.</p>
<p>Also, it&#8217;s important to note that I make no attempt to maintain a comprehensive list of devices for testing. The list of devices is intended to be representational of the actual devices available on today&#8217;s device market. For instance, I made sure to include both Android and Apple tablets, as well as Android and Apple mobile devices. The list will continue to evolve as the device landscape changes (as it always does), and any suggestions or additions are welcome.</p>
<h2>Try it Out</h2>
<p>Without further adieu, try Screenfly for yourself by clicking on the following link. This is a &#8220;beta&#8221; version of the web app, so please let me know if you encounter any errors or issues while testing your own designs.</p>
<p><a href="http://quirktools.com/screenfly/">http://quirktools.com/screenfly/</a></p>
]]></content:encoded>
			<wfw:commentRss>http://kyleschaeffer.com/news/responsive-design-testing-with-screenfly/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>9 Amazing Things You Can Do in Firefox 3.6</title>
		<link>http://kyleschaeffer.com/best-practices/9-amazing-things-firefox-3-6/</link>
		<comments>http://kyleschaeffer.com/best-practices/9-amazing-things-firefox-3-6/#comments</comments>
		<pubDate>Fri, 12 Mar 2010 16:43:32 +0000</pubDate>
		<dc:creator>Kyle</dc:creator>
				<category><![CDATA[Best Practices]]></category>
		<category><![CDATA[CSS]]></category>
		<category><![CDATA[Web Browsers]]></category>

		<guid isPermaLink="false">http://www.kyleschaeffer.com/?p=480</guid>
		<description><![CDATA[The latest update to Mozilla&#8217;s wonderful web browser, Firefox 3.6, includes support for some fantastic CSS version 3 recommendations that you may or may not be aware of. Obviously, these tricks won&#8217;t work in Internet Explorer just yet, but look &#8230; <a href="http://kyleschaeffer.com/best-practices/9-amazing-things-firefox-3-6/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>The latest update to Mozilla&#8217;s wonderful web browser, Firefox 3.6, includes support for some fantastic <a href="http://www.w3.org/Style/CSS/current-work#CSS3">CSS version 3 recommendations</a> that you may or may not be aware of. Obviously, these tricks won&#8217;t work in Internet Explorer just yet, but look for widespread support coming in the (hopefully) very near future.<span id="more-480"></span></p>
<p>Most of the new features revolve around background image and color management. This has been a definite pain point for designers in the past, as we&#8217;ve had to create extraneous <code>&lt;div/&gt;</code> tags and other silly markup hacks to implement our favorite visual elements. Fear not, for all browsers will soon support these great features! If you&#8217;ve already installed Firefox 3.6, you should plainly see all the great features in my examples below. If you haven&#8217;t installed the latest update, head on over to <a href="http://www.mozilla.com/firefox/">Mozilla&#8217;s website</a> now to download the latest version.</p>
<style type="text/css">
.box {
	margin: 0 0 20px 0;
	padding: 20px;
	border: 1px #ddd solid;
	-webkit-border-radius: 15px;
	-moz-border-radius: 15px;
	-o-border-radius: 15px;
	border-radius: 15px;
	text-align: justify;
}
.shiny-box {
	background: -moz-linear-gradient(top, #fff, #e9e9e9);
}
.slide {
	background: -moz-linear-gradient(top -45deg, violet, blue);
	color: #fff;
}
.rainbow {
	background: -moz-linear-gradient(left 20deg, violet, red, orange, yellow, green, teal, blue, purple);
	color: white;
}
.alpha {
	background: -moz-linear-gradient(left, rgba(255,255,255,1), rgba(255,255,255,0)), #4aceff url(http://thepeev.com/wp-content/themes/thepeev/images/plant.png) bottom no-repeat;
}
.radial {
	background: -moz-radial-gradient(top left, white 20%, orange);
}
.slasher {
	background: -moz-repeating-linear-gradient(left -45deg, #fff, #f5f5f5 1px, #fff 5px, #fff 1px);
}
.burst {
	background: -moz-repeating-radial-gradient(-5px -5px, circle, #bfeeff, #bfeeff 15px, #fff 15px, #fff 30px, #bfeeff 30px, #bfeeff 40px);
	border: 5px #bfeeff solid;
}
.layers {
	background: url(http://demos.hacks.mozilla.org/openweb/resources/images/logos/firefox-48.png), -moz-linear-gradient(left, rgba(255, 255, 255, 0),  rgba(255, 255, 255, 0.8)), url(http://demos.hacks.mozilla.org/openweb/resources/images/patterns/flowers-pattern.jpg);
	background-repeat: no-repeat, no-repeat, repeat;
	background-position: bottom right, left, right;
	color: #fff;
}
.layers strong {
	color: #fff;
}
.sizer {
	background: #f5f5f5 url(http://demos.hacks.mozilla.org/openweb/resources/images/logos/firefox-48.png) bottom right no-repeat;
	-moz-background-size: 120px;
	-webkit-background-size: 120px;
	-o-background-size: 120px;
}
</style>
<h2>The Linear Gradient</h2>
<p>You can now add linear gradients to your HTML elements with a handy CSS attribute called <code>-moz-linear-gradient</code>. Here are a few examples to get you started.</p>
<h3>A simple example:</h3>
<p class="box shiny-box"><strong>Are you using <a href="http://www.mozilla.com/firefox/">Firefox 3.6</a>? Check out my linear gradient background.</strong> Lorem ipsum dolor sit amet, consectetur adipiscing elit. Proin tempor odio ac elit faucibus vel rhoncus purus hendrerit. Pellentesque imperdiet fermentum lacinia.</p>
<h3>The CSS:</h3>
<pre>.shiny-box {
	background: -moz-linear-gradient(top, #fff, #e9e9e9);
}</pre>
<h3>Drawing gradients at an angle:</h3>
<p class="box slide"><strong>Gradient backgrounds can be drawn at an angle.</strong> Quisque mollis, dui quis hendrerit accumsan, dui lorem congue nibh, et scelerisque neque tortor ac magna. Quisque faucibus lectus tellus. Cras sodales, nulla in suscipit ultricies, mi neque pulvinar augue, a congue lacus tellus eu lorem. Donec varius posuere ligula, adipiscing adipiscing nibh eleifend eu. Nulla sagittis porttitor placerat. Praesent non pretium nisl. Curabitur tempor ante sed orci commodo placerat. Curabitur faucibus ornare augue. Duis adipiscing libero sed ante venenatis posuere. Etiam sodales felis ac est ultricies volutpat. Pellentesque varius iaculis dui, in interdum turpis porta ac. Ut rutrum consequat lectus sit amet euismod. Proin suscipit metus vitae magna condimentum eget blandit ante blandit. Duis lorem magna, luctus sed rutrum non, dictum a erat. In egestas libero a nisl faucibus lobortis. Duis aliquam erat vitae ipsum placerat quis dignissim elit pretium. Sed dictum interdum feugiat. Praesent feugiat libero a enim vulputate ut viverra tortor ornare. Donec vel diam mi. Morbi porttitor porttitor mattis.</p>
<h3>The CSS:</h3>
<pre>.slide {
	background: -moz-linear-gradient(top -45deg, violet, blue);
	color: #fff;
}</pre>
<h3>Stringing colors together:</h3>
<p class="box rainbow"><strong>Specify multiple colors in your gradients.</strong> In fermentum ipsum eget quam pharetra sagittis. Phasellus mollis, nulla nec sagittis pharetra, magna tortor commodo felis, eget dictum sem ipsum gravida ligula. Aliquam pharetra libero quis ligula sollicitudin condimentum. Sed sed diam nulla. Fusce malesuada gravida felis, id porttitor lacus porttitor sed. Maecenas mollis feugiat ultrices. In ac viverra ligula. Maecenas suscipit tempor nibh ac mattis. Morbi ac metus velit. Morbi enim purus, adipiscing at consectetur eget, blandit id nibh.</p>
<h3>The CSS:</h3>
<pre>.rainbow {
	background: -moz-linear-gradient(left 20deg, violet, red, orange, yellow, green, teal, blue, purple);
	color: white;
}</pre>
<h2>Alpha Gradients</h2>
<p>Alpha gradients allow you to specify an RGBA transparency for background images and colors. This allows you to &#8220;fade&#8221; your background on a gradient, so it gets slightly more opaque as you near the edge of your element. It works a lot like the linear gradients shown above.</p>
<h3>Let&#8217;s try it out:</h3>
<p class="box alpha"><strong>Apply alpha gradients to background colors and images.</strong> Mauris id mauris diam, vel hendrerit tortor. Pellentesque leo erat, ullamcorper et consectetur eget, elementum id ipsum. Vestibulum et diam mi, quis commodo velit. Maecenas bibendum purus id sapien sodales ut dapibus est consectetur. Donec vel elementum quam. Suspendisse quis risus nulla. Cras imperdiet, est sit amet rhoncus tincidunt, elit turpis consectetur enim, sit amet gravida erat magna id urna. Cras feugiat, orci nec hendrerit pulvinar, tortor mi dapibus neque, in varius massa velit vitae mi. Fusce dignissim malesuada felis in tincidunt. Donec lacus magna, blandit quis ullamcorper consectetur, interdum in nisl. Curabitur luctus lorem in leo aliquam vestibulum. Ut tempus ornare augue non aliquet. Sed id elit eget sem condimentum tempus et non libero. Proin at nisi quis dolor dignissim varius. Nam fermentum mauris eget justo laoreet vitae tristique quam varius. Praesent sodales sem sed dolor aliquet sagittis. Vestibulum fringilla ultricies nunc. In lacus nisl, mollis blandit aliquam ut, tristique in libero. Suspendisse lacinia aliquet aliquet.</p>
<pre>.alpha {
	background: -moz-linear-gradient(left, rgba(255,255,255,1),
	rgba(255,255,255,0)),
	#4aceff url(http://thepeev.com/wp-content/themes/thepeev/images/plant.png) bottom no-repeat;
}</pre>
<h2>Radial Gradients</h2>
<p>Radial gradients allow for some really cool effects like gradient &#8220;shine&#8221; and other neat things you&#8217;d otherwise have to create in Photoshop.</p>
<h3>The example:</h3>
<p class="box radial"><strong>You can even draw radial gradients. See how I shine!</strong> Donec malesuada, augue in pulvinar tincidunt, tellus lectus iaculis mi, vel facilisis ante mauris et sem. Nunc pretium orci in lacus sollicitudin rhoncus. Lorem ipsum dolor sit amet, consectetur adipiscing elit. Cras sollicitudin risus eu libero vestibulum vel mattis diam sagittis. Duis vel dui non erat eleifend dignissim vitae vitae dui. Curabitur dictum imperdiet diam euismod viverra.</p>
<h3>The CSS:</h3>
<pre>.radial {
	background: -moz-radial-gradient(top left, white 20%, orange);
}</pre>
<h2>Repeating Gradients</h2>
<p>As if this wasn&#8217;t enough, you&#8217;ll also have support for repeating gradients, which allows you to do some really cool stuff.</p>
<h3>Check it out:</h3>
<p class="box slasher"><strong>Repeating gradients make it easy to add slash-boxes.</strong> Vestibulum at fringilla dolor. Pellentesque id consectetur enim. Suspendisse vel nibh magna, et imperdiet mi. Aliquam erat volutpat. Maecenas dui quam, volutpat vitae cursus et, suscipit sit amet lorem. Duis congue, nisi eu aliquet ultricies, ipsum ligula rutrum libero, quis rhoncus nisi mauris lacinia nunc. Nam iaculis, nibh et faucibus tempor, massa magna eleifend urna, sit amet pulvinar arcu velit et lacus.</p>
<h3>The CSS:</h3>
<pre>.slasher {
	background: -moz-repeating-linear-gradient(left -45deg, #fff, #f5f5f5 1px, #fff 5px, #fff 1px);
}</pre>
<h3>Use it with radial gradients:</h3>
<p class="box burst"><strong>Repeating radial gradients make it easy to add special effects to your design.</strong> Aliquam tempor tempor nunc, ut dapibus nisl vehicula et. Nullam felis metus, consectetur eu pretium eu, iaculis eu tortor. Pellentesque habitant morbi tristique senectus et netus et malesuada fames ac turpis egestas. Ut quis ligula orci, id molestie orci.</p>
<h3>The CSS:</h3>
<pre>.burst {
	background: -moz-repeating-radial-gradient(-5px -5px, circle, #bfeeff, #bfeeff 15px, #fff 15px, #fff 30px, #bfeeff 30px, #bfeeff 40px);
	border: 5px #bfeeff solid;
}</pre>
<h2>Background Images</h2>
<p>This is one that I&#8217;m really excited about. You can apply multiple background images to a single layer. Here&#8217;s how it works:</p>
<h3>Multiple background layers:</h3>
<p class="box layers"><strong>You can layer multiple background images on a single element. This example was taken direclty from Mozilla&#8217;s demonstration page.</strong> Class aptent taciti sociosqu ad litora torquent per conubia nostra, per inceptos himenaeos. Quisque imperdiet elit dignissim libero sollicitudin tempus. Pellentesque habitant morbi tristique senectus et netus et malesuada fames ac turpis egestas. Duis mattis, leo at rhoncus varius, leo eros tempus ligula, eget blandit mi tortor vitae ante. Nulla varius aliquet massa ac varius. Vestibulum a ipsum vitae ante lobortis facilisis vitae eu risus.</p>
<h3>The CSS:</h3>
<pre>.layers {
	background: url(http://demos.hacks.mozilla.org/openweb/resources/images/logos/firefox-48.png),
	-moz-linear-gradient(left, rgba(255, 255, 255, 0),  rgba(255, 255, 255, 0.8)),
	url(http://demos.hacks.mozilla.org/openweb/resources/images/patterns/flowers-pattern.jpg);
	background-repeat: no-repeat, no-repeat, repeat;
	background-position: bottom right, left, right;
	color: #fff;
}</pre>
<h3>You can also resize background images!</h3>
<p class="box sizer"><strong>You can scale a background image to any size. It&#8217;s so ugly!</strong> Morbi sapien urna, convallis quis accumsan mattis, congue non ante. Phasellus bibendum nibh id orci consequat hendrerit rhoncus in leo. Ut a mauris eu nisl accumsan pulvinar sit amet at leo. Aenean sit amet enim sit amet tellus pellentesque tempus. Vivamus lobortis dui sed arcu venenatis vel vehicula felis vestibulum. Fusce vel ipsum eu nulla fermentum gravida. Suspendisse tincidunt euismod consectetur.</p>
<h3>The CSS:</h3>
<pre>.sizer {
	background: #f5f5f5 url(http://demos.hacks.mozilla.org/openweb/resources/images/logos/firefox-48.png) bottom right no-repeat;
	-moz-background-size: 120px;
	-webkit-background-size: 120px;
	-o-background-size: 120px;
}</pre>
<h2>Other Additions</h2>
<p>Mozilla has included some other great new features, such as the highly anticipated CSS attribute <code>@font-face</code>, which allows you to embed WOFF downloadable fonts into your web design. Type is finally coming to the web! For details on this and the many other great new features in Firefox 3.6, visit Mozilla&#8217;s <a href="https://developer.mozilla.org/En/Firefox_3.6_for_developers">update details for developers</a> page.</p>
]]></content:encoded>
			<wfw:commentRss>http://kyleschaeffer.com/best-practices/9-amazing-things-firefox-3-6/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

