<?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>Learning the World &#187; best practices</title>
	<atom:link href="http://learningtheworld.eu/tag/best-practices/feed/" rel="self" type="application/rss+xml" />
	<link>http://learningtheworld.eu</link>
	<description></description>
	<lastBuildDate>Tue, 06 Nov 2012 00:17:33 +0000</lastBuildDate>
	<language>en-US</language>
		<sy:updatePeriod>hourly</sy:updatePeriod>
		<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.9.1</generator>
	<item>
		<title>Accessible Drop-Down Menus</title>
		<link>http://learningtheworld.eu/2008/accessible-drop-down-menus/</link>
		<comments>http://learningtheworld.eu/2008/accessible-drop-down-menus/#comments</comments>
		<pubDate>Mon, 11 Aug 2008 08:00:09 +0000</pubDate>
		<dc:creator><![CDATA[Martin Kliehm]]></dc:creator>
				<category><![CDATA[accessibility]]></category>
		<category><![CDATA[usability]]></category>
		<category><![CDATA[web development]]></category>
		<category><![CDATA[ageing]]></category>
		<category><![CDATA[Ajax]]></category>
		<category><![CDATA[aria]]></category>
		<category><![CDATA[arrow keys]]></category>
		<category><![CDATA[assistive technologies]]></category>
		<category><![CDATA[AT]]></category>
		<category><![CDATA[best practices]]></category>
		<category><![CDATA[blur]]></category>
		<category><![CDATA[buffer]]></category>
		<category><![CDATA[CSS]]></category>
		<category><![CDATA[DHTML]]></category>
		<category><![CDATA[drop-down]]></category>
		<category><![CDATA[event]]></category>
		<category><![CDATA[event delegation]]></category>
		<category><![CDATA[fly-out]]></category>
		<category><![CDATA[focus]]></category>
		<category><![CDATA[Hick's Law]]></category>
		<category><![CDATA[i18n]]></category>
		<category><![CDATA[image replacement]]></category>
		<category><![CDATA[internationalization]]></category>
		<category><![CDATA[JavaScript]]></category>
		<category><![CDATA[keyboard access]]></category>
		<category><![CDATA[menu]]></category>
		<category><![CDATA[menulist]]></category>
		<category><![CDATA[multi-level menus]]></category>
		<category><![CDATA[navigation]]></category>
		<category><![CDATA[pull-down]]></category>
		<category><![CDATA[role]]></category>
		<category><![CDATA[scalability]]></category>
		<category><![CDATA[screen reader]]></category>
		<category><![CDATA[screenreader]]></category>
		<category><![CDATA[sIFR]]></category>
		<category><![CDATA[tab order]]></category>
		<category><![CDATA[text resize]]></category>
		<category><![CDATA[WCAG]]></category>
		<category><![CDATA[web 2.0]]></category>

		<guid isPermaLink="false">http://learningtheworld.eu/?p=171</guid>
		<description><![CDATA[A few days ago a co-worker asked if <strong><acronym title="Dynamic HTML">DHTML</acronym> drop-down menus pose a problem with accessibility</strong>. Since the Web Content Accessibility Guidelines 1.0 (<acronym>WCAG</acronym>) declared all JavaScript <em>evil</em> in 1999, assistive technologies (<acronym>AT</acronym>) have made significant progress. So we cannot condemn pull-down menus altogether, but there are various reasons to keep an eye on them buggers.&#160;[&#8230;]]]></description>
				<content:encoded><![CDATA[<p>A few days ago a co-worker asked if <strong><acronym title="Dynamic HTML">DHTML</acronym> drop-down menus pose a problem with accessibility</strong>. Since the Web Content Accessibility Guidelines 1.0 (<acronym>WCAG</acronym>) declared all JavaScript <em>evil</em> in 1999, assistive technologies (<acronym>AT</acronym>) have made significant progress. So we cannot condemn pull-down menus altogether, but there are various reasons to keep an eye on them buggers:</p>

<ol>
<li id="ageing"><p><strong>Older people</strong> have difficulties with drop-down and <a href="http://www.w3.org/TR/wai-age-literature/">multi-level menus</a>, because their manual dexterity, eye-hand coordination and space perception decreases. Also some move the mouse when clicking, or tremble, hence it&#8217;s more likely they slip off the menu. Hell, that happens to <em>me</em> frequently!</p>
<p>However, did you notice the Windows Start Menu is more forgiving when you slip off an item? There&#8217;s a little delay before the secondary level is hidden. Perhaps we need an event-capturing script tolerating a slip from the menu rather than the immediate reaction of the <code>mouseout</code> event.</p></li>
<li id="hicks-law"><p>Nested menus are <strong>more complex</strong>. According to <a href="http://en.wikipedia.org/wiki/Hick%27s_law">Hick&#8217;s Law</a> orientation in a multi-level menu can take longer than multiple clicks in a flat menu with good information architecture. See an <a href="http://learningtheworld.eu/2007/usability-analysis/#hicks-law">earlier article</a> for the math.</p></li>
<li id="keyboard-access"><p>The navigation must be <strong>accessible by keyboard alone</strong>. The result should be the same, whether you hover over an item or tab to it. So check for the <code>focus</code> event and <acronym title="Cascading Style Sheets">CSS</acronym> pseudo-class. Don&#8217;t forget to test backwards tabbing (<kbd>shift tab</kbd>). By the way, mobile devices have no mouse either&hellip;</p>
<p>The <strong>tab order</strong> should be consistent and logical, <abbr>i.e.</abbr> not jumping around on a page. Also the focused item should be visible, for example highlighted with the default 1px dotted border some browsers draw around it. Some people think this is ugly and remove the default border. That is a no-no.</p>
<p>And if you <em>really</em> want desktop behavior, add support for the <strong>arrow keys</strong> (<code>event.keyCode</code> 37-40). Keep in mind though that screen readers have predefined functions for the arrow keys in combination with the <kbd>ctrl</kbd>, <kbd>shift</kbd>, or <kbd>alt</kbd> keys. In JavaScript those keys can be detected with the <code>event.ctrlKey</code>, <code>event.altKey</code>, and <code>event.shiftKey</code> properties. Also <strong>crossbrowser event delegation</strong> for <code>focus</code> or <code>blur</code> events can be a bitch, thankfully <a href="http://www.quirksmode.org/blog/archives/2008/04/delegating_the.html"><acronym title="Peter-Paul Koch">PPK</acronym> has a solution</a>.</p></li>
<li id="skip-content"><p>Users of <acronym>AT</acronym> should have means to <strong>skip content</strong>. That&#8217;s possible with semantic markup: a menu as (nested) list(s) enables them to jump to the next block. Also there should be <em>a few</em> skip links at the beginning of the code pointing to important sections on the page, such as content, navigation, or search. Mobile users also profit from that technique (try surfing eBay with Opera Mini <img src="http://learningtheworld.eu/wp-includes/images/smilies/icon_wink.gif" alt=";)" class="wp-smiley" />  ).</p></li>
<li id="links"><p><strong>Pages never link to themselves.</strong> When I click on a link (the menu being no exception) I expect to land on a <em>different</em> page. Therefore it&#8217;s confusing to land on the same page. This happened to me recently when I was filling out a form on my mobile phone and got the same page with an error message. It took me a while to realize where I was. It&#8217;s the same whether you have a tiny screen or a low screen resolution to see things larger when you are visually impaired: you only see a small part of the page, so it&#8217;s hard to realize when something unexpected happens.</p></li>
<li id="aria"><p>You can add some semantic sugar with the <strong><acronym title="Accessible Rich Internet Applications">ARIA</acronym> <code>role</code></strong> property. In this case <code>&lt;ul role=&quot;navigation&quot;&gt;</code> would be appropriate. I strongly encourage you to use <acronym>ARIA</acronym> as it is widely supported by browsers and screen readers, enhances a disabled user&#8217;s experience, and doesn&#8217;t break old browsers. A most <a href="http://dev.opera.com/articles/view/introduction-to-wai-aria/">recent introduction</a> has been written by Gez Lemon for the Opera Developer Community.</p></li>
<li id="buffer"><p>If a second level navigation is initially hidden with <code>display:none</code> it won&#8217;t be in the <strong>screen reader buffer</strong>. Therefore off-screen positioning is a better idea, else you need to <a href="http://juicystudio.com/article/improving-ajax-applications-for-jaws-users.php">update the buffer</a> by writing random values into a hidden <code>input</code> field.</p></li>
<li id="scaling"><p>A common problem in menus is <strong>limited horizontal space</strong>. Text should be scalable, and it must not jut-out into other page elements when it is <strong>enlarged</strong>. Even normal text can break a narrow menu when you think of internationalization. In German there are many composite words. While building a website for a competing brand I came across a menu item on the Philips website for &ldquo;male grooming.&rdquo; The German word &bdquo;<span xml:lang="de" lang="de">Körperhaarpflegesystem</span>&rdquo; is guaranteed to blow every menu! <img src="http://learningtheworld.eu/wp-includes/images/smilies/icon_smile.gif" alt=":)" class="wp-smiley" /> </p>
<p>Another common problem that prevents scaling in menus are <strong>text graphics</strong>. I know marketing just <em>loves</em> to see the corporate font in the main menu, but text in images can&#8217;t be scaled, people with visual impairments can&#8217;t change text and background colors for higher contrast, and <strong>Flash Image Replacement</strong> like sIFR still has <a href="http://virtuelvis.com/archives/2005/04/i-hate-sifr">accessibility issues</a>, is known to <a href="http://www.456bereastreet.com/archive/200712/choose_an_accessible_image_replacement_method/#comment26">distort fonts</a>, is <a href="http://www.mezzoblue.com/archives/2004/10/26/sifr/">CPU intensive and slow</a>. The bottom line is: don&#8217;t use text as images, make textual information text.</p></li>
</ol>

<p id="technical-issues">So much for accessibility. Besides there are a few <strong>technical issues</strong> to consider: mobile devices often have problems with JavaScript or with layers. Some proxies in large companies <a href="http://www.robertnyman.com/2006/04/25/an-important-lesson-learned-about-ajax-and-accessibility/">filter JavaScript</a> for security reasons, so you can&#8217;t rely on the ubiquitous availability, your script has to be unobtrusive, and you can&#8217;t rely on <code>noscript</code> either. Don&#8217;t even think of creating a menu from JavaScript arrays.</p>

<p>Moreover there&#8217;s a well-known bug in <acronym title="Internet Explorer">IE</acronym>6 responsible for showing <code>select</code> lists always in front of any layers (like your second level menu), regardless of a <code>z-index</code>. Thankfully there are plugins like <a href="http://brandonaaron.net/docs/bgiframe/">bgiframe</a> for jQuery to solve this. Multi-level menus can bloat the code, event handling can be CPU intensive (use <a href="http://icant.co.uk/sandbox/eventdelegation/">event delegation</a>). And if large amounts of menu code is at the beginning, the real content gets further behind and less relevant for search engines.</p>

<p>In <strong>conclusion</strong>, for an alleged quicker entry you pay with many disadvantages. Often drop-down menus just conceal a poorly planned information architecture. I would reconsider their usage.</p>

<p>Did I forget something? What&#8217;s your opinion on drop-down menus? Love them or hate them?</p>
]]></content:encoded>
			<wfw:commentRss>http://learningtheworld.eu/2008/accessible-drop-down-menus/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>W3C Mobile Web Best Practices Course</title>
		<link>http://learningtheworld.eu/2008/w3c-mobile-course/</link>
		<comments>http://learningtheworld.eu/2008/w3c-mobile-course/#comments</comments>
		<pubDate>Sat, 03 May 2008 15:15:40 +0000</pubDate>
		<dc:creator><![CDATA[Martin Kliehm]]></dc:creator>
				<category><![CDATA[accessibility]]></category>
		<category><![CDATA[W3C]]></category>
		<category><![CDATA[web development]]></category>
		<category><![CDATA[web standards]]></category>
		<category><![CDATA[best practices]]></category>
		<category><![CDATA[Dom Hazael-Massieux]]></category>
		<category><![CDATA[Dominique Hazaël-Massieux]]></category>
		<category><![CDATA[mobile]]></category>
		<category><![CDATA[Philipp Hoschka]]></category>
		<category><![CDATA[Stéphane Boyera]]></category>
		<category><![CDATA[ubiquitous web]]></category>
		<category><![CDATA[UbiWeb]]></category>

		<guid isPermaLink="false">http://learningtheworld.eu/?p=100</guid>
		<description><![CDATA[In what is to my knowledge the first <acronym title="World Wide Web Consortium">W3C</acronym> online course, the <strong>Mobile Web Initiative</strong> offers a free introduction to mobile web best practices starting May <del>18th</del> <ins>26th</ins>.&#160;[&#8230;]]]></description>
				<content:encoded><![CDATA[<p>In what is to my knowledge the first <acronym title="World Wide Web Consortium">W3C</acronym> online course, the <strong>Mobile Web Initiative</strong> offers a free <a href="http://www.w3.org/2008/03/MobiWeb101/Overview.html">introduction to mobile web best practices</a> starting May <del>18th</del> <ins>26th</ins>. Unlike other online courses you are not required to attend nightly classes in another timezone, instead you can watch the lesson anytime you want within a week. Because the instructors need to review your homework, only 100 participants are allowed. So if you are interested in the mobile web or how mobile and accessibility best practices overlap, better rush and <a href="http://www.3gwebtrain.com/moodle/">register</a>!</p>

<p>The four lessons include a view of the big picture, coding, usability and design challenges, and understanding the relationship with other <acronym>W3C</acronym> standards and activities. Your instructors are among the best: <strong>Stéphane Boyera</strong> is leading the <acronym>W3C</acronym>&rsquo;s work on the mobile web in developing countries, <strong>Dominique Hazaël-Massieux</strong> is the Mobile Web Initiative&rsquo;s Activity Lead, and <strong>Philipp Hoschka</strong> is the <acronym>W3C</acronym>&rsquo;s Deputy Director and leading the Ubiquitous Web activities. For more information check the <a href="http://www.w3.org/TR/mobile-bp/">Mobile Best Practices</a> recommendation.</p>
]]></content:encoded>
			<wfw:commentRss>http://learningtheworld.eu/2008/w3c-mobile-course/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>Best Practices in Web Development</title>
		<link>http://learningtheworld.eu/2006/best-practices/</link>
		<comments>http://learningtheworld.eu/2006/best-practices/#comments</comments>
		<pubDate>Mon, 10 Jul 2006 16:56:19 +0000</pubDate>
		<dc:creator><![CDATA[Martin Kliehm]]></dc:creator>
				<category><![CDATA[web development]]></category>
		<category><![CDATA[web standards]]></category>
		<category><![CDATA[best practices]]></category>
		<category><![CDATA[checklist]]></category>
		<category><![CDATA[common errors]]></category>
		<category><![CDATA[CSS]]></category>
		<category><![CDATA[CSS reboot]]></category>
		<category><![CDATA[HTML]]></category>
		<category><![CDATA[new professionalism]]></category>
		<category><![CDATA[Roger Johansson]]></category>
		<category><![CDATA[Sean Fraser]]></category>
		<category><![CDATA[XHTML]]></category>

		<guid isPermaLink="false">http://learningtheworld.eu/2006/best-practices/</guid>
		<description><![CDATA[Roger Johansson and Sean Fraser recently reviewed websites which were submitted for the CSS Reboot Spring 2006, and they seemed to be quite shocked when 71.8% failed to validate. While this is sobering and to a degree surprising â€” one might expect better results from CSS aware developers on a relaunch â€” it confirmed my own results from reviewing a couple of high profile websites for clients.&#160;[&#8230;]]]></description>
				<content:encoded><![CDATA[<p id="intro"><strong><a href="http://www.456bereastreet.com/archive/200606/css_reboot_participants_far_from_standardsbased/" rel="colleague met" title="Roger Johansson about CSS reboot">Roger Johansson</a> and <a href="http://www.elementary-group-standards.com/web-standards/css-reboot-as-web-standards-validation-indicator.html" title="Sean Fraser about CSS reboot" rel="colleague">Sean Fraser</a> recently reviewed websites which were submitted for the <a href="http://www.cssreboot.com"><acronym title="Cascading Style Sheets">CSS</acronym> Reboot Spring 2006</a>, and they seemed to be quite shocked when 71.8% failed to validate.</strong> While this is sobering and to a degree surprising &mdash; one might expect better results from <acronym>CSS</acronym> aware developers on a relaunch &mdash; it confirmed my own results from reviewing a couple of high profile websites for clients.</p>

<h3 id="toc">In this article:</h3>

<ul class="toc">
    <li><a href="#case-study">Case study</a></li>
    <li><a href="#html">Best practices in <acronym title="Hypertext Markup Language">HTML</acronym></a></li>
    <li><a href="#css">Best practices in <acronym>CSS</acronym></a></li>
    <li><a href="#search-engines">Best practices for search engines</a></li>
</ul>

<h3 id="case-study">Case study</h3>

<p id="cs-intro">Over the years we made several <strong>technical analyses</strong> for the clients&rsquo; own websites and some of their competitors, including major German broadcasting companies, TV program journals, and a couple of large online travel sites.</p>

<p id="cs-scope">We were checking for overall performance like file sizes as well as best practices in <acronym title="Extensible Hypertext Markup Language">(X)HTML</acronym>, <acronym>CSS</acronym>, semantics, and some other aspects of friendliness to users and search engines. We mostly skipped accessibility because there were already severe errors in the other areas.</p>

<p id="cs-summary">It&rsquo;s not like these websites were made by some backstreet <del>crack houses</del> <ins>agencies</ins>. All have a well-known logo stuck to them, most of them get more than a million visits each month, some up to more than a hundred million. Still the reviews felt like a time-travel to 1998. In our elite circles we speak about a &ldquo;<a href="http://www.webstandards.org/2005/11/15/web-standards-and-the-new-professionalism/" title="Molly Holzschlag on the Web Standards Project (WaSP) website about new professionalism" rel="colleague met">new professionalism</a>,&rdquo; but <acronym>HTML</acronym> in the wild is <em>still</em> a <em>very</em> dark and ugly jungle.</p>

<p id="cs-common-errors"><strong>Most common errors</strong> were missing <code>alt</code>-attributes and unencoded <span class="nowrap"><code>&amp;</code>-characters</span> in <acronym title="Uniform Resource Locator">URL</acronym>s. Also quite common were <acronym title="Extensible Markup Language">XML</acronym> endslashes in <acronym>HTML</acronym> documents, or hacks from the nineties: proprietary attributes like <code>background</code> in table data, <code>height</code> in a table row, <code>marginwidth</code>, <code>marginheight</code>, <code>topmargin</code> and <code>leftmargin</code>, or missing <code>type</code> attributes in <code>style</code> and <code>script</code> tags.</p>

<p id="cs-proprietary-tags">Getting into the depths of old-school programming we found proprietary tags like <code>&lt;nobr&gt;</code>, <code>&lt;ilayer&gt;</code>, or <code>&lt;spacer&gt;</code>, misconceptions like <code>valign=&quot;center&quot;</code> instead of <code>&quot;middle&quot;</code>, forgotten closing tags, or tag soup like the classic <code>form</code> between table rows (to prevent top margins), block level elements inside of inline elements, <code>&lt;p&gt;</code> tags around everything (including tables and headlines!), or <code>script</code> tags before or after <code>&lt;html&gt; &lt;/html&gt;</code>. Especially ad servers and site statistics were infamous for their crappy stone-age code.</p>

<p id="cs-dtd">Only a few were missing a doctype declaration (DTD) altogether, most ran <acronym>HTML</acronym> transitional 4.01 in quirks mode, only one claimed to be <acronym>XHTML</acronym>&nbsp;1.1 (<em>gasp</em>). Seven out of ten had a charset encoding, but only the <acronym>XHTML</acronym> website did care to define the site&rsquo;s language. Almost all had no clue about <acronym>CSS</acronym> positioning and used table layout.</p>

<p id="cs-basics">Sometimes we encountered code where developers obviously hadn&rsquo;t understood even the most basic principles of <acronym>CSS</acronym>&nbsp;1. They used either <code>font</code> tags with <code>style</code> attributes, or other tags just <em>like</em> <code>font</code> tags with a lot of repeated inline <code>style</code>. Thus the advantages of <acronym>CSS</acronym> through central style sheets with classes and IDs were counteracted.</p>

<p id="cs-file-size">It didn&rsquo;t come as a surprise that the few websites using <acronym>CSS</acronym>&nbsp;2 for layout had <strong>significant smaller file sizes</strong>. Those with <acronym>CSS</acronym>&nbsp;2 had between 15-21&nbsp;<abbr title="Kilobyte">KB</abbr> of <acronym>HTML</acronym>, their competitors with table layout 55-95&nbsp;<abbr>KB</abbr>. Still you got to pay attention to the file size of images and rich media (including banners) as they frequently blow up the total amount. Be aware of <acronym title="Dynamic HTML">DHTML</acronym> menus, as they have a tendency to get out of control sizewise (<abbr title="40 kilobytes">40k</abbr> JavaScript in one case, <abbr title="85 kilobytes">85k</abbr> in another). Less than a total of <abbr title="100 kilobytes">100k</abbr> for the home page should be sufficient, even for sites with rich graphic interfaces.</p>

<p id="cs-checklist">I don&rsquo;t want to bore you with further rants about burning bandwidth with <abbr title="600 kilobytes">600k</abbr> large home pages (multiply <em>that</em> by a million), hence we thought positive and made a <strong>checklist of best practices</strong>. Although the checkpoints appear to be quite obvious and common sense when you read them, you might be surprised that the best website managed to fulfil 22 out of 29 checkpoints, the worst only 8, with an average of 12.</p>

<p id="cs-job-test">By the way, the <acronym>HTML</acronym> and <acronym>CSS</acronym> part of the checklist is more or less the same we use for testing the qualifications of <em>job applicants</em>. We associated a severity grade (<em>major</em>, <em>average</em>, <em>minor</em>) with each checkpoint, and for each error in the small task we give them we subtract 3, 2, or 1 point(s) respectively from a maximum of 100. Half the amount is subtracted when a checkpoint is partially fulfilled. We adopted that system from the German <a href="http://www.bitvtest.de" hreflang="de">accessibility test</a> &mdash; it&rsquo;s fair and a great way to compare test results.</p>

<p id="cs-checklist-intro">Here&rsquo;s the short version of our checklist. Feel free to make your own severity rating. Just be consistent in your own tests to get comparable results.</p>

<h3 id="html">Best practices in <acronym>HTML</acronym></h3>

<ol class="alpha">
    <li id="html-validation">The document <a href="http://validator.w3.org" title="External link to the World Wide Web Committee&rsquo;s validator">must validate</a> as <acronym>HTML</acronym> or <acronym>XHTML</acronym>.</li>
    <li id="html-dtd">The document must have a <strong><acronym title="Doctype Declaration">DTD</acronym></strong>.</li>
    <li id="html-character-encoding">The document must have a <a href="http://www.w3.org/TR/html401/charset.html#h-5.2.1" title="HTML 4.01 specification about character encoding">character encoding</a>, either through a <acronym title="Hypertext Transfer Protocol">HTTP</acronym> header or a <code>meta</code> tag.</li>
    <li id="html-language">
        <p>The document should have the <strong>language defined</strong> in the following ways:</p>
        <ul>
            <li><code>&lt;html lang=&quot;en&quot;&gt;</code></li>
            <li><code>&lt;html xml:lang=&quot;en&quot;&gt;</code></li>
            <li><code>&lt;meta name=&quot;content-language&quot; content=&quot;en&quot;&gt;</code></li>
        </ul>
    </li>
    <li id="html-quotes">All <strong>attribute values <a href="http://www.w3.org/TR/html4/intro/sgmltut.html#idx-attribute-6" title="HTML 4.01 Specification about quotes">should be quoted</a></strong>. In <acronym>XHTML</acronym>, <a href="http://www.w3.org/TR/xhtml1/#h-4.4" title="XHTML 1.0 Specification about quotes">quotes are mandatory</a>.</li>
    <li id="html-case">Element and attribute names should use a consistent case to enhance readability, preferred is <strong>lowercase</strong> for <acronym>XHTML</acronym> compability.</li>
    <li id="html-comments">Code should be well <code>&lt;!-- commented --></code> to help maintaining developers to get a fast grip of the basic structure and key concepts.</li>
    <li id="html-indention">Code should be consistently <strong>indented</strong>, tabs preferred over spaces.</li>
    <li id="html-alt">Images, image maps and scripted content must have an <a href="http://www.w3.org/TR/html4/struct/objects.html#adef-alt" title="HTML 4.01 specification about alternative text"><code>alt</code>-attribute</a> with an appropriate value.</li>
    <li id="html-width-height">Images should always <a href="http://www.w3.org/TR/html401/struct/objects.html#adef-width-IMG" title="HTML 4.01 specification about width and height">specify their <code>width</code> and <code>height</code></a> to allow browsers to continue rendering while waiting for the image data.</li>
    <li id="html-entities">Some special characters like <code>&amp;quot;</code>, <code>&amp;lt;</code>, <code>&amp;gt;</code>, and <a href="http://www.w3.org/TR/html401/appendix/notes.html#h-B.2.2" title="HTML 4.01 specification about ampersands in URI attribute values"><code>&amp;amp;</code></a> (especially within attributes like <code>href</code> or <code>src</code>) must always be replaced by their <strong>character entities</strong> or numeric character references (NCR). Also characters not included in the character set, like <code>&amp;euro;</code> in ISO 8859-1, must be replaced. The <acronym title="World Wide Web Consortium">W3C</acronym> <abbr title="Internationalization">I18N</abbr> activity group further <a href="http://www.w3.org/International/questions/qa-escapes" title="W3C: Using character entities and NCRs">recommends</a> to replace other special characters like <code>&amp;ndash;</code>, but <em>not</em> common characters like &ldquo;&uuml;&rdquo; in German texts or &ldquo;&eacute;&rdquo; in French to maintain code readability.</li>
    <li id="html-type"><code>script</code> and <code>style</code> tags must have a <a href="http://www.w3.org/TR/html401/interact/scripts.html#h-18.2.1" title="HTML 4.01 specification about the script type"><code>type</code></a> attribute.</li>
    <li id="html-js">
        <p><strong>JavaScript</strong> code should be included using <strong>external files</strong> for caching and better maintenance.</p>
        <p>Of course with <strong>Yahoo&rsquo;s performance research</strong> about <a href="http://yuiblog.com/blog/2007/01/04/performance-research-part-2/">browser cache</a> and <a href="http://yuiblog.com/blog/2006/11/28/performance-research-part-1/"><acronym>HTTP</acronym> requests</a> you could discuss if external files load faster with several server requests through <code>script src=&quot;foo.js&quot;</code> or just one request and internal <acronym>HTML</acronym> code, but either way you should use central, non-redundant files and include them in one way or another.</p>
    </li>
</ol>

<h3 id="css">Best practices in <acronym>CSS</acronym></h3>

<ol class="alpha">
    <li id="css-validation"><acronym>CSS</acronym> <a href="http://jigsaw.w3.org/css-validator/" title="External link to the World Wide Web Consortium&rsquo;s CSS validator">must validate</a>.</li>
    <li id="css-positioning">Elements should be <strong>positioned with <acronym>CSS</acronym>&nbsp;2</strong>, not tables.</li>
    <li id="css-decoration">All ornamental lines, borders, background colors and -images, underlines and other <strong>decorational elements</strong> should be rendered <strong>with <acronym>CSS</acronym>&nbsp;2</strong>.</li>
    <li id="css-formatting"><strong>Text</strong> should be <strong>formatted with <acronym>CSS</acronym>&nbsp;1</strong>, not with <code>font</code> tags.</li>
    <li id="css-external">All style sheets should be included in reusable, centrally maintainable, and cacheable <strong>external <acronym>CSS</acronym> files</strong>, not as redundant code within the <acronym>HTML</acronym> files.</li>
    <li id="css-mime-type">External <acronym>CSS</acronym> files should be sent with the <strong>correct MIME type</strong> (<code>text/css</code>).</li>
    <li id="css-naming-conventions"><strong><acronym>CSS</acronym> classes and IDs must be valid</strong>, <abbr title="that is">i.e.</abbr> <a href="http://www.w3.org/TR/html401/types.html#type-id">beginning with a letter</a>, not a number or an underscore. IDs must be unique. Their names should be <a href="http://www.w3.org/QA/Tips/goodclassnames" title="W3C Quality Assurance Tip: Use &quot;class&quot; with semantics in mind">generic</a>, describe functionality rather than appearance.</li>
</ol>

<h3 id="search-engines">Best practices for search engines</h3>

<ol class="alpha">
    <li id="se-title">Use a <strong>descriptive title</strong> with the name of the website and consistent separating characters in it.</li>
    <li id="se-keywords">Use <strong>keywords, keyphrases, and a description</strong> reflecting the page&rsquo;s content.</li>
    <li id="se-url-design">The <a href="http://www.w3.org/Provider/Style/URI" title="Tim Berners-Lee&rsquo;s article &ldquo;Cool URIs don&rsquo;t change&rdquo;"><acronym>URL</acronym> should be descriptive</a>, <a href="http://www.adaptivepath.com/publications/essays/archives/000058.php" title="Jesse James Garrett about &ldquo;User-Centered URL Design&rdquo;">human-readable</a>, easy to remember, to bookmark, and easy to spell on a phone. Don&rsquo;t bother the user with file extensions, thus you will be future compatible and independent from your current software.</li>
    <li id="se-robots-txt">Use the <a href="http://www.robotstxt.org">Robots Exclusion Standard</a>, <abbr>i.e.</abbr> <code>robots.txt</code>.</li>
    <li id="se-relevance">The <strong>content should be as high up</strong> in the code as possible as it gets more relevance there.</li>
    <li id="se-semantics">Use <strong>proper semantic code</strong>, like headlines, or list items for anything that resembles a list. Don&rsquo;t use list items to get bullet points or headlines to set bold text.</li>
    <li id="se-link">Use <a href="http://www.w3.org/TR/html401/types.html#type-links" title="HTML 4.01 specification about link types"><code>&lt;link&gt;</code> tags</a> to specify relations between pages, like <code>rel=&quot;start&quot;</code>, <code>chapter</code>, <code>prev</code>, or <code>next</code>, as search engines might value your start page more, or browsers could preload <code>next</code> pages.</li>
    <li id="se-favicon">Use a <a href="http://favicon.com">favorite icon</a> for bookmarking and to keep your error log clean.</li>
    <li id="se-pics">Use the <a href="http://www.w3.org/PICS/"><acronym title="Platform for Internet Content Selection">PICS</acronym></a> <a href="http://www.icra.org" title="Internet Content Rating Association, external link where you can label your website">standard</a> to signal search engines and filter programs that your website is safe for kids.</li>
</ol>
]]></content:encoded>
			<wfw:commentRss>http://learningtheworld.eu/2006/best-practices/feed/</wfw:commentRss>
		<slash:comments>12</slash:comments>
		</item>
	</channel>
</rss>
