<?xml version="1.0" encoding="UTF-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
    <link href="https://friendlybit.com/feed/" rel="self" type="application/atom+xml" />
    <link href="https://friendlybit.com/" rel="alternate" type="text/html" />
    <updated>2008-11-20T18:58:16+01:00</updated>
    <id>https://friendlybit.com</id>
    <title type="html">Friendly Bit - Web development blog</title>
    <subtitle>Friendly Bit is a blog by Emil Stenström, a Swedish web developer that occasionally gets ideas of how to improve the internet.</subtitle>
    
        <entry>
            <title type="html">Follow the 10 ground rules, or fail on the web</title>
            <link href="http://friendlybit.com/tutorial/10-web-ground-rules/" rel="alternate" type="text/html" title="Follow the 10 ground rules, or fail on the web" />
            <published>2008-11-20T18:58:16+01:00</published>
            <updated>2008-11-20T18:58:16+01:00</updated>
            <id>http://friendlybit.com/tutorial/10-web-ground-rules/</id>
            <author>
                <name>Emil Stenström</name>
            </author>
            <summary type="text">When you work with the web, there are a couple of basics you really need to get right. These are things I see people misunderstand over and over again, with...</summary>
            <content type="html" xml:base="http://friendlybit.com/tutorial/10-web-ground-rules/">
                &lt;p&gt;When you work with the web, there are a couple of basics you really need to get right. These are things I see people misunderstand over and over again, with a varying degree of failiure as a result. Not only individuals make these mistakes, even really big organizations make them, and suffer as a result. So lets get at it.&lt;/p&gt;
&lt;h2 id=&#34;1-everyone-is-stronganonymousstrong-on-the-w&#34;&gt;1. Everyone is &lt;strong&gt;anonymous&lt;/strong&gt; on the web, if they want to&lt;a href=&#34;#1-everyone-is-stronganonymousstrong-on-the-w&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;If you depend on trying to identify who a particular user on the web is, you will fail in every way possible. This is what lots of law firms try to do, especially in the context of file sharing. You will never ever be able to know who someone online is, if they don&#39;t want you to.&lt;/p&gt;
&lt;p&gt;Technical reasons: &lt;strong&gt;IP-numbers are easy to fake&lt;/strong&gt;, but using proxy servers of different sorts. New services are constantly popping up, that makes this available for unexperienced users. Just push them a little more, send a couple of more &lt;a href=&#34;http://en.wikipedia.org/wiki/Cease_and_desist&#34;&gt;cease and desist&lt;/a&gt; letters and even ordinary home users will start to cloak who they are. It&#39;s possible, it&#39;s easy.&lt;/p&gt;
&lt;p&gt;Social reasons: It&#39;s very easy to surf using &lt;strong&gt;someone else&#39;s internet connection&lt;/strong&gt;. Ways vary from just connecting to an unencrypted wireless network, to just using the free connection at a library or school. And it&#39;s getting worse: people are starting to move around while using the web (mobile), hopping from one connection to the next as their geographic position permits. The link between internet connections and users are getting blurrier as we speak.&lt;/p&gt;
&lt;p&gt;Despite the above, there are things you can identify and use. One of those is categorizing users into user types. This is what Google (and lots of others) are successfully doing with their advertising system. &amp;quot;Based on what you&#39;ve showed interest in previously, we think you will like this&amp;quot;. This enables you to personalize and customize your content to a particular user type, something that holds lots of economical value (if that&#39;s what you&#39;re after).&lt;/p&gt;
&lt;h2 id=&#34;2-give-your-content-away-for-strongfreestrong&#34;&gt;2. Give your content away for &lt;strong&gt;free&lt;/strong&gt;, or watch someone else do it&lt;a href=&#34;#2-give-your-content-away-for-strongfreestrong&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;The web is a gigantic content creation machine, and except for very niched content, you can find anything on it. If you are in the business of selling content online, you will see your profits &lt;strong&gt;steadily decline&lt;/strong&gt;. The competition is just too intense when anyone can create content.&lt;/p&gt;
&lt;p&gt;How do you tackle that? Well, put your previously costly content online for free, to &lt;strong&gt;drive people to your site&lt;/strong&gt;. If the content is good, your will see a massive surge in number of users. Well on the site, you will need to figure out how to &lt;strong&gt;make money of them&lt;/strong&gt;, either by showing them ads or getting them to buy something physical.&lt;/p&gt;
&lt;p&gt;Industries that depend on online content creation are really living on the edge right now, and for a future prediction, just look at the music industry. You still have some time to rethink your bussiness model.&lt;/p&gt;
&lt;h2 id=&#34;strong3-linkingstrong-is-the-core-of-the-web&#34;&gt;&lt;strong&gt;3. Linking&lt;/strong&gt; is the core of the web, make people want to link to you&lt;a href=&#34;#strong3-linkingstrong-is-the-core-of-the-web&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;It&#39;s called a web because of the links. Trying to limit or control other sites linking to you is fundamentally breaking the web. It&#39;s also downright stupid, since every external link is a vote for your site, and a sure way for people to find you. Having an &amp;quot;link policy&amp;quot;, controlling how people may link to you, is a sure way to make a fool out of yourself online. Not to say that people won&#39;t care one bit about it.&lt;/p&gt;
&lt;p&gt;Instead, you should encourage people to link to you. How? By first giving every piece of content a &lt;strong&gt;linkable address&lt;/strong&gt;. Many flash- and frame-based sites miss this fact, and instead require users to click through your frontpage to find the content they want. This is a sure way to turn users away. Just make your content linkable, it&#39;s not hard.&lt;/p&gt;
&lt;p&gt;Then, make sure the content is in such a high quality that users want to link to it. This rules out saying what everyone else is saying, in the same way everyone else is saying it. You need to be &lt;strong&gt;different,&lt;/strong&gt; and have &lt;strong&gt;genuinely interesting&lt;/strong&gt; content, that no one else has. This is hard, but a problem you need to solve to make it on the web.&lt;/p&gt;
&lt;h2 id=&#34;4-link-to-strongexternal-sitesstrong-with-go&#34;&gt;4. Link to &lt;strong&gt;external sites&lt;/strong&gt; with good content, it&#39;s all about servicing your users&lt;a href=&#34;#4-link-to-strongexternal-sitesstrong-with-go&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;There&#39;s billions of sites a user can go to, and you need to work hard to servicing your users if you want their attention. Sometimes your content is so extensive, that no matter how hard you work, users will still want more. This is a perfect situation where you should link to external sites and give your users what they want.&lt;/p&gt;
&lt;p&gt;Many newspaper make this mistake, and end up with users leaving their site for Google, trying to find more information about a particular piece of content. They have instead linked to good follow-up content directly, given the user what they wanted, and be accessible via the most used button on the web, the back-button. &lt;strong&gt;Happy users&lt;/strong&gt; that have &lt;strong&gt;easy access to your site&lt;/strong&gt;, or annoyed users that leave for Google, your choice.&lt;/p&gt;
&lt;h2 id=&#34;5-people-will-strongcopy-your-contentstrong&#34;&gt;5. People will &lt;strong&gt;copy your content&lt;/strong&gt;, and there&#39;s nothing you can do about it&lt;a href=&#34;#5-people-will-strongcopy-your-contentstrong&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;Some people are worried about the copying of their content. And if they see that as an issue, they better be worried. You see, each time someone reads your texts, or looks at your media, it&#39;s copied from your server to the users computer. Web browsers are really effective copyright infringement machines, and by just clicking a link, you copy that page.&lt;/p&gt;
&lt;p&gt;So if you are worried about users copying your content, please &lt;strong&gt;don&#39;t put it online at all&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;Other people think that they can have their content on the web, and still prevent people from copying it. This is pure lunacy, and all ways to prevent copying have failed. People even miss the most obvious way people can copy, by hitting the &amp;quot;Print screen&amp;quot; button on their keyboards. When it comes to video and audio it&#39;s a bit more annoying, but everything that comes out of your speakers, or is displayed on the screen, is recordable. So stop worrying about copying, &lt;strong&gt;you can&#39;t stop it&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;Instead, know and accept that people will copy your content, and just ask for a simple &lt;strong&gt;link back&lt;/strong&gt; if they do. That way, small pieces of your content on other sites will act as marketing for the whole site.&lt;/p&gt;
&lt;p&gt;If you want this formalized as a license, there is the &lt;a href=&#34;http://creativecommons.org/licenses/by/2.0/&#34;&gt;creative commons attribution license&lt;/a&gt;, which I use on this site (see footer).&lt;/p&gt;
&lt;h2 id=&#34;6-use-the-web-to-strongcommunicatestrong-wit&#34;&gt;6. Use the web to &lt;strong&gt;communicate&lt;/strong&gt; with your users, or watch your impact fade&lt;a href=&#34;#6-use-the-web-to-strongcommunicatestrong-wit&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;Almost everything is moving to the web, including most of your business and private life. This of course has implications for web sites. Back in 1999, a couple of smart people sat together and tried to formulate how the future would look for businesses. One of the fundamental truths they found was &amp;quot;&lt;a href=&#34;http://www.cluetrain.com/book/markets.html&#34;&gt;Markets are conversations&lt;/a&gt;&amp;quot;. In essence, this means that &lt;strong&gt;you sell stuff by talking&lt;/strong&gt; about it with customers. It can be through marketing or through recommendation, but it is talking. When that communication moves to the web, you too better start talking &lt;strong&gt;on the web&lt;/strong&gt;. And quickly.&lt;/p&gt;
&lt;p&gt;This movement of websites for two-way instead of one-way communication has been given the techy name Web 2.0. And it turns out, this new web is a terribly effective way of communicating. The more people realize this, the more of the conversations will move to the web.&lt;/p&gt;
&lt;p&gt;The question is, when hoards of people come to your site to talk to you about your product, are your ready? Or will you give them: &amp;quot;Sorry, this store is closed, but we have this nice brochure you can read…&amp;quot;&lt;/p&gt;
&lt;h2 id=&#34;7-communicate-with-your-users-in-strongnatural&#34;&gt;7. Communicate with your users in &lt;strong&gt;natural language&lt;/strong&gt;, marketing speech has no place on the web&lt;a href=&#34;#7-communicate-with-your-users-in-strongnatural&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;It&#39;s easy to find marketing speech about products today. Companies compete with each other to make sure as much of your field of vision as possible is filled with their message. When people are subjected to that much information they have no interest in, there are consequences. On the early web, the consequences were banner blindness, people simply started ignoring some banner formats. On the modern web, people have started &lt;strong&gt;ignoring marketing language&lt;/strong&gt; use instead. The words &amp;quot;Best&amp;quot;, &amp;quot;Revolutionize&amp;quot; and &amp;quot;Cheapest&amp;quot;, instantly makes people stop reading.&lt;/p&gt;
&lt;p&gt;Why? Because companies writing about their own products don&#39;t have anything to compare to! They can&#39;t say what&#39;s &lt;strong&gt;best&lt;/strong&gt;, because they don&#39;t use their competitor&#39;s products. They don&#39;t know if the product will &lt;strong&gt;revolutionize&lt;/strong&gt; the users life, because they know nothing about the user. And any user can look up how &lt;strong&gt;cheap&lt;/strong&gt; they are on a price comparison site.&lt;/p&gt;
&lt;p&gt;So what to do? Talk to them like you would to a friend, in the afternoon, &lt;a href=&#34;http://www.youtube.com/watch?v=OqhXwjBVVRY&#34;&gt;after two beers&lt;/a&gt;. This will make sure you don&#39;t turn customers away by trying to push to much crap on them. You wouldn&#39;t do it to your friend? Then don&#39;t do it to potential customers. Just changing your language has huge positive implications, but let me just sum it up like this: &lt;strong&gt;it builds trust&lt;/strong&gt;.&lt;/p&gt;
&lt;h2 id=&#34;8-be-stronghoneststrong-about-what-your-stre&#34;&gt;8. Be &lt;strong&gt;honest&lt;/strong&gt; about what your strengths are, liars are easily uncovered&lt;a href=&#34;#8-be-stronghoneststrong-about-what-your-stre&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;Never has it been so easy to look up facts. Liars are easily uncovered by a couple of soft tappings on a keyboard. What&#39;s even better, is that even subjective things can be checked. If someone yells: &amp;quot;Our product is the best one!&amp;quot;, you can find out if that&#39;s the case in a few seconds. Just read a couple of reviews, look at comparison charts, and you will know.&lt;/p&gt;
&lt;p&gt;Lying in person is rather bad, but &lt;strong&gt;lying on the web is worse&lt;/strong&gt;. All the facts are so close. A customer is literally seconds away from finding out if you&#39;re bullshitting them or telling the truth. This makes it vital not to lie on the web.&lt;/p&gt;
&lt;p&gt;If you want to brag anyway, make sure your add a &amp;quot;&lt;strong&gt;we think&lt;/strong&gt;&amp;quot; before all your bold claims, and back them up with solid arguments. Because if you say &amp;quot;We&#39;ve found no cheaper product than our own&amp;quot;, and I find out there are others that in fact are, you&#39;re not a liar, you&#39;re just badly informed.&lt;/p&gt;
&lt;h2 id=&#34;9-care-about-strongsearch-enginesstrong-and&#34;&gt;9. Care about &lt;strong&gt;search engines&lt;/strong&gt;, and double your number of users&lt;a href=&#34;#9-care-about-strongsearch-enginesstrong-and&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;You are not the only site on the web, and people will spend most of their time on sites other than your own. This means, that if you don&#39;t think about how people find your site, all your content work is in vain.&lt;/p&gt;
&lt;p&gt;So how are people found? I have yet to see a customer of mine that gets less than 50% of their users from search engines. &lt;strong&gt;Usually 60-70%.&lt;/strong&gt; People tend not to understand the implications of this. A e-store could potentially lose over half their sales by misbehaving in Google&#39;s eyes. This is huge.&lt;/p&gt;
&lt;p&gt;You need to &lt;strong&gt;care about search engines&lt;/strong&gt;. Luckily, they are well synced with the ground rules you&#39;re reading. If you make your content linkable, unique, interesting, and talk to them in a language they understand, you will be successful. All serious search engine optimization guides will say the same.&lt;/p&gt;
&lt;p&gt;The last step, and what many miss, is to &lt;strong&gt;keep track of&lt;/strong&gt; how people find you, and what they find. Then feed that information back to your content producers. That way, you can produce content that people actually like.&lt;/p&gt;
&lt;p&gt;Or, you could lose half your sales. Your choice.&lt;/p&gt;
&lt;h2 id=&#34;10-encouraging-and-acting-upon-strongfeedback&#34;&gt;10. Encouraging and acting upon &lt;strong&gt;feedback&lt;/strong&gt; is currently the best form of marketing&lt;a href=&#34;#10-encouraging-and-acting-upon-strongfeedback&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;Asking for feedback is unfortunately still uncommon. Unfortunate because there are so many out there that could benefit from knowing how they can do better. It&#39;s also fortunate, because it means that you have a chance to be different, and stand out, just by &lt;strong&gt;asking people what they want&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;http://www.ideastorm.com/&#34;&gt;Dell IdeaStorm&lt;/a&gt; is a great example of this. They are simply saying: &amp;quot;Hi, we want your feedback&amp;quot;, and instantly they have media coverage everywhere. Additionally, they get great feedback on how to improve their business.&lt;/p&gt;
&lt;p&gt;Of course, this means you need to act upon feedback too. Telling people that you listen, and then don&#39;t is a much worse offense than not listening at all. So find yourself a good chair, hand out the megaphones, and listen carefully.&lt;/p&gt;
&lt;h2 id=&#34;where-to-now&#34;&gt;Where to now?&lt;a href=&#34;#where-to-now&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;Thanks for reading this far. This article comes from a frustration over how some companies, and individuals, think the web is still a place were they can makes their own rules. I would therefore like to set the foot down, and tell people what I&#39;ve learned about the web, about what works and not.&lt;/p&gt;
&lt;p&gt;I also know that there are other people out there that needs to read this. Do you know some of them? I then appreciate if you could send them the link. &lt;strong&gt;More people need to read this&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;Thanks.&lt;/p&gt;

            </content>
        </entry>
    
        <entry>
            <title type="html">Templated User Controls in ASP.NET</title>
            <link href="http://friendlybit.com/other/templated-user-controls-in-aspnet/" rel="alternate" type="text/html" title="Templated User Controls in ASP.NET" />
            <published>2008-11-18T01:28:43+01:00</published>
            <updated>2008-11-18T01:28:43+01:00</updated>
            <id>http://friendlybit.com/other/templated-user-controls-in-aspnet/</id>
            <author>
                <name>Emil Stenström</name>
            </author>
            <summary type="text">Good design repeats itself. It works hard to convey a whole, a feeling of consistency. Once you understand a part of such a design, you know your way around...</summary>
            <content type="html" xml:base="http://friendlybit.com/other/templated-user-controls-in-aspnet/">
                &lt;p&gt;Good design repeats itself. It works hard to convey a whole, a feeling of consistency. Once you understand a part of such a design, you know your way around all of it. This is often done by repetition, using the same elements, colors, styles, positioning, and so on. This is a good thing.&lt;/p&gt;
&lt;p&gt;Good code &lt;a href=&#34;http://en.wikipedia.org/wiki/Don%27t_repeat_yourself&#34;&gt;never repeats itself&lt;/a&gt;. The number of techniques to avoid it are numerous, and all new languages compete in trying to remove as much repetition as possible (Especially the dynamic ones).&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Good design repeats itself, good code does not.&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;With interface development, you &lt;strong&gt;face the conflict&lt;/strong&gt; above over and over again. You get a design that (rightly) reuses the same concepts over and over, and you need to implement them in code that makes you write the same logic only once. This same time both when writing the code and later when fixing bugs in it, and deep inside, all programmers know that it&#39;s the correct way to do things.&lt;/p&gt;
&lt;p&gt;I&#39;m currently working in a .NET project (EPiServer CMS 5), and is faced with a design that uses the same kind of boxes all over the site. The boxes only differ by color and content, so things like shadows and rounded corners are clear repetition that I want to do only once. I&#39;ll do the shadows and corners with CSS, but for that I need a couple of wrapper divs. Divs that I only want to specify once, and then reuse.&lt;/p&gt;
&lt;p&gt;The prequisites are:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;I want a &lt;strong&gt;flexible&lt;/strong&gt; solution, so I&#39;m not tied to a specific HTML structure (number of divs, or even if I use the div tag or not).&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;No HTML in properties&lt;/strong&gt; that get sent to user-controls&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;No HTML in code-behind&lt;/strong&gt; (a common way in .NET to split logic (code-behind) and templates (ASP.NET and HTML))&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;What I came up with was &lt;a href=&#34;http://msdn.microsoft.com/en-us/library/36574bf6.aspx&#34;&gt;templated user controls&lt;/a&gt;. They provide a way to write controls that wrap any other controls you may have, and add content around them. And it&#39;s easy to write and user. This is how the one I wrote is used:&lt;/p&gt;
&lt;div class=&#34;highlight&#34; data-language=&#34;ASPX-CS&#34;&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;&amp;lt;MyProject:Box&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;na&#34;&gt;runat=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;server&amp;quot;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;&amp;gt;&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;    &lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;&amp;lt;Contents&amp;gt;&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;        &lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;&amp;lt;h2&amp;gt;&lt;/span&gt;Random&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;header...&lt;span class=&#34;nt&#34;&gt;&amp;lt;/h2&amp;gt;&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;        &lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;&amp;lt;asp:Repeater&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;na&#34;&gt;runat=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;server&amp;quot;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;&amp;gt;&lt;/span&gt;...&lt;span class=&#34;nt&#34;&gt;&amp;lt;/asp:Repeater&amp;gt;&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;        &lt;/span&gt;...
&lt;span class=&#34;w&#34;&gt;    &lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;&amp;lt;/Contents&amp;gt;&lt;/span&gt;
&lt;span class=&#34;nt&#34;&gt;&amp;lt;/MyProject:Box&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;p&gt;It simply wraps anything inside it (in this case a heading tag and a asp repeater), and lets me do whatever I want with them. In my case, I wanted to add some generic HTML around lots of different content, but you could do anything you wanted.&lt;/p&gt;
&lt;p&gt;This is how the above was implemented. First the code-behind:&lt;/p&gt;
&lt;div class=&#34;highlight&#34; data-language=&#34;CSHARP&#34;&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;span class=&#34;k&#34;&gt;using&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;nn&#34;&gt;System.Web.UI&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;span class=&#34;k&#34;&gt;namespace&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;nn&#34;&gt;MyProject.templates.units&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;    &lt;/span&gt;&lt;span class=&#34;na&#34;&gt;[ParseChildren(true)]&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;    &lt;/span&gt;&lt;span class=&#34;k&#34;&gt;public&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;k&#34;&gt;partial&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;k&#34;&gt;class&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;nc&#34;&gt;Box&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;n&#34;&gt;System&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;Web&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;UI&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;UserControl&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;    &lt;/span&gt;&lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;        &lt;/span&gt;&lt;span class=&#34;k&#34;&gt;private&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;n&#34;&gt;ITemplate&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;n&#34;&gt;contents&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;k&#34;&gt;null&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;        &lt;/span&gt;&lt;span class=&#34;na&#34;&gt;[TemplateContainer(typeof(TemplateControl))]&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;        &lt;/span&gt;&lt;span class=&#34;na&#34;&gt;[PersistenceMode(PersistenceMode.InnerProperty)]&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;        &lt;/span&gt;&lt;span class=&#34;na&#34;&gt;[TemplateInstance(TemplateInstance.Single)]&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;        &lt;/span&gt;&lt;span class=&#34;k&#34;&gt;public&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;n&#34;&gt;ITemplate&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;n&#34;&gt;Contents&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;        &lt;/span&gt;&lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;            &lt;/span&gt;&lt;span class=&#34;k&#34;&gt;get&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;            &lt;/span&gt;&lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;                &lt;/span&gt;&lt;span class=&#34;k&#34;&gt;return&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;n&#34;&gt;contents&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;            &lt;/span&gt;&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;            &lt;/span&gt;&lt;span class=&#34;k&#34;&gt;set&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;            &lt;/span&gt;&lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;                &lt;/span&gt;&lt;span class=&#34;n&#34;&gt;contents&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;k&#34;&gt;value&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;            &lt;/span&gt;&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;        &lt;/span&gt;&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;        &lt;/span&gt;&lt;span class=&#34;k&#34;&gt;void&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;nf&#34;&gt;Page_Init&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;()&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;        &lt;/span&gt;&lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;            &lt;/span&gt;&lt;span class=&#34;k&#34;&gt;if&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;p&#34;&gt;(&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;contents&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;o&#34;&gt;!=&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;k&#34;&gt;null&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;)&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;                &lt;/span&gt;&lt;span class=&#34;n&#34;&gt;contents&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;InstantiateIn&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;(&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;PlaceHolder1&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;);&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;        &lt;/span&gt;&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;    &lt;/span&gt;&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;p&gt;… and then the &amp;quot;code-front&amp;quot;:&lt;/p&gt;
&lt;div class=&#34;highlight&#34; data-language=&#34;ASPX-CS&#34;&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;&amp;lt;%@&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;n&#34;&gt;Control&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;n&#34;&gt;Language&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;C#&amp;quot;&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;n&#34;&gt;AutoEventWireup&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;true&amp;quot;&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;n&#34;&gt;CodeBehind&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;Box.ascx.cs&amp;quot;&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;n&#34;&gt;Inherits&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;MyProject.templates.units.Box&amp;quot;&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;%&amp;gt;&lt;/span&gt;
&lt;span class=&#34;nt&#34;&gt;&amp;lt;div&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;na&#34;&gt;class=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;box&amp;quot;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;&amp;gt;&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;    &lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;&amp;lt;div&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;na&#34;&gt;class=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;boxwrapper&amp;quot;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;&amp;gt;&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;        &lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;&amp;lt;asp:Placeholder&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;na&#34;&gt;runat=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;server&amp;quot;&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;na&#34;&gt;ID=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;PlaceHolder1&amp;quot;&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;/&amp;gt;&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;    &lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;&amp;lt;/div&amp;gt;&lt;/span&gt;
&lt;span class=&#34;nt&#34;&gt;&amp;lt;/div&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;p&gt;I think this is a &lt;strong&gt;really useful&lt;/strong&gt; way to write user controls, especially for those of you that work as interface developers in a .NET world. Asking the people around me I found that quite a few didn&#39;t know how templated user controls worked, so I hope I will be of use to some of you out there. Happy coding!&lt;/p&gt;

            </content>
        </entry>
    
        <entry>
            <title type="html">Install MySQL-python on Mac OS X (leopard)</title>
            <link href="http://friendlybit.com/tutorial/install-mysql-python-on-mac-os-x-leopard/" rel="alternate" type="text/html" title="Install MySQL-python on Mac OS X (leopard)" />
            <published>2008-10-31T18:37:18+01:00</published>
            <updated>2008-10-31T18:37:18+01:00</updated>
            <id>http://friendlybit.com/tutorial/install-mysql-python-on-mac-os-x-leopard/</id>
            <author>
                <name>Emil Stenström</name>
            </author>
            <summary type="text">What a pain. Getting mysql to work with python is the single most annoying step in getting Django up and running (if you choose MySQL as the database). You...</summary>
            <content type="html" xml:base="http://friendlybit.com/tutorial/install-mysql-python-on-mac-os-x-leopard/">
                &lt;p&gt;What a pain. Getting mysql to work with python is the single most annoying step in getting Django up and running (if you choose MySQL as the database). You see, python requires drivers to be able to talk to MySQL, and you have to compile those yourself. I just devoted several hours last night to help friends do what I did some months ago. This time, I thought I document it right here.&lt;/p&gt;
&lt;h2 id=&#34;how-to-install-mysql-python-on-mac-os-x&#34;&gt;How to install MySQL-python on Mac OS X&lt;a href=&#34;#how-to-install-mysql-python-on-mac-os-x&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;&lt;strong&gt;Step 1&lt;/strong&gt;: &lt;strong&gt;Brace yourself&lt;/strong&gt;, this proccess is really really annoying.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Step 2&lt;/strong&gt;: &lt;a href=&#34;http://dev.mysql.com/downloads/mysql/5.0.html#macosx-dmg&#34;&gt;&lt;strong&gt;Download MySQL&lt;/strong&gt; for Mac&lt;/a&gt; (Skip registration by clicking the link below the login form). You probably want &amp;quot;&lt;a href=&#34;http://dev.mysql.com/get/Downloads/MySQL-5.0/mysql-5.0.67-osx10.5-x86.dmg/from/http://mysql.mirror.kangaroot.net/&#34;&gt;Mac OS X 10.5 (x86)&lt;/a&gt;&amp;quot;. Is it possible to use some other version of MySQL? Yes, as long as you have a version that includes the source code (&lt;a href=&#34;http://www.mamp.info/en/mamp.html&#34;&gt;MAMP&lt;/a&gt; does not include them, so it won&#39;t work). You&#39;ll need the source later on.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Step 3&lt;/strong&gt;: &lt;strong&gt;Install MySQL&lt;/strong&gt; by mounting the image you just downloaded, and double-clicking the package file for MySQL. Also install the prefPane that&#39;s included in the package. That adds an icon the system admin that lets you start and stop MySQL, very convenient.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Step 4&lt;/strong&gt;: &lt;strong&gt;Make the mysql command accessible from anywhere&lt;/strong&gt; by adding it to your PATH (a variable that holds all directories the terminal looks in to find the command you&#39;re trying to execute). The below just adds mysql&#39;s bin directory (it&#39;s probably the one I&#39;m using below) to the PATH you currently are using:&lt;/p&gt;
&lt;div class=&#34;highlight&#34; data-language=&#34;BASH&#34;&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;span class=&#34;nb&#34;&gt;export&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;nv&#34;&gt;PATH&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;/usr/local/mysql/bin:&lt;span class=&#34;nv&#34;&gt;$PATH&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;p&gt;You probably want to add this line to a file called &lt;strong&gt;.bash_profile&lt;/strong&gt; (yes, it starts with a dot), that is situated in your home directory (which you get to by just typing &amp;quot;cd&amp;quot;). This file gets run each time you start a new terminal, so it makes sure the mysql command is always accessible, no matter where you are.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Step 5&lt;/strong&gt;: &lt;strong&gt;&lt;a href=&#34;https://sourceforge.net/project/showfiles.php?group_id=22307&amp;amp;package_id=15775&#34;&gt;Download MySQL-python&lt;/a&gt;&lt;/strong&gt;, you probably want the file that ends with .&lt;strong&gt;tar.gz&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Step 6&lt;/strong&gt;: &lt;strong&gt;Unpack the file&lt;/strong&gt; you just downloaded in an empty directory (anywhere)&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Step 7&lt;/strong&gt;: &lt;strong&gt;&lt;a href=&#34;http://developer.apple.com/technology/xcode.html&#34;&gt;Download XCode&lt;/a&gt;&lt;/strong&gt; from Apple. The reason you need this is because XCode includes a C++ compiler you will use when installing MySQL-python soon. The download is huge (1 Gb), and to be able to download you first need to fill in a long form. The registration process for Apple Developer Connection is about the worst things Apple has ever created, so after completing it, you will either laugh or be really annoyed, just pick and choose. You do need XCode however.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Step 8&lt;/strong&gt;: &lt;strong&gt;Install the XCode Tools&lt;/strong&gt; &lt;strong&gt;package&lt;/strong&gt; by first mounting the file you just downloaded, and then double-clicking on the &lt;strong&gt;XCode Tools&lt;/strong&gt; package. It&#39;s the only one you need from the huge set of junk you just downloaded.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Step 9&lt;/strong&gt;: Try installing MySQL-python by going to the directory where you unpacked it and typing:&lt;/p&gt;
&lt;div class=&#34;highlight&#34; data-language=&#34;BASH&#34;&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;python&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;setup.py&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;install
&lt;/pre&gt;&lt;/div&gt;
&lt;p&gt;This will attempt to install the drivers, but &lt;strong&gt;will fail&lt;/strong&gt;. This is because the coders behind MySQL-python have failed to fix a very simple bug in types.h (&lt;a href=&#34;https://sourceforge.net/tracker/?func=detail&amp;amp;aid=1808476&amp;amp;group_id=22307&amp;amp;atid=374932&#34;&gt;1808476&lt;/a&gt; - &amp;quot;#define of uint breaks compiling on Mac OS X 10.5&amp;quot;). However, you can easily fix it yourself: Look for a reference to types.h in the terminal. When you find it, open that file in your favorite text editor and comment out line 92, which should say something about &lt;code&gt;#define&lt;/code&gt; and &lt;code&gt;uint&lt;/code&gt; (comments in C++ are double forward slashes: //).&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Step 10&lt;/strong&gt;: Now, &lt;strong&gt;try the above command again&lt;/strong&gt;. It should install fine. If it doesn&#39;t, you will probably find out why by looking in the terminal for errors while compiling.&lt;/p&gt;
&lt;p&gt;What did I say, isn&#39;t this process about 7 steps to long? Well, I hope this little guide helps someone.&lt;/p&gt;

            </content>
        </entry>
    
        <entry>
            <title type="html">Ten commandments of update services</title>
            <link href="http://friendlybit.com/other/ten-commandments-of-update-services/" rel="alternate" type="text/html" title="Ten commandments of update services" />
            <published>2008-09-21T23:10:25+02:00</published>
            <updated>2008-09-21T23:10:25+02:00</updated>
            <id>http://friendlybit.com/other/ten-commandments-of-update-services/</id>
            <author>
                <name>Emil Stenström</name>
            </author>
            <summary type="text">I&#39;m getting increasingly annoyed with update services shipped with popular applications. It&#39;s looks like it&#39;s getting worse and worse, and I think someone...</summary>
            <content type="html" xml:base="http://friendlybit.com/other/ten-commandments-of-update-services/">
                &lt;p&gt;I&#39;m getting increasingly annoyed with update services shipped with popular applications. It&#39;s looks like it&#39;s getting worse and worse, and I think someone should stand up and say &lt;strong&gt;enough is enough&lt;/strong&gt;.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&#34;#adobe&#34;&gt;Adobe Update&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;#google&#34;&gt;Google Update&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;#microsoft&#34;&gt;Microsoft Update&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;#ten&#34;&gt;Ten Commandments of Update Services&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Let me start by showing when updates go wrong:&lt;/p&gt;
&lt;h2 id=&#34;adobe&#34;&gt;Adobe Update&lt;a href=&#34;#adobe&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;&lt;img class=&#34;secondary&#34; src=&#34;/files/post-media/adobe_logo.jpg&#34; alt=&#34;&#34; /&gt;I start Adobe Fireworks because I want to resize an image I have. After it has started and the image has loaded the update service prompts me that there are new updates available. For what? It doesn&#39;t say, so I click more info and get a list of things. Strange: &lt;strong&gt;None of them seem related to Fireworks&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;The update starts, and tells me I &lt;strong&gt;have to close Fireworks&lt;/strong&gt; to complete it. Bah, I just started it! I&#39;m trying to resize an image here, remember? But Ok, this time. Next it tells me to close Firefox. What?! All my precious tabs I&#39;ve saved for later reading! Bitches.&lt;/p&gt;
&lt;p&gt;The download begins, and the &lt;strong&gt;progress window takes focus&lt;/strong&gt; over the other stuff I&#39;m doing while not looking at the progress bar. *Repeated clicking to hide the window*. Then when it&#39;s done it takes focus again, and asks me to click the only button available. GAH?!&lt;/p&gt;
&lt;p&gt;Ok, done. Why was I starting Fireworks again? And hey, what&#39;s those &lt;strong&gt;new PDF icons&lt;/strong&gt; doing in my Links toolbar in Internet Explorer?&lt;/p&gt;
&lt;h2 id=&#34;google&#34;&gt;Google Update&lt;a href=&#34;#google&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;&lt;img class=&#34;secondary&#34; src=&#34;/files/post-media/google-logo.jpg&#34; alt=&#34;&#34; /&gt;Oh, a new web browser: Google Chrome, I surely want to try it out. *Couple of hours of fiddling*. Nah, I still like Firefox more, I&#39;ll go back to using that one. &lt;strong&gt;Wait, what&#39;s that GoogleUpdate.exe process doing there&lt;/strong&gt;? I&#39;ll try closing Chrome. Nope, still there. Ok, I&#39;ll force it to close. Hmm, it restarts after a while. Ok, must be some kind of process that starts with Windows. Ah, registry setting, lets remove that one. *Reboot*. Still there?! Ah, they also installed it as a service. Lets remove that too. Finally!&lt;/p&gt;
&lt;p&gt;What&#39;s that? A new version of Google Gears! *Installing*. Hmm… What&#39;s that GoogleUpdate.exe process doing there? GAH! What were you thinking Google?!&lt;/p&gt;
&lt;h2 id=&#34;microsoft&#34;&gt;Microsoft update&lt;a href=&#34;#microsoft&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;&lt;img class=&#34;secondary&#34; src=&#34;/files/post-media/logo_microsoft_small.gif&#34; alt=&#34;&#34; /&gt;I really should make sure my OS is up to date. Lets go to the windowsupdate website. What? I need to run IE5 or later? Ah, no Firefox support, damn it. Lets switch browser. Ok. Install validation thingie? Ehm… I guess I have no choice. *Waiting*. Ok, now let&#39;s see if there&#39;s some updates, Express or Custom? Custom, of course. *Waiting quite a long time*. Why are you making me look at a progress bar? Ok, no OS upgrades, but there&#39;s some update to Windows Media player. Yeye, I guess it couldn&#39;t do any harm (not that I use that one). Trust ActiveX thingie? Yeye, I know what I&#39;m doing. *Waiting some more, with focus stealing*. &amp;quot;Please restart your computer to complete the installation&amp;quot;. Sigh.&lt;/p&gt;
&lt;p&gt;So why don&#39;t I just use Windows Update program instead? Well, there&#39;s a window that pops up every 5 minutes that remind you that you have to restart the computer. Do you know how annoying that one is? No, it&#39;s MORE annoying than that.&lt;/p&gt;
&lt;h2 id=&#34;ten&#34;&gt;Ten Commandments of Update Services&lt;a href=&#34;#ten&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;So I hope that&#39;s enough evidence that big companies have no idea how do conduct a decent update of their own program. So let me offer some (free of charge) advise:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;If your update is web based, &lt;strong&gt;let me use any modern browser I want&lt;/strong&gt;. Don&#39;t start by getting me annoyed.&lt;/li&gt;
&lt;li&gt;Check for updates &lt;strong&gt;right before the program starts&lt;/strong&gt;. I know that you want me to close the app while it&#39;s being updated, but why on earth do you let me start it then? Lets keep it simple, update before the program starts, and resume starting the app when you&#39;re done.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Don&#39;t leave processes running in the background&lt;/strong&gt; when I close the program. When I close your program, I don&#39;t care about you, or any updates to your program.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Only update the current program&lt;/strong&gt;, not bundled ones. I know you want me to have the latest versions of all your programs, but odds are I don&#39;t even use them. Update those programs when I start them, not now.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Show me what gets updated&lt;/strong&gt;, and if possible link to a change log. If you want me to download 70 Mb you need to first talk me into why I need it. You may want to hide detailed info for inexperienced users, but could you please then remember that I&#39;m not one of those?&lt;/li&gt;
&lt;li&gt;If it&#39;s a tiny update (less than 1 Mb), you can just &lt;strong&gt;go ahead and install right away&lt;/strong&gt;. You don&#39;t even have to prompt me.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Download and install in the background&lt;/strong&gt;, without stealing my focus. If you&#39;re shipping a big pile of fixes (ie. the version I bought was not done), you have to let me do other stuff while you update. Like surfing the web. It&#39;s not Ok it require that I close unrelated programs, sorry.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Never ever touch my browser bookmarks&lt;/strong&gt;. Never add things to the quicklaunch bar. Never make things start automatically unless I&#39;ve told you that&#39;s what I want (why do most people have a Quicktime icon in their systray?). The only way of getting into my bookmarks or my quicklaunch bar is writing a really good application. You can&#39;t force me to like you. The opposite works well though.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Never require me to restart the computer&lt;/strong&gt;. There&#39;s only one exception for when you may: when I&#39;m updating the operating system. No excuses.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;When you&#39;re done&lt;/strong&gt;, just start the program. I don&#39;t want to confirm anything, I want to get to work using your app.&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;(Bonus point from &lt;a href=&#34;#comment-31047&#34;&gt;James Socol&lt;/a&gt; in the comments: 11. &lt;strong&gt;Use incremental downloads&lt;/strong&gt;, so I don&#39;t have to download stuff I already have installed.)&lt;/p&gt;
&lt;p&gt;If you are a software company, and can&#39;t manage the above, just do it the old fashion way: let me manually download a file from your website. That will annoy me much less than a bad automatic process. Or if you want things to be really convenient: &lt;strong&gt;write a web application instead&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;Now get to work. I&#39;ve had it.&lt;/p&gt;

            </content>
        </entry>
    
        <entry>
            <title type="html">Quick Accessibility Testing</title>
            <link href="http://friendlybit.com/tutorial/quick-accessibility-testing/" rel="alternate" type="text/html" title="Quick Accessibility Testing" />
            <published>2007-06-24T21:57:53+02:00</published>
            <updated>2007-06-24T21:57:53+02:00</updated>
            <id>http://friendlybit.com/tutorial/quick-accessibility-testing/</id>
            <author>
                <name>Emil Stenström</name>
            </author>
            <summary type="text">A recent project of mine required me to do a quick review of the accessibility level of a site. Nothing serious, just to show what was possible to test and...</summary>
            <content type="html" xml:base="http://friendlybit.com/tutorial/quick-accessibility-testing/">
                &lt;p&gt;A recent project of mine required me to do a quick review of the accessibility level of a site. Nothing serious, just to show what was possible to test and where the site scored right now. I managed to assemble a small list of tools that I believe did a rather good job. This article is a list of those tools, and some tips on how to use them.&lt;/p&gt;
&lt;p&gt;First off, to do a real accessibility test, you need real people, with real tasks to accomplish. These are not tools to replace people. Instead, they can give you a quick rundown on where you stand, and find things you&#39;ve missed. I like to compare it with HTML validation: Validation is a great way to find your errors, but just because you validate does not mean you have good code.&lt;/p&gt;
&lt;p&gt;Oh, by the way, I limited this to only free tools. Thought you&#39;d like that. Also, for your enjoyment, I&#39;ve split this article into three parts (you&#39;re just soooo spoiled):&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&#34;#auto&#34;&gt;Automatic testing&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;#semi&#34;&gt;Semi-automatic testing&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;#manual&#34;&gt;Manual testing&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;h2 id=&#34;auto&#34;&gt;Automatic testing&lt;a href=&#34;#auto&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;Automatic testing is one of the quickest way you can check your site&#39;s accessibility. What the authors of the below tools have done is to go through the available standards, and tried to find things that a computer can check. The tools will not find every error, but the things they do find, they find quickly. This is why I like to start with these.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;&lt;a href=&#34;http://validator.w3.org/&#34;&gt;W3C Markup Validation Service&lt;/a&gt;&lt;/strong&gt; - This is a real classic. It goes through your HTML or XHTML and makes sure you follow the basic syntactic rules. What does this have to do with accessibility? Well, if you deliver invalid code, you have no chance but to test every user agent and how it renders your page. Will you do that? Didn&#39;t think so.&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Bonus #1&lt;/strong&gt;: Test up to 100 pages of your site at once with the &lt;a href=&#34;http://htmlhelp.com/tools/validator/&#34;&gt;WDG HTML Validator&lt;/a&gt;, just check &amp;quot;Validate entire site&amp;quot; before you validate.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Bonus #2&lt;/strong&gt;: As a developer it&#39;s handy to get to know directly if the page you&#39;re looking at validates or not. &lt;a href=&#34;http://users.skynet.be/mgueury/mozilla/&#34;&gt;HTML Validator for Firefox&lt;/a&gt; is an extension that sits in your browser&#39;s status bar, and shows a red cross when something is wrong. When you double click the icon it shows you the exact error. Very handy.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;&lt;a href=&#34;http://jigsaw.w3.org/css-validator/&#34;&gt;W3C CSS Validation Service&lt;/a&gt;&lt;/strong&gt; - Even though screen readers don&#39;t care much about the CSS you need to make sure it&#39;s alright. Why? Because there&#39;s more to accessibility than screen readers. Surely, most people that need your help are people surfing with their ordinary browsers: Internet Explorer, Firefox, and so on. To make sure all of them see the content and can interact with it, check your CSS for obvious errors automatically.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;&lt;a href=&#34;http://www.cynthiasays.com/&#34;&gt;Cynthia Says&lt;/a&gt;&lt;/strong&gt;, &lt;strong&gt;WebXACT&lt;/strong&gt;, and &lt;strong&gt;Wave Accessibility Tool&lt;/strong&gt; are all testing tools that are aimed at accessibility testing. They support both Section 508 (an American accessibility standard) and WCAG 1.0 (W3C&#39;s own standard). Like the W3C tools above they do not catch all errors, in fact, most of the feedback you get is that you should check things manually. None the less, they often find simple errors that you have missed. Make sure you enable all extra options when using them.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Basic accessibility analyzer&lt;/strong&gt; is a much less known, but very impressive accessibility tester. Among other things it adds checks for proper heading structure and form labels, two things many have problems getting right. Built by Peter Krantz (former colleague of mine) and based on his &lt;a href=&#34;http://www.peterkrantz.com/raakt/wiki/&#34;&gt;accessibility library&lt;/a&gt; for Ruby).&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;&lt;a href=&#34;http://validator.w3.org/checklink&#34;&gt;W3C Link Checker&lt;/a&gt;&lt;/strong&gt; is another tool that&#39;s easy to forget about. It walks through your site and picks out all the links it finds, checking that each of them works. Using a tool like this makes sense for more than accessibility reasons, but accessibility alone is a reason to use it.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;&lt;a href=&#34;http://juicystudio.com/services.php#hosted&#34;&gt;Juicy Studio&lt;/a&gt;&lt;/strong&gt; hosts a whole series of useful online automatic tools. There&#39;s tests for Readability, Your CSS file, Luminosity and Color Contrast (really useful), and an Image tester. You will most certainly find something to improve here.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;&lt;a href=&#34;http://nikitathespider.com/&#34;&gt;Nikita the spider&lt;/a&gt;&lt;/strong&gt; is a great tool going through a lot of pages in search for errors. It crawls through a site and reports broken links, missing doctypes, and validation errors. Good for big batch checks after the fact.&lt;/li&gt;
&lt;/ul&gt;
&lt;h2 id=&#34;semi&#34;&gt;Semi-automatic testing&lt;a href=&#34;#semi&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;Semi-automatic tools do part of the work for you but also requires that you twiddle with the results yourself. They can&#39;t give you a &amp;quot;passed validation&amp;quot; stamp to put on your site, but correctly used they can give you deeper knowledge than the automatic ones.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;&lt;a href=&#34;http://www.visionaustralia.org.au/ais/toolbar/&#34;&gt;Accessibility Toolbar&lt;/a&gt;&lt;/strong&gt; for Internet Explorer is a collection of accessibility tools bundled as a toolbar. The best part of it is it&#39;s support for color and contrast testing. Click &amp;quot;Colour -&amp;gt; Contrast Analyzer [application]&amp;quot;. By selecting &amp;quot;Simulation&amp;quot; from the menu you can see what your site looks like with different vision impairments. If you rely on color alone for some feature it will be obvious with some testing with this tool.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;&lt;a href=&#34;http://www.standards-schmandards.com/projects/fangs&#34;&gt;Fangs&lt;/a&gt;&lt;/strong&gt; is a screen reader simulator in the form of a Firefox plugin. It&#39;s simply shows (not reads) the text on a page as it would be read by a screen reader. This is a great way to get a feel of how your site works with non-visual browsers. Due to a bug in Firefox you need to run an English version of the browser before installing Fangs. It&#39;s worth switching language to run Fangs, it helps that much.&lt;/li&gt;
&lt;/ul&gt;
&lt;h2 id=&#34;manual&#34;&gt;Manual testing&lt;a href=&#34;#manual&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;Then we have the old fashioned gruntwork, manual testing. I&#39;m going to put things here that you don&#39;t use special tools for, just the browser and your accessibility knowledge.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Testing in several browsers&lt;/strong&gt; is of course the most obvious way to test a site. If 10% of your users can&#39;t access the site because it doesn&#39;t work in Firefox you have a problem. So fire up both versions of Internet Explorer (6 and 7, not 5.5, it&#39;s dead), the latest version of Firefox and Opera. If you have access to a Mac make sure it works on Safari there too. If not you have to try with the buggy &lt;a href=&#34;/other/safari-now-available-on-windows/&#34;&gt;Safari 3 beta for Windows&lt;/a&gt; (it&#39;s better than nothing).&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Text zoom&lt;/strong&gt; is one of the first things you should try. Firefox and Internet Explorer 6 relies on only enlarging the text, and not the whole window, so make sure you test that. Internet Explorer refuses to zoom text set in pixels, so keep a lookout for that. Text zoom helped me greatly when my old monitor broke and got all blurry. Thanks for letting me zoom!&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Turning off CSS and Javascript&lt;/strong&gt; is another great way to make sure people can access your content. You don&#39;t need to mind what the content &lt;em&gt;looks like&lt;/em&gt;, just make sure it&#39;s understandable and that things work as expected.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Remove images&lt;/strong&gt; and replace them with alt text. There&#39;s options to do this with both &lt;a href=&#34;http://chrispederick.com/work/web-developer/&#34;&gt;Web Developer Toolbar&lt;/a&gt; and the previously mentioned Accessibility Toolbar. Testing your image alternatives helps both people that gets their content read to them and those that disable image loading due to a slow dialup connection.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Keyboard navigation&lt;/strong&gt; is another thing to test. Just push your mouse to the side and navigate using only the keyboard (use the tab-key, arrows and enter). Does things work like you expect? Good, you passed.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;That&#39;s it. Lots of little tools and tricks you can use to make your site accessible to more people. If you ask &lt;a href=&#34;http://www.useit.com/alertbox/&#34;&gt;Jakob Nielsen&lt;/a&gt; or &lt;a href=&#34;http://www.456bereastreet.com/&#34;&gt;Roger Johansson&lt;/a&gt; if this is enough they will of course say no, but I say you should be proud anyway! Passing most of the above tests isn&#39;t easy, and you&#39;re certainly on the right track now. Well done!&lt;/p&gt;
&lt;p&gt;Feel free to tip me off on more tools using the comments. Thanks for reading!&lt;/p&gt;

            </content>
        </entry>
    
        <entry>
            <title type="html">What is Web 2.0? Really.</title>
            <link href="http://friendlybit.com/js/what-is-web-20-really/" rel="alternate" type="text/html" title="What is Web 2.0? Really." />
            <published>2007-03-10T00:59:52+01:00</published>
            <updated>2007-03-10T00:59:52+01:00</updated>
            <id>http://friendlybit.com/js/what-is-web-20-really/</id>
            <author>
                <name>Emil Stenström</name>
            </author>
            <summary type="text">Web 2.0 is really hot right now. One of Sweden&#39;s biggest newspapers recently wrote a long article on their debate section. They had started linking back to...</summary>
            <content type="html" xml:base="http://friendlybit.com/js/what-is-web-20-really/">
                &lt;p&gt;Web 2.0 is really hot right now. One of Sweden&#39;s biggest newspapers recently wrote a long article on their debate section. They had started linking back to blogs that linked to them, in a little box next to the article. The problem was that they had got into trouble with what blogs to link to. After all, you can&#39;t just link to anything, right?&lt;/p&gt;
&lt;p&gt;Aside from starting to think about the implications of blog links, I got another interesting question in my head. What is Web 2.0 really? Most people working with interface development would say that Web 2.0 is everything that uses AJAX. But the newspaper didn&#39;t use AJAX at all, and still they claim links to blogs is Web 2.0. Time for some research!&lt;/p&gt;
&lt;h2 id=&#34;the-hunt-for-a-definition&#34;&gt;The hunt for a definition&lt;a href=&#34;#the-hunt-for-a-definition&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;The phrase &amp;quot;Web 2.0&amp;quot; was first put into widespread use at an O&#39;Reilly conference in 2004. The organizers wanted to talk about a change that has happened on the web, and just bumping the version of the web seemed like a good idea. Paul Graham found this &lt;a href=&#34;http://www.paulgraham.com/web20.html#f1n&#34;&gt;first try at defining Web 2.0&lt;/a&gt; at the conference:&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;&amp;quot;While the first wave of the Web was closely tied to the browser, the second wave extends applications across the web and enables a new generation of services and business opportunities.&amp;quot;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;Note that there&#39;s no mention of AJAX there. Hell, there&#39;s no mention of users either! They must have meant something else, and the definition might have changed over the years since then. Let&#39;s keep looking for a good definition.&lt;/p&gt;
&lt;p&gt;Tim O&#39;Reilly comments on the issue two years later, in a &lt;a href=&#34;http://radar.oreilly.com/archives/2006/12/web_20_compact.html&#34;&gt;clarification on his blog&lt;/a&gt;:&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;Web 2.0 is the business revolution in the computer industry caused by the move to the internet as platform, and an attempt to understand the rules for success on that new platform. Chief among those rules is this: Build applications that harness network effects to get better the more people use them.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;Tim acknowledges the change in meaning and talks about &amp;quot;network effects&amp;quot; here, something that starts to look a little bit more like what my idea of Web 2.0 is. But isn&#39;t there still something missing? To me, that looks only like a small part of what I call Web 2.0. Let&#39;s keep looking…&lt;/p&gt;
&lt;p&gt;Gartner has tried to convince companies of the merits of Web 2.0 for a rather long time. In one of their many (business oriented) PowerPoint presentations they attempt to define &amp;quot;three anchor points around Web 2.0&amp;quot;:&lt;/p&gt;
&lt;blockquote&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Technology and Architecture&lt;/strong&gt; — Consisting of Web-oriented architecture (WOA) and Web platforms.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Community&lt;/strong&gt; — Looks at the dynamics around social networks and other personal content public/shared models, wiki and other collaborative content models.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Business Model&lt;/strong&gt; — Web service-enabled business models, mashup/remix applications and so forth.&lt;/li&gt;
&lt;/ul&gt;
&lt;/blockquote&gt;
&lt;p&gt;I believe we&#39;re getting closer. Gartner is making business models a separate point which I don&#39;t agree with. Many of the biggest Web 2.0 sites didn&#39;t have a business model when they started (and many still don&#39;t). Digg has troubles covering their hosting cost with the tiny bit of money they acquire from their ads. Del.icio.us still doesn&#39;t make any direct money (although they got sold to Yahoo, and they surely use the data…). My point is, a business plan isn&#39;t one third of Web 2.0, it&#39;s something sites add afterwards if things work out.&lt;/p&gt;
&lt;p&gt;So let me state my own (slightly more general) definition of Web 2.0:&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;&amp;quot;A collection of ideas and techniques that can be used to make more interactive sites&amp;quot;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;The thing is, just doing something in AJAX does not mean it gets the Web 2.0 stamp of approval. You need several of the ideas or techniques and you need to combine them in clever ways. So lets agree on the definition above and got look for ideas.&lt;/p&gt;
&lt;h2 id=&#34;ideas-that-are-part-of-web-20&#34;&gt;Ideas that are part of Web 2.0&lt;a href=&#34;#ideas-that-are-part-of-web-20&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;I&#39;d like to gather a whole bunch of ideas under the Web 2.0 roof. My selection is of course not all there is. Googling could uncover more I&#39;m sure, but I think this is a good start.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&#34;#generated&#34;&gt;User generated content&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;#trust&#34;&gt;Radical trust&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;#syndication&#34;&gt;Syndication of content and services&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;#tail&#34;&gt;Long tail&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;#collective&#34;&gt;Collective intelligence&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;h3 id=&#34;generated&#34;&gt;User generated Content&lt;a href=&#34;#generated&#34;&gt;#&lt;/a&gt;&lt;/h3&gt;
&lt;p&gt;Many companies still view the web as a one-way medium, an extension of a paper catalog, it&#39;s main advantage being that it can be distributed to more people. It&#39;s not like that any more! There are people that want to add content to your site, that want to contribute their ideas and thoughts. Why are you denying them to help you?&lt;/p&gt;
&lt;p&gt;User generated content is content that your users are willing to give you. It can be everything from a simple &amp;quot;like it&amp;quot; or &amp;quot;don&#39;t like it&amp;quot;, to fully featured articles written by users. The two most used ways of contributions are the simple ones: votes and comments. The author is still in full control of the content but users are given a chance to chip in with minor corrections. This is the least you can do. It&#39;s what I do on this blog; let you chip in by commenting.&lt;/p&gt;
&lt;p&gt;But if you have users that are passionate about your subject, users that are willing to use your site to get their ideas out, you should really endorse that! Allow them to post articles on your site, allow them to regroup and re-prioritize according to their own wishes. It is technically possible, even rather easy to do; you just have to do it.&lt;/p&gt;
&lt;p&gt;Six simple things your users can help you with:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Reviews of your products&lt;/li&gt;
&lt;li&gt;Comments on your articles&lt;/li&gt;
&lt;li&gt;Stories about how people use your product&lt;/li&gt;
&lt;li&gt;Multimedia using your product&lt;/li&gt;
&lt;li&gt;Questions about your products&lt;/li&gt;
&lt;li&gt;Articles in an area you choose&lt;/li&gt;
&lt;/ul&gt;
&lt;h3 id=&#34;trust&#34;&gt;Radical trust&lt;a href=&#34;#trust&#34;&gt;#&lt;/a&gt;&lt;/h3&gt;
&lt;p&gt;&lt;img class=&#34;secondary&#34; src=&#34;/files/web20/wikipedia.png&#34; alt=&#34;Logotype of Wikipedia&#34; /&gt;&lt;/p&gt;
&lt;p&gt;Another approach many sites have taken can be summarized as &amp;quot;radical trust&amp;quot;. It builds on the simple idea that users know what they want better than you do. So let them order, categorize, sort, select your data as they like!&lt;/p&gt;
&lt;p&gt;This is exactly what wikis do. They acknowledge that there are more users doing good than doing bad. If that&#39;s the case, why not let them in on your content directly, letting them edit and improve it like they want. They few people that do bad can be hunted away with a combination with versioning (saving old versions of content that&#39;s easy to restore), and some simple monitoring. Wikis trust users, do you?&lt;/p&gt;
&lt;h3 id=&#34;syndication&#34;&gt;Syndication of content and services&lt;a href=&#34;#syndication&#34;&gt;#&lt;/a&gt;&lt;/h3&gt;
&lt;p&gt;Web 2.0 is not only about &amp;quot;user to website&amp;quot; interactivity. It&#39;s also about letting other sites and tools interact with your site directly. This is often summarized as &amp;quot;syndication&amp;quot;.&lt;/p&gt;
&lt;p&gt;It&#39;s a very fancy word for a simple concept. Let me try to explain.&lt;/p&gt;
&lt;p&gt;Somewhere you have some kind of database with your content, be it products in your e-store or posts on your blog. Usually you take that content, add some structure (HTML) to it, and send it to the user.&lt;/p&gt;
&lt;p&gt;Another website that wants to access the same information could parse the HTML and try to understand what it means, something called &amp;quot;screen scraping&amp;quot; (or microformats ;). The problem with that method is that it&#39;s very dependent on that the webmaster doesn&#39;t decide to change the HTML. The other problem is that computers and humans often want different types of information. A computer that is going to parse a list of your products doesn&#39;t need navigation like humans do. What you do is send your data directly to computers instead, without messing it up with HTML. Formats include: RDF, RSS, or perhaps custom XML through a Web Service.&lt;/p&gt;
&lt;p&gt;Thing is, when you start syndicating your data you make it easier for others build services based on it. Now people get several entrances into your content instead of the one you produced. Again, your users are helping you reach more people.&lt;/p&gt;
&lt;p&gt;Allowing full RSS feeds is another way of syndicating, I&#39;m switching right now. Do you syndicate?&lt;/p&gt;
&lt;h3 id=&#34;tail&#34;&gt;Long tail&lt;a href=&#34;#tail&#34;&gt;#&lt;/a&gt;&lt;/h3&gt;
&lt;p&gt;&lt;img class=&#34;secondary&#34; src=&#34;/files/web20/tail.png&#34; alt=&#34;Graph of a sold units per item&#34; /&gt;&lt;/p&gt;
&lt;p&gt;The theory of the long tail is one of the ideas that are usually associated with Web 2.0. It&#39;s a business model that many companies that are successful on the web use. As with most business models they are invented after the fact, and as such I&#39;m not sure it really belongs on this list, but people always bring it up, so let’s go. I&#39;ll let you choose yourself.&lt;/p&gt;
&lt;p&gt;Wikipedia describes the long tail like this:&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;&amp;quot;Products that are in low demand […] can collectively make up a market share that rivals or exceeds the relatively few current bestsellers and blockbusters, if the store or distribution channel is large enough&amp;quot;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;Most physical stores need to aim for the bestsellers to sell anything. There&#39;s simply too few interested in odd products, to make it worth hiring store space and personnel to sell it.&lt;/p&gt;
&lt;p&gt;Web based stores are in a different position. Selling another product usually means just adding another page to your site, no extra store space or personnel needed. In addition people are prepared to wait a couple of days before receiving their products. That time span means you can skip warehouses and not start producing your products until you have an order ready.&lt;/p&gt;
&lt;p&gt;No more is there a need to estimate what people will be interested in and pre-order them. For the right kind of product the internet is a huge benefit. Amazon did it with books, iTunes did it with music, do you do it?&lt;/p&gt;
&lt;h3 id=&#34;collective&#34;&gt;Collective intelligence&lt;a href=&#34;#collective&#34;&gt;#&lt;/a&gt;&lt;/h3&gt;
&lt;p&gt;You have let each user customize their experience and add content of their own. Now it&#39;s time to organize that content to better help the everyone benefit from it. There&#39;s hundreds of ways of doing it, but here&#39;s a couple of things that you can present to your users:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;The most popular Swedish article right now…&lt;/strong&gt; - Crawl all Swedish blogs and keep track of what they link to.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Others that bought this book also bought…&lt;/strong&gt; - Query your shipment table. Pick a product, select the number of times each other product appeared together with said product, and recommend that product to your customers. Amazon does this and it&#39;s said that it has increased their profits considerably.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;You probably think this movie is a four out of five&lt;/strong&gt; - A Swedish movie site give its users personalized ratings of movies. They find users that have similar taste as you have (based on your previous grades) and then checks what those people have rated the movie as.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;This is probably spam&lt;/strong&gt; - Write a word filter that learns what is considered spam when users mark them. Share that filter with fellow users and let their markings stop your spam. A form of collective sieve filtering, Akismet does this.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;None of them are technologically hard to do, you just Google and copy other people&#39;s samples. Why not?&lt;/p&gt;
&lt;h2 id=&#34;techniques-involved-in-web-20&#34;&gt;Techniques involved in Web 2.0&lt;a href=&#34;#techniques-involved-in-web-20&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;But there are techniques involved too. Let&#39;s go through a few of the important ones.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&#34;#ajax&#34;&gt;AJAX (and other javascript)&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;#feeds&#34;&gt;Feeds (RSS, Atom)&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;#tags&#34;&gt;Tags&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;h3 id=&#34;ajax&#34;&gt;AJAX (and other javascript)&lt;a href=&#34;#ajax&#34;&gt;#&lt;/a&gt;&lt;/h3&gt;
&lt;p&gt;Everyone talks about AJAX together with Web 2.0, but I think it&#39;s important they are kept separate.&lt;/p&gt;
&lt;p&gt;AJAX is just a technology that helps prevent (full) page reloads. Instead you connect to the server silently in the background and receive your data that way. What&#39;s the revolutionary about this technique? Nothing. It has been in use for at least 5 years. They new thing about it is that people started using it to build better interfaces.&lt;/p&gt;
&lt;p&gt;Javascript is language that enables AJAX, and playing with reloads is not all it can do. Through some nifty use you can change attributes on any HTML element on the page. Move things around, react to mouse movement, fade and animate, it&#39;s your choice. This means a lot of new controls become possible, ranging from simple sliders to interactive maps.&lt;/p&gt;
&lt;p&gt;Why do most accessibility people hate it? Because most developers don&#39;t know enough about accessibility. And when those start to use AJAX they disregard accessibility completely. Javascript and AJAX have different goals and I think a good compromise is making sure the basic functions of the site (buy a product and pay for it) works without javascript, but enabling it adds additional features.&lt;/p&gt;
&lt;p&gt;When was the last time you used javascript to enhance your site? What was the last control you invented?&lt;/p&gt;
&lt;h3 id=&#34;feeds&#34;&gt;Feeds (RSS, Atom)&lt;a href=&#34;#feeds&#34;&gt;#&lt;/a&gt;&lt;/h3&gt;
&lt;p&gt;&lt;img class=&#34;secondary&#34; src=&#34;/files/web20/feeds.png&#34; alt=&#34;The official feed icon&#34; /&gt;&lt;/p&gt;
&lt;p&gt;Feeds are great for syndication of content. There are many different feed formats to choose from but they all have one purpose: to communicate pure data, skipping all design.&lt;/p&gt;
&lt;p&gt;A feed is simply a list of feed items, each with an unique identifier. A user adds the address to their &amp;quot;feed reader&amp;quot; and it starts polling you, asking for updates. I have my reader set to just a couple of minutes, making sure I quickly notice changes in people&#39;s feeds.&lt;/p&gt;
&lt;p&gt;The good thing about feeds is that they make it easy to follow several at once. There&#39;s no annoying different designs in the way if you don&#39;t want to (you can always just visit the site if you want design). Feeds are getting more and more of a commodity; you should already be allowing your users the possibility to subscribe your content. Do you?&lt;/p&gt;
&lt;h3 id=&#34;tags&#34;&gt;Tags&lt;a href=&#34;#tags&#34;&gt;#&lt;/a&gt;&lt;/h3&gt;
&lt;p&gt;Tags is another hip concept. It deals with the collective intelligence idea and how to categorize content efficiently. A tag consists of a phrase of some kind that describes a piece of content. This blog post could have the tag &amp;quot;javascript&amp;quot;.&lt;/p&gt;
&lt;p&gt;There&#39;s several ways you can use them. One is the just fix what tags are allowed and use them as regularly groups you can assign content to. But allowing more than one tag enable you to do more than just split things into groups, you can instead pick all contents bits that have the same tag. You can go further, allowing custom tags that the users can pick themselves. That gives you a wide array of descriptive words for your content, free to play around with. For example, if many users pick the same word, that one is probably a better descriptor.&lt;/p&gt;
&lt;p&gt;Picking many bits of content and analyzing all tags tied to them can be easily done with a tag cloud. In that you simply print all tags used after each other, and make those used often bigger. Doing this on a whole site is an effective way of giving users a snapshot of what you write about, something I know I like.&lt;/p&gt;
&lt;p&gt;Can tags help you solve a categorization problem you have?&lt;/p&gt;
&lt;h2 id=&#34;summary&#34;&gt;Summary&lt;a href=&#34;#summary&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;Now. To build a Web 2.0 site, pick from both of the lists above. You Google for more ideas and you work hard to interact with your users as much as possible. Web 2.0 is the combination that happens when your ideas and technology finally just works.&lt;/p&gt;
&lt;p&gt;Your users want to help you, do you let them in?&lt;/p&gt;

            </content>
        </entry>
    
        <entry>
            <title type="html">Click here to read this article</title>
            <link href="http://friendlybit.com/other/click-here-to-read-this-article/" rel="alternate" type="text/html" title="Click here to read this article" />
            <published>2006-10-19T00:25:28+02:00</published>
            <updated>2006-10-19T00:25:28+02:00</updated>
            <id>http://friendlybit.com/other/click-here-to-read-this-article/</id>
            <author>
                <name>Emil Stenström</name>
            </author>
            <summary type="text">No matter where you go on the web today you see those little anonymous links: &#34;click here)&#34;. You clearly see them, often marked with a different color...</summary>
            <content type="html" xml:base="http://friendlybit.com/other/click-here-to-read-this-article/">
                &lt;p&gt;No matter where you go on the web today you see those little anonymous links: &amp;quot;&lt;a href=&#34;#harmful-link&#34;&gt;click here&lt;/a&gt;)&amp;quot;. You clearly see them, often marked with a different color (links as they are), but you don&#39;t immediately see where they go. Instead you need to read the text before, no wait, after, Oh! That&#39;s a nice image up there? Hmm… What was I looking for again?&lt;/p&gt;
&lt;p&gt;It has been said over and over again; very few people actually read full articles unless they know it&#39;s worth it. It&#39;s all about trust. They must have previously gotten the idea that the article they are about to read is on topic, interesting, worth a read. It&#39;s a tricky situation, before they have read the article they need to somehow already know that they are on the right track. The solution is of course good links.&lt;/p&gt;
&lt;p&gt;A link tells you something about the page you&#39;re about to visit. You get a quick two or three word summary, often from an author you have previously deemed trustworthy (after all, you&#39;re reading her/his site are you not?). When you are on a trusted site and click on a link you know that the destination is a good one. Why would there be a link there otherwise? You also know roughly what the site is about, it&#39;s summarized and underlined in blue right there. You click and you start reading.&lt;/p&gt;
&lt;p&gt;Instead of the above scenario I see the same problem repeated over and over again. Instead of using good link text people use &amp;quot;click here&amp;quot; to name their links. You force me to read a lot more than I should need to. &lt;strong&gt;Damn you!&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;But not only do you annoy your users. Search engines use link text as a primary source of information about the site linked to. Who wants to be found on Google only by those that search for &amp;quot;click here&amp;quot;? Sure, Google sometimes act like a persistent human and reads the surrounding text too, but it also values those words less. What? I can&#39;t use Google to find you? &lt;strong&gt;Damn you!&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;Many screen readers have an option to only show the links for a site. This is a useful feature if you are browsing, navigating, searching for something, but know it&#39;s not on the current page. Since screen reader users are dependent on hearing things they navigate much slower than an average user and all ways of speeding up that process helps. On a page with the usual &amp;quot;click here&amp;quot; links, the generated list will be useless. The links are taken out of context and users are forced to read the whole site to see where a certain link goes. Why are you punishing them when it&#39;s so easy to do it the right way? &lt;strong&gt;Damn you!&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;Sometimes the existence of “click here” links has to do with design. It&#39;s very popular right now to remove the underlining on links. This makes links harder to see and you need other methods to show the user where to click. One of them is telling the user what to do in text instead: &amp;quot;I want you to buy my product, but you can&#39;t by clicking directly, you need to click here&amp;quot;. &amp;quot;Click me&amp;quot; designers: &lt;strong&gt;Damn you!&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;And it&#39;s so easy.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;Link with the words that best describe the content you link to.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;Now. No one is going to do funny things with their comment signatures or trackbacks will they?&lt;/p&gt;

            </content>
        </entry>
    
        <entry>
            <title type="html">Judging the technical quality of a site</title>
            <link href="http://friendlybit.com/tutorial/judging-the-technical-quality-of-a-site/" rel="alternate" type="text/html" title="Judging the technical quality of a site" />
            <published>2006-10-01T00:28:08+02:00</published>
            <updated>2006-10-01T00:28:08+02:00</updated>
            <id>http://friendlybit.com/tutorial/judging-the-technical-quality-of-a-site/</id>
            <author>
                <name>Emil Stenström</name>
            </author>
            <summary type="text">When you look at a website to determine its quality on the code level, you need a different set of metrics than you did some years ago. This article is my...</summary>
            <content type="html" xml:base="http://friendlybit.com/tutorial/judging-the-technical-quality-of-a-site/">
                &lt;p&gt;When you look at a website to determine its quality on the code level, you need a different set of metrics than you did some years ago. This article is my attempt at specifying what metrics I use. Have a look at them, do they match yours?&lt;/p&gt;
&lt;p&gt;First I look at the &lt;strong&gt;validation&lt;/strong&gt;. Does the front page validate? Do all sub pages of the site validate? If they don’t, what kind of errors are there? While validation isn’t the most important metric, it’s a very quick way to get a feeling of if the coder is “web standards aware” or not. I use the &lt;a href=&#34;http://users.skynet.be/mgueury/mozilla/&#34;&gt;Firefox validation plugin&lt;/a&gt; that checks all the pages I visit and puts a little green check in the statusbar if the current page validates. For doing sitewide validation I use &lt;a href=&#34;http://www.htmlhelp.com/tools/validator/&#34;&gt;htmlhelp’s validation spider&lt;/a&gt; and let it loose on the site (check &amp;quot;Validate entire site&amp;quot;). Validation is slowly catching on as a standard tool in the webdev toolbox. Someone who is not using the validator probably doesn&#39;t know much about web standards.&lt;/p&gt;
&lt;p&gt;While on the subject of validation: don’t forget &lt;strong&gt;validating the CSS&lt;/strong&gt;. There’s a lot of basic errors that the validator finds that only leads to errors in some browsers. The W3C CSS validator might help you fix some of those right away. Before you complain: the CSS validator has a few issues. If you use line-height, you need pass it a decimal number; 1 becomes 1.0, 0 becomes 0.0. Secondly, if you use CSS 2.1 or CSS 3 properties you need to inform the validator you do. Add the &lt;a href=&#34;http://jigsaw.w3.org/css-validator/validator?uri=http%3A%2F%2Ffriendlybit.com&amp;amp;usermedium=all&amp;amp;profile=css21&#34;&gt;URL parameter “profile”&lt;/a&gt; with the value set to “css21” or “css3”, and revalidate. CSS errors and whether or not the style sheet is &lt;strong&gt;well organized&lt;/strong&gt; clearly propagates what &lt;a href=&#34;/css/levels-of-css-knowledge/&#34;&gt;CSS level&lt;/a&gt; the developer is on.&lt;/p&gt;
&lt;p&gt;Next I look at the &lt;strong&gt;doctype&lt;/strong&gt;. That single line of information at the first line of the HTML that defines what language the coder is using. Use of &lt;a href=&#34;http://accessites.org/gbcms_xml/news_page.php?id=23&#34;&gt;Strict or Transitional&lt;/a&gt; is what matters most. Most pages that validate as transitional can with very small changes be upgraded to strict. And why not? Strict signals that an effort has been made to ensure that the document separates structure from design. If you know how, there’s no reason not to. At this stage I also check that the doctype is properly set, there’s an IE bug that makes IE render things badly (quirks mode) if the doctype isn’t the first element of the page. Incorrect use of doctype is also a common way to recognize a beginner.&lt;/p&gt;
&lt;p&gt;Sites that pass the above code tests get another batch of checks. Is the code &lt;strong&gt;semantic&lt;/strong&gt;? (ie. does the HTML describe the content?) I look at elements, classes, and ids in use. Do they describe the content they contain? Bad sites use class names tied to design. Mediocre sites use general names like “wrapper” or “column2”. Great sites use “copyright”, “invitation”, and “footnote”. Many CMS:es generate design-oriented classes and ids, and only a few reach mediocre. This is one way to see that a site was robot-made.&lt;/p&gt;
&lt;p&gt;Another code issue is the &lt;strong&gt;content over HTML quotient&lt;/strong&gt;. For just a few lines of content you shouldn’t have to need huge amounts of HTML. You shouldn’t need 10 divisions just for one header. A high content over HTML quotient signals that the developer knows what he’s doing. An “overmarked” site means that the developer is on the right track but suddenly forgot that content is more important than the code behind it.&lt;/p&gt;
&lt;p&gt;One last angle is the &lt;strong&gt;accessibility&lt;/strong&gt; one. How will a screen reader read this site? Is all the content of the site available as readable text? Does the site require javascript when it isn’t needed? A good place to see if someone knows about accessibility (on the web) or not is checking the forms. Fieldsets, legends, and labels: they all tell their story about the developer and his knowledge about accessibility.&lt;/p&gt;
&lt;p&gt;A quality site ranks high in all of the above.&lt;/p&gt;

            </content>
        </entry>
    
        <entry>
            <title type="html">Tricks to make your site easier to use</title>
            <link href="http://friendlybit.com/html/make-your-site-easier-to-use/" rel="alternate" type="text/html" title="Tricks to make your site easier to use" />
            <published>2006-08-01T19:17:40+02:00</published>
            <updated>2006-08-01T19:17:40+02:00</updated>
            <id>http://friendlybit.com/html/make-your-site-easier-to-use/</id>
            <author>
                <name>Emil Stenström</name>
            </author>
            <summary type="text">There are lots of little tricks you can use to make your sites easy to use. Problem is that they are so obvious, you don’t think of them. This article is an...</summary>
            <content type="html" xml:base="http://friendlybit.com/html/make-your-site-easier-to-use/">
                &lt;p&gt;There are lots of little tricks you can use to make your sites easy to use. Problem is that they are so obvious, you don’t think of them. This article is an attempt to share some of the ideas that I &lt;em&gt;did&lt;/em&gt; think of. I&#39;m sure I missed some; feel free to add your own tricks in the comments.&lt;/p&gt;
&lt;p&gt;You rarely think of sites as &amp;quot;easy to use&amp;quot;; they just work. You enter them, click here and there, and don&#39;t think much about how the navigation works or what to do. That&#39;s the feeling we should go for.&lt;/p&gt;
&lt;h2 id=&#34;separate-the-interaction-layer&#34;&gt;Separate the interaction layer&lt;a href=&#34;#separate-the-interaction-layer&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;A very simple way of making it easier for your users is clearly marking what can be interacted with. Are users expected to click on those small arrows of yours? Are the only links to your content through your headers? Then you better make sure those arrows or headers come across as clickable.&lt;/p&gt;
&lt;p&gt;The fastest way to convey that something is clickable is using blue underlined text. Why? Because that&#39;s what most sites use (see &lt;a href=&#34;http://www.google.com&#34;&gt;Google&lt;/a&gt;, &lt;a href=&#34;http://www.amazon.com&#34;&gt;Amazon&lt;/a&gt;, &lt;a href=&#34;http://www.ebay.com&#34;&gt;eBay&lt;/a&gt;). It&#39;s what we have grown up with and it just works. Designers tend to dislike blue underlined links and have started to use other colors and skip the underlines. Jakob Nielsen, the notorious usability expert, writes about what you should think of in his &lt;a href=&#34;http://www.useit.com/alertbox/20040510.html&#34;&gt;article about the visual style of links&lt;/a&gt;. It&#39;s a good reminder.&lt;/p&gt;
&lt;p&gt;You don&#39;t have to stop with just the links though. Are your images clickable? Then make sure they connect with your links somehow. If you pick orange as your link color, make something around or in the images use that color too. Make your form fields use the same color. When someone enters your site it should be possible to quickly get an idea of what to do: &amp;quot;I can either click a link in the menu, search for a phrase, or click this thumbnail&amp;quot;. Don&#39;t make people confused by mixing in orange on the static parts of your site.&lt;/p&gt;
&lt;p&gt;With some cleverness I&#39;m sure this idea can be expanded to work even without being dependent on color. A small figure? A border? Use your imagination, and be sure to tell me about it.&lt;/p&gt;
&lt;h2 id=&#34;split-up-your-content&#34;&gt;Split up your content&lt;a href=&#34;#split-up-your-content&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;You know those portal sites? There&#39;s one big reason they don&#39;t work. There&#39;s too much content cramped into a too small area. A portal is rarely about something specific, it&#39;s about everything that they can possibly fit in. Whatever content you are looking for you will have to search hard for it. Do you use the portal parts of Yahoo or MSN? Didn&#39;t think so.&lt;/p&gt;
&lt;p&gt;There has been a long discussion recently about how badly designed pages work better. &lt;a href=&#34;http://www.andyrutledge.com/bad-design.php&#34; title=&#34;Bad design harms business, it does not help it&#34;&gt;Like Andy Rutledge&lt;/a&gt; I mostly disagree but I can understand how bad design works for ad-driven sites. Is the point of your pages to make people click ads? Then make them confused, make them think your navigation is the ads, I&#39;m sure it drives your revenue up. If the point of your site is the content on it, stay away from being a portal.&lt;/p&gt;
&lt;p&gt;The simplest way of avoiding the portal-look is splitting up your content. Do you have info on both crocodiles and stock numbers? Don&#39;t put them on the same page. Make sure only the people interested in stocks get the stock info. Anyone else will just see them as &amp;quot;something I am not looking for&amp;quot;. If you have lots of info from diverse fields, perhaps a &lt;a href=&#34;http://dmoz.org/&#34; rel=&#34;nofollow&#34;&gt;directory&lt;/a&gt; is a better bet?&lt;/p&gt;
&lt;h2 id=&#34;use-codeltlabelgtcode-for-form-elements&#34;&gt;Use &lt;code&gt;&amp;lt;label&amp;gt;&lt;/code&gt; for form elements&lt;a href=&#34;#use-codeltlabelgtcode-for-form-elements&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;Bad form elements are one of the most annoying things on the web. Worst are those tiny little checkboxes you need to check to specify if you like to get spammed or not. They are simply too small. There is an easy solution though, that everyone should be aware of: the label element. What it does is associate some text with the checkbox. The browsers use this information by making a click on the text check the box. Note: this also works for radio buttons. Here&#39;s the markup you need:&lt;/p&gt;
&lt;div class=&#34;highlight&#34; data-language=&#34;HTML&#34;&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;form&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;action&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;&amp;quot;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;input&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;checked&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;checked&amp;quot;&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;id&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;send_spam&amp;quot;&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;type&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;checkbox&amp;quot;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;br&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;label&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;for&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;send_spam&amp;quot;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;Send me all your &amp;quot;newsletters&amp;quot;&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;label&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;br&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;form&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;div class=&#34;highlight&#34; data-language=&#34;CSS&#34;&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;label&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;k&#34;&gt;cursor&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;kc&#34;&gt;pointer&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;p&gt;There&#39;s a lot more to learn about how to make your forms usable and accessible. Just head over to the Web standards project&#39;s &lt;a href=&#34;http://www.webstandards.org/learn/tutorials/accessible-forms/beginner/&#34;&gt;Accessible forms tutorial&lt;/a&gt; (don&#39;t miss the intermediate one either).&lt;/p&gt;
&lt;h2 id=&#34;make-it-interesting&#34;&gt;Make it interesting&lt;a href=&#34;#make-it-interesting&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;You have a few seconds to get you visitor hooked to your site. In that time the user needs to understand he&#39;s on the right track. &amp;quot;Ah, this site seems to be about web development&amp;quot; is what I want my users to feel when they enter Friendly Bit. Therefore almost all my pages have a little info box that tells the visitors just that. To just put this info on your front page isn&#39;t enough, search engines or other external links can make them enter deeper into your site. Please put this little info-box somewhere on all of your sites. It&#39;s one of the best ways for me to see I&#39;m where I want to be.&lt;/p&gt;
&lt;p&gt;To actually get your content interesting you need to work on your writing. My best tip is to follow the points Liz Strauss summed up nicely in her post about &lt;a href=&#34;http://www.successful-blog.com/1/9-1-things-every-reader-wants-from-a-writer/&#34;&gt;what a reader wants&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Read through your text over and over again, out loud if you need to. Pay attention to typography, don&#39;t make your paragraphs too long and use headers extensively.&lt;/p&gt;
&lt;h2 id=&#34;conclusion&#34;&gt;Conclusion&lt;a href=&#34;#conclusion&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;These are just some of the tricks I find myself using on my sites. I&#39;m sure this site does not follow all of them perfectly but that doesn&#39;t stop me from telling you about them, does it? Pick and choose as you like, but try to reach make you visitors feel that &amp;quot;it just works&amp;quot;-feeling.&lt;/p&gt;
&lt;p&gt;Do you have any tricks you can share?&lt;/p&gt;

            </content>
        </entry>
    
        <entry>
            <title type="html">Correcting the 20 pro tips (.NET magazine)</title>
            <link href="http://friendlybit.com/css/correcting-the-20-pro-tips/" rel="alternate" type="text/html" title="Correcting the 20 pro tips (.NET magazine)" />
            <published>2006-07-26T05:01:06+02:00</published>
            <updated>2006-07-26T05:01:06+02:00</updated>
            <id>http://friendlybit.com/css/correcting-the-20-pro-tips/</id>
            <author>
                <name>Emil Stenström</name>
            </author>
            <summary type="text">.NET magazine is a fairly big web development magazine. I&#39;ve recently been referenced to its articles from many separate places, and often found the...</summary>
            <content type="html" xml:base="http://friendlybit.com/css/correcting-the-20-pro-tips/">
                &lt;p&gt;.NET magazine is a fairly big web development magazine. I&#39;ve recently been referenced to its articles from many separate places, and often found the articles to be of good quality. The last one, called &lt;a href=&#34;http://www.netmag.co.uk/zine/design-tutorials/20-pro-tips&#34;&gt;20 pro tips&lt;/a&gt;, was not too good though, so I&#39;m going to go through and correct it. I&#39;m not trying to attack the magazine here (remember &amp;quot;friendly&amp;quot; in the URL), I just want people to know these things.&lt;/p&gt;
&lt;p&gt;The article consists of 20 points that a pro should know. Here are the points I found errors in:&lt;/p&gt;
&lt;h2 id=&#34;stylesheets-importing-vs-linking-point-3&#34;&gt;Stylesheets: importing vs linking (point 3)&lt;a href=&#34;#stylesheets-importing-vs-linking-point-3&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;The point is that importing is better than linking since many older browsers will not apply the CSS then. This is correct but they also go as far as suggesting developers to add a separate stylesheet for Netscape 4 (NS4). As someone that has experimented with NS4 I can say that its CSS support is bad. Really bad. Considering the near zero percent of NS4 users I would strongly advise against fixing your site for it. That is of course, unless your site logs suggests you have a lot of users with that (old) browser.&lt;/p&gt;
&lt;p&gt;There&#39;s also a code error here, simple.css is included twice, and the second @import reference should probably be advanced.css. Not a big error but might confuse someone.&lt;/p&gt;
&lt;h2 id=&#34;smarter-gradient-backgrounds-point-4&#34;&gt;Smarter gradient backgrounds (point 4)&lt;a href=&#34;#smarter-gradient-backgrounds-point-4&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;Again a good point. CSS can be used to repeat background images on any element, not just body. This means you can save on file size by replacing big images with smaller ones. The article then suggests using 1 pixel wide images which is something old versions of IE has problems with. A lot of repetitions can easily get the browser very slow so my best bet would be to make them at least 5 pixels wide.&lt;/p&gt;
&lt;p&gt;In the code you would be better off using shorthand notation (I know, this is not a big deal). To add an extra pedagogic twist something else than body could have been used:&lt;/p&gt;
&lt;div class=&#34;highlight&#34; data-language=&#34;CSS&#34;&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;form&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;k&#34;&gt;background&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;kc&#34;&gt;white&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;nb&#34;&gt;url&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;(&lt;/span&gt;&lt;span class=&#34;sx&#34;&gt;background.png&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;)&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;kc&#34;&gt;repeat-x&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;h2 id=&#34;ie-box-model-hack-point-8&#34;&gt;IE Box Model Hack (point 8)&lt;a href=&#34;#ie-box-model-hack-point-8&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;A lot of confusion here. Internet Explorer 5 (IE5) uses another box model than the modern browsers. The padding and border are not added to the outside of a specified width, but instead included in it. This means that if you specify a 500 pixel wide box and add a 10 pixel border to it, it will still be 500 pixels wide. Some say that this is a better way of calculating widths but that&#39;s missing the point. The point is that according to the W3C box model the padding should be added &lt;em&gt;outside&lt;/em&gt; of the width.&lt;/p&gt;
&lt;p&gt;This problem does not appear in Internet Explorer 6 (IE6) if you &lt;a href=&#34;/css/cross-browser-strategies-for-css/#mode&#34;&gt;include a proper Doctype&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;So IE5 is broken, should you care? Again, check your logs if people still use the ancient IE5. My guess is that they don&#39;t which saves you a lot of work. There&#39;s probably &lt;em&gt;no need for this hack&lt;/em&gt;.&lt;/p&gt;
&lt;p&gt;Also, the &lt;a href=&#34;http://tantek.com/CSS/Examples/boxmodelhack.html&#34;&gt;Box model hack&lt;/a&gt; is Tantek&#39;s hack using the voice-family property to add a &amp;quot;}&amp;quot; to your CSS. It&#39;s really ugly. The article uses the same name for another solution to the problem: wrapping the offending element in another element and moving the padding to that box. That&#39;s a much cleaner way of fixing the problem.&lt;/p&gt;
&lt;h2 id=&#34;space-saver-point-9&#34;&gt;Space saver (point 9)&lt;a href=&#34;#space-saver-point-9&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;Don&#39;t use inline styles for styling. Try to keep all your styles in the external CSS file. Two more general ways of saving space across browsers are outlined in my &lt;a href=&#34;/css/cross-browser-strategies-for-css/#default&#34;&gt;cross-browser CSS article&lt;/a&gt; (the star-selector and using a premade CSS file that resets browser defaults.&lt;/p&gt;
&lt;h2 id=&#34;format-fundamentals-point-11&#34;&gt;Format fundamentals (point 11)&lt;a href=&#34;#format-fundamentals-point-11&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;Good points about image formats. Use 8-bit PNGs instead of GIF, it makes you smaller files.&lt;/p&gt;
&lt;p&gt;An addition: JPEGs are generally smaller than 32-bit PNGs but that&#39;s because JPEG removes information in your image to improve compression. Remember that, if you use JPEG.&lt;/p&gt;
&lt;p&gt;If you use PNG you need to know that IE has problems showing them in the exact correct color (&lt;a href=&#34;http://hsivonen.iki.fi/png-gamma/&#34;&gt;technical explanation of the PNG color problem&lt;/a&gt;). If that matters a lot to you, use another format (remember that all PNGs change color in IE, so images still match each other). Friendly Bit uses PNGs only.&lt;/p&gt;
&lt;h2 id=&#34;the-title-and-alt-attributes-point-12&#34;&gt;The ‘title’ and ‘alt’ attributes (point 12)&lt;a href=&#34;#the-title-and-alt-attributes-point-12&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;Don&#39;t use the title attribute unless it&#39;s needed to convey what you mean. In the example it does not make sense at all, why repeat the alt text? The main point is still true though, always use the alt attribute and make good use of the title attribute.&lt;/p&gt;
&lt;h2 id=&#34;wrapping-text-around-images-point-17&#34;&gt;Wrapping text around images (point 17)&lt;a href=&#34;#wrapping-text-around-images-point-17&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;Come on! Using the align attribute is going against what was just recommended, use of semantic markup (point 14). Alignment is style and should be added through CSS, nothing else. Adding a strict Doctype and validating will generate an error on this kind of ugliness. Use &lt;span class=&#34;float: left &#34;&gt;&lt;code&gt;img.typeOfImage&lt;/code&gt;&lt;/span&gt; instead.&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;
&lt;p class=&#34;first&#34;&gt;
  That&#39;s it for now, hope you learned something. I just wanted to make sure my readers know more than the .NET readers :)
&lt;/p&gt;


            </content>
        </entry>
    
        <entry>
            <title type="html">Why you should date a front-end developer</title>
            <link href="http://friendlybit.com/other/why-you-should-date-a-front-end-developer/" rel="alternate" type="text/html" title="Why you should date a front-end developer" />
            <published>2006-07-22T13:01:31+02:00</published>
            <updated>2006-07-22T13:01:31+02:00</updated>
            <id>http://friendlybit.com/other/why-you-should-date-a-front-end-developer/</id>
            <author>
                <name>Emil Stenström</name>
            </author>
            <summary type="text">You&#39;ve heard all those rumours of how nerdy looking people in glasses obsess over numbers they call things like &#34;pie&#34; or &#34;eee&#34;. You heard they dress up like...</summary>
            <content type="html" xml:base="http://friendlybit.com/other/why-you-should-date-a-front-end-developer/">
                &lt;p&gt;You&#39;ve heard all those rumours of how nerdy looking people in glasses obsess over numbers they call things like &amp;quot;pie&amp;quot; or &amp;quot;eee&amp;quot;. You heard they dress up like aliens and go to big… ehm… seminars, where people sleep in sleeping bags and only eat bad food. Then you have the other side of it, in a couple of years they will have well-paid jobs at some major technological company. They also don&#39;t switch partners easily, if they find someone they like they stick to him/her for, like, forever. You might also be able to hold an intellectual conversation with someone from this group, just try to stay away from tech-talk, you don&#39;t want get hurt. If you are able to get their eyes off the screen, say hello to &lt;em&gt;the programmers&lt;/em&gt;.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;Typical comment: &amp;quot;Linux is much better than Windows&amp;quot;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;On a trendy club in the middle of town you&#39;ll find the next group of people. Some of these also have glasses, but not because they need them, more because it makes them look hip. These people never talk directly with the programmers; a few words could easily ruin their reputation completely. While these people also make a lot of money it&#39;s more spread out over the year. They sometime get a creative period in January and paint images of pink goats that they sell for thousands of dollars, just to get no ideas at all in February and be broke. People from this group should be interesting if you&#39;re in for fame and fortune, passion and flame, but be aware that you might need a couple of partners to switch between depending on their weekly mood. If they get a break in their busy schedule, you should say hello to &lt;em&gt;the designers&lt;/em&gt;.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;Typical comment: &amp;quot;Did you see those shoes she was wearing? They where teeeeerrible!&amp;quot;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;In the third corner, not talking with any of the two groups above, we have a smaller group of people. These started as programmers but didn&#39;t like sitting isolated in basements. They wanted to work more with people and what people wanted. After studying methods for doing that they suddenly stopped thinking about anything else. They quickly made enemies with the designers because of their often pretty creations that made people go &amp;quot;oh, this looks good&amp;quot; instead of using the product right away. People in this group are great at handling people, and are often good company on dates, that is, if you can take their know-it-all attitude. They tend to know everything that matters and love to tell you about it. They get decent salary and tend to stick with partners that stay &amp;quot;useful&amp;quot; (not too pretty) and focus on right things. If you find the most functional way to say hello you should try it with these people, the &lt;em&gt;usability experts&lt;/em&gt;.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;Typical comment: &amp;quot;Door handles are really quite bad, 60% of users would be better off with something else&amp;quot;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;But I&#39;m not here to talk about programmers, designers, or usability experts. I&#39;m here to talk about a fourth group of people. These are the people that all three of the previous actually talk to. Not because they necessarily want to, but because they need it to get things done. These are the people that get frowned upon for being bad programmers, lousy designers, and for knowing too little about usability. Truth is, they still they manage to ship sites that actually work. They tend to be good at coding, but not in the way programmers are used to. While they don&#39;t have the status of designers, they are visible in the same way. They are actually good at explaining their thinking to people around them (often without technical experience), and know who they design for. You&#39;ll have no problems saying hello to the &lt;em&gt;front-end developers&lt;/em&gt;.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;Typical comment: &amp;quot;Don&#39;t use tables for layout&amp;quot;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;So, this fourth group of people have all the good characteristics of the other groups. Just like programmers they are able to have an intellectual conversation with someone. If you like the &amp;quot;nerdyness&amp;quot; that pretty much defines programmers, you&#39;ll sometimes find it with the front-enders too (just try mentioning that you like XHTML). Like designers they do get some of the fame when a site gets successful, since they are the ones pulling the strings and making things work they are quite visible. But unlike designers, these people will not desert you because you used the same t-shirt two days in a row. As a final strike you&#39;ll find that front-enders are good with people, just like the usability experts. They even know about the people that will be using the site and will gladly meet with them if they get the chance.&lt;/p&gt;
&lt;p&gt;So front-end developers are simply the best kind of date, so what are you waiting for? Go out there and get one before they run out!&lt;/p&gt;

            </content>
        </entry>
    
        <entry>
            <title type="html">Concept: Four layers of web development</title>
            <link href="http://friendlybit.com/css/concept-four-tier-web-development/" rel="alternate" type="text/html" title="Concept: Four layers of web development" />
            <published>2006-06-03T18:45:07+02:00</published>
            <updated>2006-06-03T18:45:07+02:00</updated>
            <id>http://friendlybit.com/css/concept-four-tier-web-development/</id>
            <author>
                <name>Emil Stenström</name>
            </author>
            <summary type="text">When thinking about web development on the client side, I tend to think of four different layers. Any (well built) framework will cater for all of these...</summary>
            <content type="html" xml:base="http://friendlybit.com/css/concept-four-tier-web-development/">
                &lt;p&gt;When thinking about web development on the client side, I tend to think of four different layers. Any (well built) framework will cater for all of these layers and all good developers will be aware of them. The layers I&#39;m thinking about are: Data, Structure, Design, and Behavior. This article discusses all four of those and explains how they relate.&lt;/p&gt;
&lt;h2 id=&#34;data-layer&#34;&gt;Data layer&lt;a href=&#34;#data-layer&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;The data layer is the most important one and strangely the one most people get confused about. HTML is &lt;em&gt;not&lt;/em&gt; the data layer, the &lt;strong&gt;content&lt;/strong&gt; is. The data layer is the raw data that you are presenting, the text, the images, the sound, the video, whatever content you want to serve. For bigger sites the data is often stored in a database or perhaps XML files somewhere and then processed server side every time someone wants to access it.&lt;/p&gt;
&lt;p&gt;This layer is also where all websites should start. What content do you have? If the content is bad no pretty design or fancy Web 2.0 technique is going to cater for that. In fact, content together with bad uses of the other layers, &lt;a href=&#34;http://www.andyrutledge.com/bad-design.php&#34;&gt;might still work&lt;/a&gt;!&lt;/p&gt;
&lt;p&gt;One last point to make about data is that you should make sure to use the best possible media for representing your content. If it can be text, use text! Don&#39;t use images for text, narrate your podcasts (or at least provide a text-summary), put your videos online with descriptions to them. Having that text there helps you convey your point, search engines will find you, your users will be able to skim read while it loads and disabled users will get access to at least some of your content.&lt;/p&gt;
&lt;h2 id=&#34;structural-layer&#34;&gt;Structural layer&lt;a href=&#34;#structural-layer&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;The structural layer is where the much misunderstood HTML comes to play. HTML&#39;s job is to take the data it has received from the data layer and &lt;a href=&#34;/html/datatypes-of-html/&#34; title=&#34;Some examples of data structures you have available in HTML&#34;&gt;add some structure to it&lt;/a&gt;. Mark up what parts are headers, make sure lists get the HTML that best describes them, split the page up in the important parts and so on.&lt;/p&gt;
&lt;p&gt;HTML also adds some semantics to the data but since it&#39;s quite a limited dictionary we have to work with I believe this is secondary. If you happened to have the kind of data that HTML happens to catch with its elements be sure to use them, if not make sure you at least capture the structure of it.&lt;/p&gt;
&lt;p&gt;You know you have done this level right if your site works with nothing but data and structure.&lt;/p&gt;
&lt;h2 id=&#34;design-layer&#34;&gt;Design layer&lt;a href=&#34;#design-layer&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;The design layer is where you define the looks of your data. Design requires a good basic structure to be useful. On the web you should use CSS for this layer, a language that has been built upon the idea of a solid structure and is remarkably powerful. As you know CSS targets certain elements and then defines their look. Without a solid structure this is not possible.&lt;/p&gt;
&lt;p&gt;Good designers often point out that only working with the looks of a site will not accomplish good design. They also work on the structural layer by making sure structurally important content gets the most exposure in the design. This is also strengthens the idea that structure is a layer upon which design works.&lt;/p&gt;
&lt;h2 id=&#34;behavioral-layer&#34;&gt;Behavioral layer&lt;a href=&#34;#behavioral-layer&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;Behavior is the last layer I&#39;m going to talk about. It&#39;s the one that&#39;s least important; data, structure and design are all more effective in conveying your message. None the less, added behavioral functionality &lt;em&gt;can&lt;/em&gt; be powerful if executed properly on top of the other layers.&lt;/p&gt;
&lt;p&gt;Javascript is the most used language for adding new behavior to websites. With the whole &lt;a href=&#34;http://en.wikipedia.org/wiki/Web_2.0&#34;&gt;Web 2.0&lt;/a&gt; and &lt;a href=&#34;http://en.wikipedia.org/wiki/Ajax_%28programming%29&#34;&gt;AJAX&lt;/a&gt; wave we are experiencing many new sites that adds a behavioral layer without even thinking about it. We should be careful; becoming dependent on the new behavior (the site not working without it) means you will lose many potential visitors, the most important single one being search engines. Behavior should always be added separately and only enhance the experience for those that has it enabled. This is what&#39;s called unobtrusive javascript.&lt;/p&gt;
&lt;h2 id=&#34;putting-it-all-together-four-tier-web-development&#34;&gt;Putting it all together: four tier web development&lt;a href=&#34;#putting-it-all-together-four-tier-web-development&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;Putting all these four parts together we get the following:&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;/files/four-tier-webdev.png&#34; alt=&#34;Adding layers step by step to a paragraph of text&#34; /&gt;&lt;/p&gt;
&lt;p&gt;Is this the same mental model you use? Let me know through comments.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Update:&lt;/strong&gt; Threehouse has an image up showing the four layers in the context of javascript connection the layers together.&lt;/p&gt;

            </content>
        </entry>
    
        <entry>
            <title type="html">Improving the web; Blogging, Google and Web standards</title>
            <link href="http://friendlybit.com/css/improving-the-web/" rel="alternate" type="text/html" title="Improving the web; Blogging, Google and Web standards" />
            <published>2006-05-20T00:12:31+02:00</published>
            <updated>2006-05-20T00:12:31+02:00</updated>
            <id>http://friendlybit.com/css/improving-the-web/</id>
            <author>
                <name>Emil Stenström</name>
            </author>
            <summary type="text">The web has really changed the way we do things. Remember those paper timetables? No need for them anymore, we simply type in our destination on a box and...</summary>
            <content type="html" xml:base="http://friendlybit.com/css/improving-the-web/">
                &lt;p&gt;The web has really changed the way we do things. Remember those paper timetables? No need for them anymore, we simply type in our destination on a box and get a step by step guide for what to do. Finding recipies? No need to look through books any more, just type in a few ingredients on your favourite food site. The examples are countless but there is no time for us to sit back and relax just yet. The web &lt;em&gt;can&lt;/em&gt; be improved. We can get more people to publish their stuff online, we can get better tools for finding relevant info, and we can make the information accessible to more people. In this article I&#39;m going to talk a little about each of those three points.&lt;/p&gt;
&lt;h2 id=&#34;we-need-more-information&#34;&gt;We need more information&lt;a href=&#34;#we-need-more-information&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;We need more information. People will argue and say &amp;quot;No, there&#39;s enough junk online already&amp;quot; but I don&#39;t care. More information is a good thing. The web is currently not a good representation of the world at large. The is a million technology weblogs and five about shoemaking. Another million sites about how it&#39;s like to be a teenager today and another five about life as an 80 year old. You know what I&#39;m getting at? We need a wider variety of people on the web, not only people that are just like us.&lt;/p&gt;
&lt;p&gt;Another thing to remember is that text only is one facet of information. With today’s bandwidth available we can look at live video from all over the world. We can listen to live radio and music just as easy as we read the web. We then have a look at availability. I&#39;d say that at most one out of 1000 people publishing on the web is using something else than text (This site is no exception). I know that there are people out there that have a video camera, that have a microphone, and know how to put it up on the web. But they don&#39;t.&lt;/p&gt;
&lt;p&gt;This lack of variety in information is a real problem. It builds barriers towards people we just don&#39;t know anything about and it fools us surfers to believe the world is smaller than it seems. &amp;quot;No, there can&#39;t be any problems with the Chinese government, we would have heard about it!” or what about &amp;quot;Christianity must be the biggest religion, just look at what people are writing most about&amp;quot;.&lt;/p&gt;
&lt;p&gt;There &lt;em&gt;are&lt;/em&gt; ways the tackle this problem and the concept of blogging is one of them. It makes it easy to almost anyone, anywhere to just start writing in a few minutes. You can be anonymous, you don&#39;t have to tell the truth, there&#39;s no age check and it doesn&#39;t cost you money. This opens up to real diversity on the web. The technology exists, what we need to do is get people online and make them use it. So tell your friends to pick something they love or hate and blog about it. We need more information.&lt;/p&gt;
&lt;h2 id=&#34;we-need-relevant-information&#34;&gt;We need relevant information&lt;a href=&#34;#we-need-relevant-information&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;The next step, after we have gotten a larger and more diversified web, is to start filtering it. I&#39;m not talking censoring here, I mean filtering in the sense to &amp;quot;filter what you want&amp;quot;. This can be tied to a certain task you want to accomplish or it can be a strong interest of yours that you want to follow. It doesn&#39;t matter which, what matters is that there are ways to easily find relevant information.&lt;/p&gt;
&lt;p&gt;There are many ways of determining relevancy on the web and the one most successful is linking. Links are like recommendations; anyone that links to a site is telling their readers a certain site is recommended. It&#39;s relevant for the subject at hand and it contains good information. If you are just looking for random information about something looking at a few links might be enough. For example, if &lt;a href=&#34;http://www.456bereastreet.com&#34;&gt;Roger Johansson&lt;/a&gt; links to something web related I can be pretty sure it&#39;s good.&lt;/p&gt;
&lt;p&gt;For more task oriented queries we need something else. If someone is looking for a plane ticket they will probably not know who the authority in that area is. Google is the search engine that has had the greatest success with solving this problem and the solution is simple. Gather the recommendations for as many sites as possible and reply to queries with what &lt;em&gt;most&lt;/em&gt; people recommend. Just think about it, if 100 people recommend FlyPlane and 1000 people AirFlight, who would you go for?&lt;/p&gt;
&lt;p&gt;In reality it isn’t that simple, but in essence that’s how search engines work. Something that is important to note is that the system encourages people to write &lt;em&gt;good content&lt;/em&gt;. Why is that? Simply because good content gets linked to, and more links means it&#39;s probably more relevant. This way Google and all the others are actively encouraging people to improve the web. Good, isn&#39;t it?&lt;/p&gt;
&lt;h2 id=&#34;making-information-accessible&#34;&gt;Making information accessible&lt;a href=&#34;#making-information-accessible&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;So, we have lots of information from all over the world and we have the tools to find the most relevant info at any point. The last step is actually delivering the information to our users. This is where web standards come to play.&lt;/p&gt;
&lt;p&gt;In the early nineties browser makers raced to get the coolest new features included in their browsers. The result was things like blinking text, different methods of representing &amp;quot;layers&amp;quot; and scrolling text. Web developers had a hard time keeping up with browser differences and often you had to construct two or more separate pages to send people to depending on what browser they used.&lt;/p&gt;
&lt;p&gt;The W3C acknowledged this and presented a solution. Instead of browsers trying to find the coolest additions, let a standards organization handle the new additions. Let hundreds of people sit together and discuss new ideas long before they are implemented. When everyone has had a chance to say their meaning and problems has been eliminated you release a document presenting the new features together with implementation details. Now the browser makers can race over who supports the most recommended standards instead, and webmasters can just pick a set of standards that is well supported. One way of doing things instead of many incompatible ones.&lt;/p&gt;
&lt;p&gt;Right now, the current recommendation is to use the strict versions of HTML of XHTML for structure, CSS for design and Javascript for behaviour. Using those standards means that your site is accessible by more than just the few browsers you have tested with. Both people and automated crawlers that that are after just your content can easily skip your design. People with old browsers will still be able to view your content, even though they don’t see the design the still get the content.&lt;/p&gt;
&lt;p&gt;If you adopt the recommendations I mentioned above you have gotten quite far, but there is more. &lt;em&gt;Accessibility&lt;/em&gt; is an area in web development that has gotten far too little exposure. It&#39;s focused on making it easier to people with various disabilities, varying from broken arms and color blindness to dyslexia. Previously people cared about old browsers, it’s time for a shift towards caring about people instead. Read up on accessibility, Mark Pilgrim&#39;s &lt;a href=&#34;http://diveintoaccessibility.org/introduction.html&#34;&gt;Dive into Accessibilty&lt;/a&gt; is a good start.&lt;/p&gt;
&lt;h2 id=&#34;in-summary&#34;&gt;In summary&lt;a href=&#34;#in-summary&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;I&#39;ve gone over three areas where I believe there is space for improvement on the web.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;More diversified information. Get your friends on the web!&lt;/li&gt;
&lt;li&gt;Better tools for filtering all the information depending on what we need. Build new and better tools for doing this!&lt;/li&gt;
&lt;li&gt;Use web standards and care about accessibility. I try to help in this area with the help of this blog.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Now I&#39;m interested in your comments. What do you think? Are there more areas we need to look into?&lt;/p&gt;

            </content>
        </entry>
    
        <entry>
            <title type="html">What beginners ask for (and what I tell them)</title>
            <link href="http://friendlybit.com/css/what-beginners-ask-for-and-what-i-tell-them/" rel="alternate" type="text/html" title="What beginners ask for (and what I tell them)" />
            <published>2006-03-27T22:22:07+02:00</published>
            <updated>2006-03-27T22:22:07+02:00</updated>
            <id>http://friendlybit.com/css/what-beginners-ask-for-and-what-i-tell-them/</id>
            <author>
                <name>Emil Stenström</name>
            </author>
            <summary type="text">Being in an IRC help channel lets you meet a lot of people. Many are fresh beginners that just wrote their first lines of CSS and stumbled over something...</summary>
            <content type="html" xml:base="http://friendlybit.com/css/what-beginners-ask-for-and-what-i-tell-them/">
                &lt;p&gt;Being in an IRC help channel lets you meet a lot of people. Many are fresh beginners that just wrote their first lines of CSS and stumbled over something they found strange. When you look at their questions from a perspective you quickly find that many of them are repeated and come back over and over again. This article is an attempt to list a few of the important concepts that people seem to have trouble with.&lt;/p&gt;
&lt;h2 id=&#34;separation&#34;&gt;Separation of content and design&lt;a href=&#34;#separation&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;Separation is the fundamental idea that CSS builds upon. Ten years ago there was only one way to make pages that worked across browsers: you mixed everything in one large file and copied that file if you wanted pages that looked similar. Then &lt;a href=&#34;/css/interview-why-did-css-succeed/&#34; title=&#34;Interview with Håkon Wium Lie&#34;&gt;Håkon&lt;/a&gt; and Bert came up with CSS and things got much easier. Their idea is to make the code easier to maintain by extracting everything that has to do with design, put it in an external file and link to that file when we want a certain look. CSS is all about design and HTML is all about content and structure.&lt;/p&gt;
&lt;p&gt;Even though this sounds good in theory there are a lot of cases where it&#39;s hard to determine whether something is design or not. Is the company logo design or content? When you start thinking about those kinds of problems you know you&#39;re on the right track. You can find a couple of examples of the separation I&#39;m talking about in my &lt;a href=&#34;/css/beginners-guide-to-css-and-standards/&#34;&gt;beginners guide&lt;/a&gt;.&lt;/p&gt;
&lt;h2 id=&#34;clearing&#34;&gt;Clearing floats&lt;a href=&#34;#clearing&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;Floats and clearing is another problem almost everyone has in the beginning. What I like to use when I explain how floats work is the old align-attribute on images. Long time ago, when you only could use HTML for design, and wanted the text to &amp;quot;flow around the image&amp;quot; you used:&lt;/p&gt;
&lt;div class=&#34;incorrect&#34;&gt;&lt;div class=&#34;highlight&#34; data-language=&#34;HTML&#34;&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;img&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;src&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;/files/post-media/image.jpg&amp;quot;&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;align&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;right&amp;quot;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;&lt;p&gt;The above code is clearly design (placement of the image) so we should use CSS instead of HTML for this.&lt;/p&gt;
&lt;div class=&#34;correct&#34;&gt;&lt;div class=&#34;highlight&#34; data-language=&#34;CSS&#34;&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;img&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;#&lt;/span&gt;&lt;span class=&#34;nn&#34;&gt;id_of_image&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;k&#34;&gt;float&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;kc&#34;&gt;right&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;&lt;p&gt;CSS is not restricted to float only images, all elements can be floated. This opens up to both new layout methods and confusion. To place three divisions side by side, just give them a width and float them. You can see a layout based on this in my &lt;a href=&#34;/css/simple-css-templates/&#34;&gt;article about layouts&lt;/a&gt; or the &lt;a href=&#34;/files/templates/?style=3columns_float_float_float&amp;cols=3&#34; data-no-instant&gt;3-column example&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;&lt;em&gt;Clear&lt;/em&gt; is also important to know of. Setting &lt;code&gt;clear: both;&lt;/code&gt; on an element makes it move downwards until it&#39;s below all previous floats. That was how the footer in the above example was made.&lt;/p&gt;
&lt;p&gt;Floats and clears are not always easy to understand though. One thing people often ask about is what&#39;s wrong when their container isn&#39;t expanded to contain everything inside it. Eric Meyer excellently explains both that problem and its solution in the article &lt;a href=&#34;http://www.complexspiral.com/publications/containing-floats/&#34;&gt;Containing Floats&lt;/a&gt;.&lt;/p&gt;
&lt;h2 id=&#34;validation&#34;&gt;Validation is a timesaver&lt;a href=&#34;#validation&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;Why is validation so important? Because I just can&#39;t stand you forgetting your alt attributes? Because I think that valid pages are better than non-valid? No and No. It&#39;s because validation finds the simple errors. If I misspell width or some other property a validation will find it. If I nest my tags incorrectly a validation will find it. If I forget to close a quote in a link? A validation will find it. Validation is a great timesaver because it actually finds all the small errors that humans have trouble finding. To make validation even easier I use the &lt;a href=&#34;http://users.skynet.be/mgueury/mozilla/&#34;&gt;Html Validator extension&lt;/a&gt; for Firefox. A little icon in the bottom right corner tells me when I have an HTML error. Validation is a great tool, use it.&lt;/p&gt;
&lt;h2 id=&#34;accessibility&#34;&gt;Accessibility is not about blind users&lt;a href=&#34;#accessibility&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;It could be that I&#39;m trying to explain why someone should add labels to their form. I say something in the lines of:&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;&lt;strong&gt;Me&lt;/strong&gt;: &amp;quot;Not having labels hurts your site’s accessibility&amp;quot;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;&lt;strong&gt;User&lt;/strong&gt;: &amp;quot;But I don&#39;t have any blind users on my site!&amp;quot;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;Accessibility is about making it easy for as many as possible to access your content. With, often simple, means you can make it much easier for people to access your site. Let me give you some examples or people your can help by thinking about accessibiliy.&lt;/p&gt;
&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
  &lt;th&gt;User&lt;/th&gt;
  &lt;th&gt;How you can help&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
  &lt;td&gt;Partly color blind&lt;/td&gt;
  &lt;td&gt;Don&#39;t use only color to convey information&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td&gt;People unable to use a mouse. Either because of some physical disability or simply that they are linux hackers and dislike it.&lt;/td&gt;
  &lt;td&gt;Make sure keyboard navigation works as intended&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td&gt;Young users or users with another native language than yours&lt;/td&gt;
  &lt;td&gt;Don&#39;t overcomplicate your text&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td&gt;People with a slow connection&lt;/td&gt;
  &lt;td&gt;Mind the size of your site&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;p&gt;The list could continue for a whole article. People from those groups would very much like to see your site and buy your stuff just like anyone else. Read up on the basics of accessiblity, it helps a lot of people. Robert Johansson has written a nice article about how you could &lt;a href=&#34;http://www.456bereastreet.com/archive/200603/evaluating_website_accessibility_part_1_background_and_preparation/&#34;&gt;evaluate your website&#39;s accessibility&lt;/a&gt;.&lt;/p&gt;
&lt;h2 id=&#34;harder&#34;&gt;Some things are harder to do with CSS, that does not mean CSS is a bad language&lt;a href=&#34;#harder&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;People that are switching from tables to CSS often complain about what a bad language CSS is for not supporting &lt;em&gt;[insert favourite feature]&lt;/em&gt;. I did so too in the beginning. What makes me like the language is all the other powers it gives me. It is not possible to do everything as easily with CSS as it is with tables. But other things are much easier, and some things aren&#39;t even possible with tables. There are good parts and bad parts and to me the good parts greatly outweigh the bad ones.&lt;/p&gt;
&lt;h2 id=&#34;equal&#34;&gt;Equal height columns&lt;a href=&#34;#equal&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;The last thing I&#39;m going to talk about in this article is equal height columns. The problem is that your have two or three columns of content that stretch down the page. You want the columns to stretch as far as the longest column but the content inside does not expand the columns that far.&lt;/p&gt;
&lt;p&gt;This problem is most easily solved by a technique known as &lt;em&gt;faux columns&lt;/em&gt;. Add a container to the columns you have and then add a background image to that container. The image will repeat down that page and make it look like your columns take up exactly as much vertical space. I&#39;ve added a &lt;a href=&#34;/files/templates/?style=faux_columns&amp;cols=3&amp;nofooter=1&#34; data-no-instant&gt;faux column example&lt;/a&gt; for you to look at.&lt;/p&gt;

            </content>
        </entry>
    
        <entry>
            <title type="html">Building a poker template</title>
            <link href="http://friendlybit.com/css/semantic-poker-template/" rel="alternate" type="text/html" title="Building a poker template" />
            <published>2006-01-23T03:31:06+01:00</published>
            <updated>2006-01-23T03:31:06+01:00</updated>
            <id>http://friendlybit.com/css/semantic-poker-template/</id>
            <author>
                <name>Emil Stenström</name>
            </author>
            <summary type="text">This is the first article in a series of niche templates I&#39;m building. You can have a look at the finished template before we start if you want. About the...</summary>
            <content type="html" xml:base="http://friendlybit.com/css/semantic-poker-template/">
                &lt;p&gt;This is the first article in a series of &lt;a href=&#34;/css/building-niche-sites-with-standards/&#34;&gt;niche templates&lt;/a&gt; I&#39;m building. You can have a look at the &lt;a href=&#34;/files/poker/?style=positioning&amp;style2=decoration&#34; data-no-instant&gt;finished template&lt;/a&gt; before we start if you want.&lt;/p&gt;
&lt;h2 id=&#34;about-the-niche&#34;&gt;About the niche&lt;a href=&#34;#about-the-niche&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;Today&#39;s topic is &lt;em&gt;Poker sites&lt;/em&gt;. Poker, and card games overall, are hot these days and they are all over news. There are TV commercials for big international gambling sites even here in Sweden. Being in that kind of spotlight and receiving massive traffic must make those sites better than the rest, don&#39;t you think? Let&#39;s &lt;a href=&#34;http://www.google.com/search?q=poker&#34;&gt;google for &amp;quot;poker&amp;quot;&lt;/a&gt; and have a look at the top 10 results (23 Jan 2006).&lt;/p&gt;
&lt;table summary=&#34;A look at the web standards compliance of poker sites&#34;&gt;
  &lt;tr&gt;
    &lt;th title=&#34;Placement in Google&#34;&gt;
      #
    &lt;/th&gt;
    &lt;th&gt;
      Site name
    &lt;/th&gt;
    &lt;th&gt;
      Doctype
    &lt;/th&gt;
    &lt;th&gt;
      Validation errors
    &lt;/th&gt;
    &lt;th&gt;
      Layout method
    &lt;/th&gt;
  &lt;/tr&gt;

  &lt;tr&gt;
    &lt;th&gt;
      1
    &lt;/th&gt;
    &lt;td&gt;
      Pokerroom.com
    &lt;/td&gt;
    &lt;td class=&#34;almost&#34;&gt;
      Transitional
    &lt;/td&gt;
    &lt;td class=&#34;incorrect&#34;&gt;
      22 errors
    &lt;/td&gt;
    &lt;td class=&#34;incorrect&#34;&gt;
      Tables
    &lt;/td&gt;
  &lt;/tr&gt;

  &lt;tr&gt;
    &lt;th&gt;
      2
    &lt;/th&gt;
    &lt;td&gt;
      Poker.com
    &lt;/td&gt;
    &lt;td class=&#34;correct&#34;&gt;
      Strict
    &lt;/td&gt;
    &lt;td class=&#34;incorrect&#34;&gt;
      62 errors
    &lt;/td&gt;
    &lt;td class=&#34;correct&#34;&gt;
      CSS
    &lt;/td&gt;
  &lt;/tr&gt;

  &lt;tr&gt;
    &lt;th&gt;
      3
    &lt;/th&gt;
    &lt;td&gt;
      Pokerstars.com
    &lt;/td&gt;
    &lt;td class=&#34;incorrect&#34;&gt;
      None
    &lt;/td&gt;
    &lt;td class=&#34;incorrect&#34;&gt;
      48 errors
    &lt;/td&gt;
    &lt;td class=&#34;incorrect&#34;&gt;
      Tables
    &lt;/td&gt;
  &lt;/tr&gt;

  &lt;tr&gt;
    &lt;th&gt;
      4
    &lt;/th&gt;
    &lt;td&gt;
      Pokerpages.com
    &lt;/td&gt;
    &lt;td class=&#34;incorrect&#34;&gt;
      None
    &lt;/td&gt;
    &lt;td class=&#34;incorrect&#34;&gt;
      336 errors
    &lt;/td&gt;
    &lt;td class=&#34;incorrect&#34;&gt;
      Tables
    &lt;/td&gt;
  &lt;/tr&gt;

  &lt;tr&gt;
    &lt;th&gt;
      5
    &lt;/th&gt;
    &lt;td&gt;
      Pagat.com Poker
    &lt;/td&gt;
    &lt;td class=&#34;incorrect&#34;&gt;
      None
    &lt;/td&gt;
    &lt;td class=&#34;incorrect&#34;&gt;
      52 errors*
    &lt;/td&gt;
    &lt;td class=&#34;correct&#34;&gt;
      None
    &lt;/td&gt;
  &lt;/tr&gt;

  &lt;tr&gt;
    &lt;th&gt;
      6
    &lt;/th&gt;
    &lt;td&gt;
      Worldpokertour.com
    &lt;/td&gt;
    &lt;td class=&#34;almost&#34;&gt;
      Transitional
    &lt;/td&gt;
    &lt;td class=&#34;incorrect&#34;&gt;
      56 errors
    &lt;/td&gt;
    &lt;td class=&#34;incorrect&#34;&gt;
      Tables
    &lt;/td&gt;
  &lt;/tr&gt;

  &lt;tr&gt;
    &lt;th&gt;
      7
    &lt;/th&gt;
    &lt;td&gt;
      Pacificpoker.com
    &lt;/td&gt;
    &lt;td class=&#34;incorrect&#34;&gt;
      None
    &lt;/td&gt;
    &lt;td class=&#34;incorrect&#34;&gt;
      72 errors
    &lt;/td&gt;
    &lt;td class=&#34;incorrect&#34;&gt;
      Tables
    &lt;/td&gt;
  &lt;/tr&gt;

  &lt;tr&gt;
    &lt;th&gt;
      8
    &lt;/th&gt;
    &lt;td&gt;
      Partypoker.com
    &lt;/td&gt;
    &lt;td class=&#34;almost&#34;&gt;
      Transitional
    &lt;/td&gt;
    &lt;td class=&#34;incorrect&#34;&gt;
      22 errors*
    &lt;/td&gt;
    &lt;td class=&#34;correct&#34;&gt;
      CSS
    &lt;/td&gt;
  &lt;/tr&gt;

  &lt;tr&gt;
    &lt;th&gt;
      9
    &lt;/th&gt;
    &lt;td&gt;
      Paradisepoker.com
    &lt;/td&gt;
    &lt;td class=&#34;almost&#34;&gt;
      Transitional
    &lt;/td&gt;
    &lt;td class=&#34;almost&#34;&gt;
      1 error
    &lt;/td&gt;
    &lt;td class=&#34;correct&#34;&gt;
      CSS
    &lt;/td&gt;
  &lt;/tr&gt;

  &lt;tr&gt;
    &lt;th&gt;
      10
    &lt;/th&gt;
    &lt;td&gt;
      Homepoker.com
    &lt;/td&gt;
    &lt;td class=&#34;incorrect&#34;&gt;
      Broken
    &lt;/td&gt;
    &lt;td class=&#34;incorrect&#34;&gt;
      146 errors
    &lt;/td&gt;
    &lt;td class=&#34;incorrect&#34;&gt;
      Tables
    &lt;/td&gt;
  &lt;/tr&gt;
&lt;/table&gt;

&lt;p class=&#34;first&#34;&gt;
  *) These sites required that we set a character set manually to even see how many errors there were.
&lt;/p&gt;

&lt;p&gt;What do we see up there? Poker.com and Paradisepoker.com do pretty well. Poker.com uses Strict doctype which means that their validation is stricter than the others, but 62 errors is still too much. Paradisepoker.com almost validates as Transitional which is a good thing compared to the other sites in the list.&lt;/p&gt;
&lt;p&gt;Three sites use CSS for their layouts instead of tables. This is a good thing and they should be commended for it. However, that does not mean that they can&#39;t be &lt;em&gt;better&lt;/em&gt;. All three with CSS layouts overuse divisions and spans terribly, often making the page a mess without CSS turned on.&lt;/p&gt;
&lt;p&gt;Does this guy do nothing more than whine? I hear you ask. Yes I do. What I will do is nothing special; any one of you reading this could have done it yourself. I&#39;m going to build a simple HTML document mimicking the front page of a poker site. If you are planning to build a site like that (or even if you are the developer of one of the sites above), you should definitely keep reading. The idea with all of this is to make it easier for people to follow the standards.&lt;/p&gt;
&lt;p&gt;I will only include the front page of the site but it won&#39;t be hard to transform it to something simpler later on. Remember the purpose here: to show that it&#39;s possible to combine logical markup, valid code and make it look just the way you want it to. We need some kind of content though, so let&#39;s start with that.&lt;/p&gt;
&lt;h2 id=&#34;plan-what-features-you-want&#34;&gt;Plan what features you want&lt;a href=&#34;#plan-what-features-you-want&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;The features for the template will be my picks of the top10 above. Let&#39;s put some time on analyzing what features a decent poker site has.&lt;/p&gt;
&lt;p&gt;The purpose of most of the sites seems to be to &lt;em&gt;get people to play&lt;/em&gt; on their site. Most have some kind of client that is easily available from the front page and that button is the most important part of the page. Aside from that we need features to build a community around the game. Let&#39;s pick &lt;em&gt;a forum&lt;/em&gt; as our community builder. Beginners need to have somewhere to &lt;em&gt;learn the basics&lt;/em&gt; and everyone might need &lt;em&gt;support&lt;/em&gt; from experienced staff sometimes. To build a good community you might also need news of some kind, displaying the largest prizes might give the site more players. Finally, all respectable sites have some info &lt;em&gt;about the company&lt;/em&gt; behind it and if the site is big, they have a &lt;em&gt;search&lt;/em&gt;. We want to earn some money too so let&#39;s add in a little advertisement. Sum this up in a list with descriptions.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Play poker button&lt;/strong&gt;: One big button telling people to click it.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Beginners guide and support&lt;/strong&gt;: Show on the front page that you don&#39;t need to be a pro to play and provide a quote from a professional player that illustrates this. Link directly into the guide to show experienced users that there might be something there for them too. Add frequently asked questions to this part too. Give users somewhere to turn to if they have problems.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;News&lt;/strong&gt;: Front page should link to a couple of top news and at the bottom have link to a dedicated news-page with more info.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Forum&lt;/strong&gt;: Users should feel that this is a site with lots of people. Link to the topics in the forum most posted in to show them just that. This site is live and kicking.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Search&lt;/strong&gt;: Search might be important both if you look for either a poker term or for a feature on the site. Add search for both the forums and the news here and let people decide which of them to search.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;About us&lt;/strong&gt;: Trust is important if you want people to part from their money. Put a picture of the staff online and quote reviews and happy customers (Don&#39;t fake this stuff. Never)&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Advertisement (Ads)&lt;/strong&gt;: Ads need needs to be marked up as what they are. We want users to click on the ads only if they like the service the advertisers are serving&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;We now need to transform this to HTML somehow. When you do this yourself, try to think as little about the color, fonts and such as possible. Focus on what &lt;em&gt;content&lt;/em&gt; you want to show your users and build the HTML based on that.&lt;/p&gt;
&lt;p&gt;On the next page we will get down to business and start coding. You want to see what I&#39;m talking about don&#39;t you?&lt;/p&gt;
&lt;p&gt;Time has come to go through the list of features and write the code for them. The question which we should keep in mind here is &amp;quot;What content do I have?&amp;quot;.&lt;/p&gt;
&lt;h2 id=&#34;play-poker-button&#34;&gt;Play poker button&lt;a href=&#34;#play-poker-button&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;Ok. We want a poker button. Some people prefer to use&lt;/p&gt;
&lt;p&gt;&lt;code&gt;&amp;lt;input type=&amp;quot;submit&amp;quot; /&amp;gt;&lt;/code&gt; for all kinds of buttons. Those buttons are made for submitting a form though, and that&#39;s not what we want here. When you think of it, is this &amp;quot;Play button&amp;quot; any different from a link? I think not. We will make it look like a button with CSS later on. Let&#39;s use the HTML of a simple link:&lt;/p&gt;
&lt;div class=&#34;highlight&#34; data-language=&#34;HTML&#34;&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;href&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;play-poker.html&amp;quot;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;Play poker&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;h2 id=&#34;advertisement&#34;&gt;Advertisement&lt;a href=&#34;#advertisement&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;All sites cost money to run and getting that money is often done with some kind of advertisement on the site. What kind of ads should we use for this template? Looking at the top10 it seems that images are more common than text so let&#39;s use images. Don&#39;t forget to let advertisers specify alternate text to their images so you don&#39;t have to make something up for the alt attribute.&lt;/p&gt;
&lt;div class=&#34;highlight&#34; data-language=&#34;HTML&#34;&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;h2&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;Advertisement&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;h2&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;href&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;url_to_advertisers_site.com&amp;quot;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
   &lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;img&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;src&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;/files/post-media/play-roulette-online.png&amp;quot;&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;alt&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;Advertisement: Play roulette online&amp;quot;&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;/&amp;gt;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;h2 id=&#34;beginners-guide&#34;&gt;Beginners guide&lt;a href=&#34;#beginners-guide&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;To get beginners to play on our site we need to at least teach them the basics. How? People don&#39;t like manuals and they are often hard to navigate in. The best would be if no manual were needed at all, but let&#39;s be realistic, some people will still need help. A good approach is to use questions in natural language to lure people to read the guide. Keep it simple and easy to read. To mark that this is the beginners guide we add a header with that name in. Don&#39;t be tempted to use any other header than h2, the h1 will be used for the name of the site and this is a second level header, nothing else. To mark up the questions we use a paragraph of text with links. At the end we add a link to more information. The class &amp;quot;more&amp;quot; there is just a way to say that this paragraph is different from the one above.&lt;/p&gt;
&lt;div class=&#34;highlight&#34; data-language=&#34;HTML&#34;&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;h2&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;Beginners guide&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;h2&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
If you are a poker beginner you might want to start by reading
&lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;href&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;help/rules-of-poker.html&amp;quot;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;the rules&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;. When you are done with that
you can &lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;href&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;#help/register.html&amp;quot;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;register an account&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt; with us. Don&amp;#39;t worry,
to join is free of charge and you can even win some money in our
&lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;href&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;help/monthly-tournaments.html&amp;quot;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;monthly tournaments&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;.
More questions are answered in the
&lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;href&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;help/frequently-asked-questions.html&amp;quot;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;frequently asked questions&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt; section
&lt;/pre&gt;&lt;/div&gt;
&lt;h2 id=&#34;news&#34;&gt;News&lt;a href=&#34;#news&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;People playing poker are probably interested in poker news too. By having news on your site your users don&#39;t have to go somewhere else looking for them. This will be a separate section so we should add a header here too, h2 is appropriate. The news items themselves are just items in an unordered list, so let&#39;s use the HTML for that, &lt;code&gt;&amp;lt;ul&amp;gt;&lt;/code&gt;. End it all with a link to the news page that we wrap it in a classed paragraph like before.&lt;/p&gt;
&lt;div class=&#34;highlight&#34; data-language=&#34;HTML&#34;&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;h2&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;News&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;h2&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;ul&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;23 feb: &lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;href&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;news/highest-prize-ever&amp;quot;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;Highest Prize Ever paid...&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;5 jan: &lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;href&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;news/caught-cheating&amp;quot;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;Top player caught cheating&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;10 dec: &lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;href&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;news/how-to-improve&amp;quot;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;How to improve your betting&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;1 nov: &lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;href&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;news/pokercompany-featured&amp;quot;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;PokerCompany featured on...&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;30 okt: &lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;href&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;news/murkus-baltomi&amp;quot;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;Murkus Baltomi the new...&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;24 apr: &lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;href&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;news/planned-downtime&amp;quot;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;Planned downtime on Sunday&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;ul&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
We maintain an &lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;href&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;#news/&amp;quot;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;news archive&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt; too.
&lt;/pre&gt;&lt;/div&gt;
&lt;h2 id=&#34;forum&#34;&gt;Forum&lt;a href=&#34;#forum&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;The forum posts can be handled much like the news. A header, a simple list, this time ordered by with the most active on top. End it with a now familiar classed paragraph.&lt;/p&gt;
&lt;div class=&#34;highlight&#34; data-language=&#34;HTML&#34;&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;h2&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;Forum&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;h2&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;ul&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;href&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;forum/forum.php?topic=7&amp;quot;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;Best strategy with one...&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt; - 124 repl.&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;href&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;forum/forum.php?topic=572&amp;quot;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;Anyone know of a store...?&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt; - 115 repl.&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;href&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;forum/forum.php?topic=17&amp;quot;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;What&amp;#39;s the name of the...&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt; - 89 repl.&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;href&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;forum/forum.php?topic=67&amp;quot;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;What your biggest pot?&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt; - 51 repl.&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;href&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;forum/forum.php?topic=23&amp;quot;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;There was this guy in...&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt; - 49 repl.&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;href&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;forum/forum.php?topic=325&amp;quot;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;Help me get my...&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt; - 36 repl.&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;ul&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;href&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;#forum/&amp;quot;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;Our forums&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt; are always filled with people to answer your questions.
&lt;/pre&gt;&lt;/div&gt;
&lt;h2 id=&#34;search&#34;&gt;Search&lt;a href=&#34;#search&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;The bigger the site gets the more important it becomes to get a site search. A search clearly resembles a form; the user fills in a few values and sends them to the site. A simple textbox for the search query with a submit following it.&lt;/p&gt;
&lt;p&gt;Just in case you&#39;re not familiar with the modern way to make a good form I&#39;ll go through the elements used below briefly.&lt;/p&gt;
&lt;p&gt;A &lt;code&gt;&amp;lt;fieldset&amp;gt;&lt;/code&gt; groups similar form elements together. For example, if you have two separate fields for first name and last name, you can signal that they are both part of the full name by adding a fieldset around both of them.&lt;/p&gt;
&lt;p&gt;Using &lt;code&gt;&amp;lt;legend&amp;gt;&lt;/code&gt; we then tell what the meaning of the fieldset is. For the previous example we could use &amp;quot;Full name&amp;quot;.&lt;/p&gt;
&lt;p&gt;The last &amp;quot;new&amp;quot; tag here is the &lt;code&gt;&amp;lt;label&amp;gt;&lt;/code&gt;. It simply shows that there are a relation between the text in front of the button and the input box right next to it. A good thing about this relation is that it enables you to click on the label and have the input selected; something that is particularly useful with small radio buttons. This is what the HTML looks like:&lt;/p&gt;
&lt;div class=&#34;highlight&#34; data-language=&#34;HTML&#34;&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;form&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;action&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;search.php&amp;quot;&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;method&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;get&amp;quot;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;fieldset&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
  &lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;legend&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;Site search&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;legend&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
  &lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;label&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;for&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;phrase&amp;quot;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;Search: &lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;label&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
  &lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;input&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;type&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;text&amp;quot;&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;id&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;phrase&amp;quot;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
  &lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;input&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;type&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;submit&amp;quot;&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;value&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;search&amp;quot;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;fieldset&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;form&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;h2 id=&#34;about-us&#34;&gt;About us&lt;a href=&#34;#about-us&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;Everyone wants to know who they&#39;re dealing with before they make a purchase of some kind (I believe that&#39;s one of the reasons some e-shops have problems, but that&#39;s a completely different story). Anyways, it&#39;s easy for you to put up an image and some quotes from people that are happy with your services, so do it. The header and &amp;quot;more&amp;quot; paragraph should be familiar by now.&lt;/p&gt;
&lt;div class=&#34;highlight&#34; data-language=&#34;HTML&#34;&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;h2&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;About us&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;h2&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
PokerCompany has been in the business since 1997 and is...
Want to read &lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;href&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;about/&amp;quot;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;more about us&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;?
&lt;/pre&gt;&lt;/div&gt;
&lt;p&gt;On the next page we will take all the pieces of HTML and put them together. It&#39;s getting interesting, don&#39;t you think?&lt;/p&gt;
&lt;h2 id=&#34;what-a-structured-document-looks-like&#34;&gt;What a structured document looks like&lt;a href=&#34;#what-a-structured-document-looks-like&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;We have carefully constructed all the markup for the important parts of the site. Notice that we&#39;ve said nothing about the look of it yet, we’re strictly dealing with content.&lt;/p&gt;
&lt;p&gt;We will first add all a good doctype (strict), character encoding and the other things needed for validation. I will not go over this again, it was described a couple of weeks ago in the &lt;a href=&#34;/css/beginners-guide-to-css-and-standards/&#34;&gt;beginner&#39;s guide&lt;/a&gt;. This is just copy and paste, so don&#39;t skip this part.&lt;/p&gt;
&lt;p&gt;Aside from that we also need to add some &amp;quot;hooks&amp;quot;, namely classes and ids, to make it easier to style the document (If you don&#39;t know what those two are I recommend you read through the &lt;a href=&#34;/css/beginners-guide-to-css-and-standards/&#34;&gt;beginners guide&lt;/a&gt; before continuing). Good class and id names have something in common: they describe the content. So using &amp;quot;tinyredbar&amp;quot; is a bad name and using &amp;quot;latestnews&amp;quot; is a good one.&lt;/p&gt;
&lt;p&gt;The basics, the bits of HTML we constructed above and the hooks, together form a &lt;a href=&#34;/files/poker/&#34; data-no-instant&gt;good logical structure&lt;/a&gt; to start with. When looking at that page you will notice that it doesn&#39;t &lt;em&gt;look&lt;/em&gt; pretty. When you view the source of it you will see though - that&#39;s what I want to see when I look at the source of your front page. I get all warm when thinking about it; pure, logical, and accessible content. It&#39;s now time to position things where we want them.&lt;/p&gt;
&lt;h2 id=&#34;apply-some-fancy-css&#34;&gt;Apply some fancy CSS&lt;a href=&#34;#apply-some-fancy-css&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;For me the design part always starts with an image program of some sort (Macromedia Fireworks lately for its ease of use). After a while of fiddling around with images and colors I decided to go for something like &lt;a href=&#34;/files/poker/poker-draft.jpg&#34; data-no-instant&gt;this draft&lt;/a&gt; (Note that I&#39;m a programmer rather than a designer so don&#39;t expect wonders here :).&lt;/p&gt;
&lt;p&gt;When you site there with your image in front of you and are on your way to start with the CSS there is one thing you should remember: &lt;em&gt;do the positioning before you do the decoration&lt;/em&gt;. The positioning is the hard part and it &lt;strong&gt;will&lt;/strong&gt; get even harder if you start to mix in colors and fonts. Let&#39;s all follow what I just said and start with the positioning.&lt;/p&gt;
&lt;p&gt;Think of every tag you have on your page as a little box. By &lt;a href=&#34;/files/poker/?style=borders&#34; data-no-instant&gt;enabling borders&lt;/a&gt; on all your elements you can get a good idea of what I&#39;m talking about. When deciding how to position these boxes it&#39;s always wise to start to look at &amp;quot;the flow&amp;quot; of the document. The flow is what you just saw when you looked at the structure above, content is just stacked on top of each other and most tags occupy the full width. By using some clever combinations of floats, clears and widths/heights it is possible to things to line up like we want.&lt;/p&gt;
&lt;h2 id=&#34;positioning-the-header&#34;&gt;Positioning the header&lt;a href=&#34;#positioning-the-header&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;Let&#39;s start by &lt;a href=&#34;/files/poker/poker-draft.png&#34; data-no-instant&gt;looking at the top&lt;/a&gt;. There seems to be four boxes here: a company name, company info, statistics, and the play button. The big image to the right can be added as a background, so we&#39;ll wait with that one. The first two boxes just need a smaller width to be where we want them (compare with how they where positioned in default flow). The last two ones need to be floated left and given a width (this will place them side by side).&lt;/p&gt;
&lt;div class=&#34;highlight&#34; data-language=&#34;CSS&#34;&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;#&lt;/span&gt;&lt;span class=&#34;nn&#34;&gt;header&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;h1&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;   &lt;/span&gt;&lt;span class=&#34;k&#34;&gt;height&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;mi&#34;&gt;65&lt;/span&gt;&lt;span class=&#34;kt&#34;&gt;px&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;   &lt;/span&gt;&lt;span class=&#34;k&#34;&gt;width&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;mi&#34;&gt;400&lt;/span&gt;&lt;span class=&#34;kt&#34;&gt;px&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;#&lt;/span&gt;&lt;span class=&#34;nn&#34;&gt;header&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;p&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;   &lt;/span&gt;&lt;span class=&#34;k&#34;&gt;width&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;mi&#34;&gt;400&lt;/span&gt;&lt;span class=&#34;kt&#34;&gt;px&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;#&lt;/span&gt;&lt;span class=&#34;nn&#34;&gt;header&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;ul&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;   &lt;/span&gt;&lt;span class=&#34;k&#34;&gt;float&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;kc&#34;&gt;left&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;   &lt;/span&gt;&lt;span class=&#34;k&#34;&gt;width&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;mi&#34;&gt;130&lt;/span&gt;&lt;span class=&#34;kt&#34;&gt;px&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;#&lt;/span&gt;&lt;span class=&#34;nn&#34;&gt;header&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;   &lt;/span&gt;&lt;span class=&#34;k&#34;&gt;display&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;kc&#34;&gt;block&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;   &lt;/span&gt;&lt;span class=&#34;k&#34;&gt;height&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;mi&#34;&gt;84&lt;/span&gt;&lt;span class=&#34;kt&#34;&gt;px&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;   &lt;/span&gt;&lt;span class=&#34;k&#34;&gt;width&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;mi&#34;&gt;261&lt;/span&gt;&lt;span class=&#34;kt&#34;&gt;px&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;h2 id=&#34;positioning-the-navigation&#34;&gt;Positioning the navigation&lt;a href=&#34;#positioning-the-navigation&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;Next up we will deal with the navigation and search. Start by adding &lt;code&gt;clear: both&lt;/code&gt; to the navigation to make sure we are below any floats from earlier in the code. To make the navigation list horizontal we add &lt;code&gt;display: inline;&lt;/code&gt; to all list items. We complete the navigation by setting a width on the list and floating it left.&lt;/p&gt;
&lt;p&gt;The search box is a bit harder. All that info won&#39;t fit in the tiny space we have left so my idea is that we hide the fieldset, legend and label. &amp;quot;Why go through the fuzz of adding them and then hiding?&amp;quot;, I hear you shout. Relax. They&#39;re there because they help users that surf the site with CSS turned off, people like your rich grandmother (using Netscape 4), blind users (using screen readers) and Google. Visual users still know that the textbox is for searching because of the &amp;quot;Search&amp;quot; on the button afterwards, so we&#39;re not hiding important information. Ohh, and the header won&#39;t fit our design either so let&#39;s hide that too.&lt;/p&gt;
&lt;div class=&#34;highlight&#34; data-language=&#34;CSS&#34;&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;#&lt;/span&gt;&lt;span class=&#34;nn&#34;&gt;navigation&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;   &lt;/span&gt;&lt;span class=&#34;k&#34;&gt;clear&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;kc&#34;&gt;both&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;   &lt;/span&gt;&lt;span class=&#34;k&#34;&gt;height&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;mi&#34;&gt;41&lt;/span&gt;&lt;span class=&#34;kt&#34;&gt;px&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;   &lt;/span&gt;&lt;span class=&#34;k&#34;&gt;width&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;mi&#34;&gt;720&lt;/span&gt;&lt;span class=&#34;kt&#34;&gt;px&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;#&lt;/span&gt;&lt;span class=&#34;nn&#34;&gt;navigation&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;ul&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;   &lt;/span&gt;&lt;span class=&#34;k&#34;&gt;float&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;kc&#34;&gt;left&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;   &lt;/span&gt;&lt;span class=&#34;k&#34;&gt;list-style&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;kc&#34;&gt;none&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;   &lt;/span&gt;&lt;span class=&#34;k&#34;&gt;width&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;mi&#34;&gt;400&lt;/span&gt;&lt;span class=&#34;kt&#34;&gt;px&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;#&lt;/span&gt;&lt;span class=&#34;nn&#34;&gt;navigation&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;   &lt;/span&gt;&lt;span class=&#34;k&#34;&gt;display&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;kc&#34;&gt;inline&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;#&lt;/span&gt;&lt;span class=&#34;nn&#34;&gt;navigation&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;form&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;   &lt;/span&gt;&lt;span class=&#34;k&#34;&gt;float&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;kc&#34;&gt;right&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;   &lt;/span&gt;&lt;span class=&#34;k&#34;&gt;width&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;mi&#34;&gt;250&lt;/span&gt;&lt;span class=&#34;kt&#34;&gt;px&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;#&lt;/span&gt;&lt;span class=&#34;nn&#34;&gt;navigation&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;legend&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;,&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;p&#34;&gt;#&lt;/span&gt;&lt;span class=&#34;nn&#34;&gt;navigation&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;label&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;,&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;p&#34;&gt;#&lt;/span&gt;&lt;span class=&#34;nn&#34;&gt;navigation&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;h2&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;   &lt;/span&gt;&lt;span class=&#34;k&#34;&gt;position&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;kc&#34;&gt;absolute&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;   &lt;/span&gt;&lt;span class=&#34;k&#34;&gt;left&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;mi&#34;&gt;-10000&lt;/span&gt;&lt;span class=&#34;kt&#34;&gt;px&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;   &lt;/span&gt;&lt;span class=&#34;k&#34;&gt;text-indent&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;mi&#34;&gt;-10000&lt;/span&gt;&lt;span class=&#34;kt&#34;&gt;px&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;   &lt;/span&gt;&lt;span class=&#34;k&#34;&gt;line-height&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;mi&#34;&gt;0&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;#&lt;/span&gt;&lt;span class=&#34;nn&#34;&gt;navigation&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;fieldset&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;   &lt;/span&gt;&lt;span class=&#34;k&#34;&gt;border&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;kc&#34;&gt;none&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;h2 id=&#34;positioning-the-advertisements&#34;&gt;Positioning the advertisements&lt;a href=&#34;#positioning-the-advertisements&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;Ahhh, &lt;acronym title=&#34;advertisements&#34;&gt;ads&lt;/acronym&gt;, both hated and loved at the same time. Not to include ads on a big site like this would just look strange. Let&#39;s position it like we want. First move it down below the navigation by clearing. Then float it right to get it out of the way from the content below.&lt;/p&gt;
&lt;div class=&#34;highlight&#34; data-language=&#34;CSS&#34;&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;#&lt;/span&gt;&lt;span class=&#34;nn&#34;&gt;adverts&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;   &lt;/span&gt;&lt;span class=&#34;k&#34;&gt;clear&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;kc&#34;&gt;both&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;   &lt;/span&gt;&lt;span class=&#34;k&#34;&gt;float&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;kc&#34;&gt;right&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;h2 id=&#34;positioning-the-content&#34;&gt;Positioning the content&lt;a href=&#34;#positioning-the-content&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;This is going well; the content is next up for positioning. Note that I &lt;a href=&#34;/files/poker/&#34; data-no-instant&gt;added a couple of divisions&lt;/a&gt; to this part of the HTML when merging. They will come to good use now as holders of the four sections. Each of the boxes is given a specific width and height and gets floated left.&lt;/p&gt;
&lt;div class=&#34;highlight&#34; data-language=&#34;CSS&#34;&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;#&lt;/span&gt;&lt;span class=&#34;nn&#34;&gt;content&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;div&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;   &lt;/span&gt;&lt;span class=&#34;k&#34;&gt;float&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;kc&#34;&gt;left&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;   &lt;/span&gt;&lt;span class=&#34;k&#34;&gt;height&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;mi&#34;&gt;200&lt;/span&gt;&lt;span class=&#34;kt&#34;&gt;px&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;   &lt;/span&gt;&lt;span class=&#34;k&#34;&gt;width&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;mi&#34;&gt;240&lt;/span&gt;&lt;span class=&#34;kt&#34;&gt;px&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;p&gt;Phew, this feels like a whole days work doesn&#39;t it? On the last page of this tutorial we will put all positioning together and show an example of how everything looks when decorated. Click next below.&lt;/p&gt;
&lt;h2 id=&#34;putting-it-all-together&#34;&gt;Putting it all together&lt;a href=&#34;#putting-it-all-together&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;Now it&#39;s time to take all these small parts of CSS, put them in a CSS-file and &lt;a href=&#34;/files/poker/?style=positioning&#34; data-no-instant&gt;apply it on the structure&lt;/a&gt; we had before positioned. Can you &lt;a href=&#34;/files/poker/positioning.css&#34; data-no-instant&gt;recognize the different parts&lt;/a&gt; from the previous page?&lt;/p&gt;
&lt;p&gt;I could bore you to death by explaining every little margin in the decoration step but I won&#39;t. Instead I will just show you the prettied up version of the site. You can have a look at the &lt;a href=&#34;/files/poker/decoration.css&#34; data-no-instant&gt;second CSS file used&lt;/a&gt; if you want.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;&lt;a href=&#34;/files/poker/?style=positioning&amp;style2=decoration&#34; data-no-instant&gt;Final version of the site&lt;/a&gt;&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;Let&#39;s have a look at the same properties we looked at in the beginning of this article:&lt;/p&gt;
&lt;table summary=&#34;A look at the web standards compliance of the template&#34;&gt;
  &lt;tr&gt;
    &lt;th&gt;
      Site name
    &lt;/th&gt;
    &lt;th&gt;
      Doctype
    &lt;/th&gt;
    &lt;th&gt;
      Validation errors
    &lt;/th&gt;
    &lt;th&gt;
      Layout method
    &lt;/th&gt;
  &lt;/tr&gt;

  &lt;tr&gt;
    &lt;td&gt;
      Friendlybit template
    &lt;/td&gt;
    &lt;td class=&#34;correct&#34;&gt;
      Strict
    &lt;/td&gt;
    &lt;td class=&#34;correct&#34;&gt;
      0 errors
    &lt;/td&gt;
    &lt;td class=&#34;correct&#34;&gt;
      CSS
    &lt;/td&gt;
  &lt;/tr&gt;
&lt;/table&gt;

&lt;h2 id=&#34;summary&#34;&gt;Summary&lt;a href=&#34;#summary&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;I hope this tutorial has showed you that CSS far from rocket science; could you not have done this yourself? The web really needs to be freshened up and made accessible for everyone, and with your help it can. Do your part by telling your friends, by holding a short presentation where you work, and by supporting webmaster you know work like this. Use your imagination, how can you make people understand?&lt;/p&gt;
&lt;p&gt;Still here? Ok. If you&#39;re uncertain, ask yourself: can you afford to be left behind?&lt;/p&gt;
&lt;p&gt;I hope this article gave you some insight to the development of a poker site. This article was the first is a series of articles about &lt;a href=&#34;/css/building-niche-sites-with-standards/&#34;&gt;niche templates&lt;/a&gt; so be sure to check back for more. Any comments?&lt;/p&gt;

            </content>
        </entry>
    
        <entry>
            <title type="html">Cross browser CSS for your site</title>
            <link href="http://friendlybit.com/css/cross-browser-strategies-for-css/" rel="alternate" type="text/html" title="Cross browser CSS for your site" />
            <published>2006-01-13T00:21:39+01:00</published>
            <updated>2006-01-13T00:21:39+01:00</updated>
            <id>http://friendlybit.com/css/cross-browser-strategies-for-css/</id>
            <author>
                <name>Emil Stenström</name>
            </author>
            <summary type="text">This article will go through some useful cross-browser CSS techniques I use to get my sites to look the same in several modern browsers. It&#39;s fairly easy to...</summary>
            <content type="html" xml:base="http://friendlybit.com/css/cross-browser-strategies-for-css/">
                &lt;p&gt;This article will go through some useful cross-browser CSS techniques I use to get my sites to look the same in several modern browsers. It&#39;s fairly easy to send out different versions of your site to different browsers. This should be avoided though since it will end up with you having to maintain the site as if it was in fact several. That defeats the whole purpose with standards, why are they even needed if you are adapting to the browsers instead? My opinion is that good cross-browser coding is to find the set of standards that &lt;em&gt;are&lt;/em&gt; supported and then use them.&lt;/p&gt;
&lt;h2 id=&#34;validate&#34;&gt;Validate your site&lt;a href=&#34;#validate&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;Validation is a much debated area and many &lt;a href=&#34;/css/levels-of-css-knowledge/&#34;&gt;Level 2 bosses&lt;/a&gt; doubt that this procedure really helps. It does help though. It ensures that you didn&#39;t do any simple spelling errors, things that could be incredibly hard to find manually. A validator also checks for nesting errors (did you put a &lt;code&gt;&amp;lt;div&amp;gt;&lt;/code&gt; inside of an anchor?) and other strange things like your character encoding. Information about each of the errors is available as links when they appear, just click on one and you&#39;re on your way to learn something new.&lt;/p&gt;
&lt;p&gt;Validation is the simplest of my tricks to check. There are validators available for both &lt;a href=&#34;http://validator.w3.org/&#34;&gt;(X)HTML&lt;/a&gt; and &lt;a href=&#34;http://jigsaw.w3.org/css-validator/&#34;&gt;CSS&lt;/a&gt;. Use them! Any errors that show up on those lists could be a potential cross-browser breaker so if you decide to ignore any of them you should be really sure about what you are doing. There are reasons why each one of all of the errors on the validation page show up, so validate, fix, validate, fix, validate.&lt;/p&gt;
&lt;h2 id=&#34;mode&#34;&gt;Stay in standards mode&lt;a href=&#34;#mode&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;The next trick is not as obvious. Modern browsers have two rendering modes they use to display websites with: &lt;em&gt;Standards mode&lt;/em&gt; and &lt;em&gt;Quirks mode&lt;/em&gt;. Standards mode is a rendering mode that is made to work according to the W3C specifications as closely as possible and Quirks mode is a bug ridden mode made for older sites. Why have a mode with bugs you ask? It&#39;s a way for browser makers to keep their users happy. When you do big changes to your rendering engine a lot of old sites relying on browser bugs will break. Some might think that this is a good thing, why should sites still work when they are poorly coded? If you think like that you have forgot about who the web is for. It&#39;s not a place for experts only, it&#39;s made for regular users, that is, &lt;em&gt;anyone&lt;/em&gt; with a browser. Those people need to see a working site if that&#39;s possible.&lt;/p&gt;
&lt;p&gt;So a new browser is released with a more standards compliant rendering mode and pages start to break. This is a bad thing for users so browser makers decided to first identify pages that tried to follow the standards, and if they did, switch to the new and improved rendering mode. You will probably see why I recommend standards mode now. All browsers are trying to render things as similar to the specs as possible when in standards mode, while in quirks mode they keep all their old bugs just to help regular users.&lt;/p&gt;
&lt;p&gt;So how do the browsers identify who&#39;s trying to follow standards and who&#39;s not? They use the &lt;em&gt;doctype&lt;/em&gt;. If you&#39;re not familiar with doctypes, don&#39;t worry, they are easy to learn. A doctype is a tag on first line of your site file telling the browser what markup language you will be using. There are basically two doctypes you should select among:&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;HTML 4.01 Strict (what I recommend)&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&#34;highlight&#34; data-language=&#34;HTML&#34;&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;span class=&#34;cp&#34;&gt;&amp;lt;!DOCTYPE HTML PUBLIC &amp;quot;-//W3C//DTD HTML 4.01//EN&amp;quot; &amp;quot;http://www.w3.org/TR/html4/strict.dtd&amp;quot;&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;p&gt;&lt;strong&gt;XHTML 1.0 Strict (without &lt;code&gt;&amp;lt;?xml ...&amp;gt;&lt;/code&gt; on the line before)&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&#34;highlight&#34; data-language=&#34;HTML&#34;&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;span class=&#34;cp&#34;&gt;&amp;lt;!DOCTYPE html PUBLIC &amp;quot;-//W3C//DTD XHTML 1.0 Strict//EN&amp;quot; &amp;quot;http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd&amp;quot;&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;p&gt;Using any of these make sure the browser switches to standards mode and your design not fail because of that. Using a &lt;em&gt;strict&lt;/em&gt; doctype means that you will do your best to separate structure from design and the validator will give you errors in those areas. It&#39;s very useful. (Worth a small note is that the XHTML Transitional doctype also triggers standards mode, but while using transitional you don&#39;t get as many good validation checks so don&#39;t use that one anyways.)&lt;/p&gt;
&lt;p&gt;There is one last catch one needs to talk about when dealing with doctypes and standards mode - &lt;strong&gt;the doctype needs to be the first tag in the document&lt;/strong&gt;. If you put any HTML comments or strange characters before it &lt;acronym title=&#34;Internet Explorer&#34;&gt;IE&lt;/acronym&gt; will go crazy and switch to quirks mode. This has cause many developers countless hours of trying to fix things. Just don&#39;t do it!&lt;/p&gt;
&lt;h2 id=&#34;default&#34;&gt;Remove default styling of elements&lt;a href=&#34;#default&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;Another cause of many web developers screaming in the night is the default CSS that is applied to elements. If you don&#39;t use any CSS at all on your page elements will still have a certain look. Headers will be larger than text paragraphs and blockquotes will have padding. Sizes of text is something that is pretty similar across browsers but something that&#39;s not is padding and margins. Let me give you an example: With no styling an &lt;code&gt;&amp;lt;ul&amp;gt;&lt;/code&gt; gets a padding in Firefox but a margin in IE. Solution? Set either the margin or padding to zero and set the other one to the indentation you want. You need to somehow remove the default browset styles.&lt;/p&gt;
&lt;p&gt;These kinds of problems take up a lot of development time if not handled nicely. &amp;quot;Do definition lists in Opera have padding or margin?&amp;quot;. &amp;quot;What about second level headers in IE 6?&amp;quot;. Two schools of thought have evolved to handling this. The first one tells you to start by resetting &lt;em&gt;all&lt;/em&gt; margins to their defaults at the top of you CSS file. This can easily be done by typing in &lt;span class=&#34;margin: 0; padding: 0; &#34;&gt;&lt;code&gt;*&lt;/code&gt;&lt;/span&gt;, * being a &lt;a href=&#34;http://css.maxdesign.com.au/selectutorial/selectors_universal.htm&#34;&gt;universal selector&lt;/a&gt; that applies the same rules to &lt;em&gt;all&lt;/em&gt; elements.&lt;/p&gt;
&lt;p&gt;Problem solved right? That&#39;s where the second school of thought comes in. They argue that too many default margins are reset. Why should we mess with users form fields, rendering them hard to use unless they are set to good values again? Instead you could just reset those elements that have differences, and leave the rest untouched. This is quite a lot of work to get right so Faruk Ate? built a &amp;quot;starting css&amp;quot; template that you can easily include in your head. Personally I prefer the *-method, but try both and decide for yourself.&lt;/p&gt;
&lt;h2 id=&#34;bugs&#34;&gt;Browser bugs&lt;a href=&#34;#bugs&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;This is the area where CSS gets hard. Even though browser makers work their asses off to follow standards they sometimes don&#39;t reach their goals. This leaves us webmasters with bugs that when fixed triggers new bugs, either in the same or another browser. It can easily get real dirty.&lt;/p&gt;
&lt;p&gt;One of the worst browsers (that is widely in use) is Microsoft&#39;s Internet Explorer, version 6. Some claim they have about 80% of the browser market so it&#39;s not a browser you can just ignore. IE was a good browser when it was first released but by today&#39;s standards it&#39;s certainly not. No other browser caused me more pain while building the design of this page. Its shortcomings get painfully clear when it comes to rendering complex CSS layouts.&lt;/p&gt;
&lt;p&gt;How do you handle these bugs then? The easiest (and fastest) way is not solving it yourself but reading up on someone else&#39;s solution. &amp;quot;Holly &#39;n John&amp;quot; have gathered the most frequent bugs on their page &lt;a href=&#34;http://positioniseverything.net/explorer.html&#34;&gt;Explorer Exposed!&lt;/a&gt;. They give you examples of how to detect the bug, how it works and why (sometimes) and most importantly how to solve it. Sometimes the solution is just setting &lt;code&gt;position: relative;&lt;/code&gt; or &lt;code&gt;display: inline;&lt;/code&gt; on some element and sometimes you have to resort to strange code. The point here is that if your bug is on that page; don&#39;t waste time trying to figure it out yourself. Learn that list by heart.&lt;/p&gt;
&lt;p&gt;So what do you do if your bug isn&#39;t on the list? You start by googling for a solution of course. Googling takes a few minutes compared to the hour you probably need to hunt it down. Don&#39;t underestimate this step.&lt;/p&gt;
&lt;p&gt;If you don&#39;t find it somewhere you need to hunt it down yourself. Do this by making a copy of your page and then removing as much code as you can while keeping the bug. Then find out exactly what line (or lines) of code that causes it and finally try to find another way of doing what triggers it. This is much better than just throwing in hacks, you keep your code maintainable and you learn a lot more useful stuff than if you were throwing in nonsense code from the beginning.&lt;/p&gt;
&lt;p&gt;If you for some reason do not manage to solve the bug with the above technique you either rethink what you are doing (not likely) or you go get your arsenal of hacks. Make sure the hacks are valid code. The one I use for IE when nothing else works is the &amp;quot;* html&amp;quot; hack. You use it but writing like this: &lt;span class=&#34;code; &#34;&gt;&lt;code&gt;* html #element&lt;/code&gt;&lt;/span&gt;. That selector selects all tags that have the child html that have the child #element. But &amp;quot;html&amp;quot; is the topmost element in the hierarchy so nothing is selected, unless IE can choose of course. The code gets applied in IE only. Note that it is perfectly valid CSS, it just doesn&#39;t select anything. Remember: hacks are your &lt;em&gt;last resort&lt;/em&gt; when nothing else works.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Update 18 Jan:&lt;/strong&gt; &lt;a href=&#34;#comment-51&#34;&gt;Richard&lt;/a&gt; in the comments point out that you can also use &lt;a href=&#34;http://www.quirksmode.org/css/condcom.html&#34;&gt;conditional comments&lt;/a&gt; to serve a certain &lt;code&gt;&amp;lt;style&amp;gt; or &amp;lt;link&amp;gt;&lt;/code&gt; to different versions of IE. The &amp;quot;* html&amp;quot;-hack will not work in the comming IE7. Thanks Richard.&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;
&lt;p&gt;I hope you found something useful in this article that you can use when you get cross-browser CSS problems. I have now told you what steps I use, did I miss something? Do you do something differently?&lt;/p&gt;

            </content>
        </entry>
    
        <entry>
            <title type="html">Simple CSS templates</title>
            <link href="http://friendlybit.com/css/simple-css-templates/" rel="alternate" type="text/html" title="Simple CSS templates" />
            <published>2006-01-07T16:25:48+01:00</published>
            <updated>2006-01-07T16:25:48+01:00</updated>
            <id>http://friendlybit.com/css/simple-css-templates/</id>
            <author>
                <name>Emil Stenström</name>
            </author>
            <summary type="text">The most frequent question in the #CSS channel I&#39;m in is about how you make a 2 column layout. Most beginners seems to have problems understanding how...</summary>
            <content type="html" xml:base="http://friendlybit.com/css/simple-css-templates/">
                &lt;p&gt;The most frequent question in the #CSS channel I&#39;m in is about how you make a 2 column layout. Most beginners seems to have problems understanding how floats work since they are quite different from tables. So I sat down and made some simple layout templates for you. These layouts will all be made with floats since that&#39;s the easiest way to do things. I could have set out to use absolute positioning but that can get tricky when it comes to placing the footer. Let&#39;s stay with floats.&lt;/p&gt;
&lt;p&gt;I&#39;ll recap how a floats work. A float is applied by simply setting &lt;code&gt;float: left&lt;/code&gt; or &lt;code&gt;float: right&lt;/code&gt; on an element in your CSS-file. The element then gets pushed as far to the left or right as possible and the next element will follow to the right (if floated left) or left (if floated right). The closest HTML comparision is the effect you get when setting align=&amp;quot;left&amp;quot; on an image. In the beginning it helped me to think of floats like that.&lt;/p&gt;
&lt;p&gt;There are basically two ways to make 2 column layouts with floats. Either you float all the columns (float-float) or you float all but the last one (float-margin). The former method makes it easier to work with clearing inside of the second columns though, so if you&#39;re going for a complex layout float-float might be better. The latter has the advantage that you don&#39;t have to set a width on the last column. It will fill whatever space is availiable. My favourite is still float-margin though, the automatically expanding second column makes sure the the full width is used no matter what.&lt;/p&gt;
&lt;p&gt;For the examples below I will use the HTML I outlined in my previous article about &lt;a href=&#34;/css/beginners-guide-to-css-and-standards/&#34;&gt;CSS basics&lt;/a&gt;.&lt;/p&gt;
&lt;h2 id=&#34;the-float-margin-method&#34;&gt;The float-margin method&lt;a href=&#34;#the-float-margin-method&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;Let&#39;s start by looking at some examples:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&#34;/files/templates/?style=2columns_float_margin&#34; data-no-instant&gt;2 columns using float-margin&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;/files/templates/?style=3columns_float_float_margin&amp;cols=3&#34; data-no-instant&gt;3 columns using float-margin&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Ok, so how does this work? The first example: The navigation is floated left which means that the next element will follow to the right of it. This sounds right but we are forgetting one thing, what happens if the navigation is very short? Then the text in the right column will continue &lt;a href=&#34;/files/templates/float_example.html&#34; data-no-instant&gt;below the float&lt;/a&gt;, probably not what we wanted. So, to fix this we add a margin-left to our content division. Voilà!&lt;/p&gt;
&lt;p&gt;The 3 column example is based on the same idea. Here we start by floating the navigation left, floating the first content block right and finally add margins to the second content block. The last block needs to have both a margin-left and a margin-right to stop the text from continuing below the left and right columns. Makes sense? Take a look at the code and I hope it will.&lt;/p&gt;
&lt;h2 id=&#34;the-float-float-method&#34;&gt;The float-float method&lt;a href=&#34;#the-float-float-method&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;Another method of doing the same is floating each of the columns left. This means that the columns will show up on the webpage in the same order as you put them in the HTML (that was &lt;em&gt;not&lt;/em&gt; the case in the previous example, content1 was to the right and content2 in the middle). Some examples for you:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&#34;/files/templates/?style=2columns_float_float&#34; data-no-instant&gt;2 columns using float-float&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;/files/templates/?style=3columns_float_float_float&amp;cols=3&#34; data-no-instant&gt;3 columns using float-float&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;/files/templates/?style=4columns_float_float_float_float&amp;cols=4&#34; data-no-instant&gt;4 columns using float-float&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;There isn&#39;t much explaination needed here, only thing different from the float-margin method is that you need to set a width on all your columns. You should easily be able to expand this method to kazillion columns :)&lt;/p&gt;
&lt;p&gt;That&#39;s all, be sure to poke around with the different layouts to get a feel of how they work for you. In my next post I will go through some less static layouts, namely elastic and fluid layout. Comments are availiable for questions.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;&lt;strong&gt;Update&lt;/strong&gt;: Added an article on &lt;a href=&#34;/css/what-beginners-ask-for-and-what-i-tell-them/&#34;&gt;Common questions beginners ask&lt;/a&gt;&lt;/p&gt;
&lt;/blockquote&gt;

            </content>
        </entry>
    
        <entry>
            <title type="html">Beginner’s guide to CSS</title>
            <link href="http://friendlybit.com/css/beginners-guide-to-css-and-standards/" rel="alternate" type="text/html" title="Beginner’s guide to CSS" />
            <published>2006-01-05T18:11:00+01:00</published>
            <updated>2006-01-05T18:11:00+01:00</updated>
            <id>http://friendlybit.com/css/beginners-guide-to-css-and-standards/</id>
            <author>
                <name>Emil Stenström</name>
            </author>
            <summary type="text">In the chat channel I&#39;m in, I get to talk to people on a daily basis that have never used CSS before, or are at the very beginning of learning it.. This...</summary>
            <content type="html" xml:base="http://friendlybit.com/css/beginners-guide-to-css-and-standards/">
                &lt;p&gt;In the chat channel I&#39;m in, I get to talk to people on a daily basis that have never used &lt;acronym title=&#34;Cascading StyleSheets&#34;&gt;CSS&lt;/acronym&gt; before, or are at the very beginning of learning it.. This article teaches all the basics you need to make your first CSS powered website. It is aimed at people that know a little &lt;acronym title=&#34;HyperText Markup Language&#34;&gt;HTML&lt;/acronym&gt;, and maybe have made a few websites themselves. Let&#39;s get started.&lt;/p&gt;
&lt;h2 id=&#34;what&#34;&gt;What is CSS?&lt;a href=&#34;#what&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;CSS is a language that adds style (colors, images, borders, margins…) to your site. It&#39;s really that simple. CSS is not used to put any content on your site, it&#39;s just there to take the content you have and make it pretty. First thing you do is link a CSS-file to your HTML document. Do this by adding this line:&lt;/p&gt;
&lt;div class=&#34;highlight&#34; data-language=&#34;HTML&#34;&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;link&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;rel&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;stylesheet&amp;quot;&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;href&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;style.css&amp;quot;&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;type&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;text/css&amp;quot;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;p&gt;The line should be placed in between your &lt;code&gt;&amp;lt;head&amp;gt;&lt;/code&gt; tags. If you have several pages you could add the exact same line to all of them and they will all use the same stylesheet, but more about that later. Let&#39;s look inside the file &amp;quot;style.css&amp;quot; we just linked to.&lt;/p&gt;
&lt;div class=&#34;highlight&#34; data-language=&#34;CSS&#34;&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;h1&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;   &lt;/span&gt;&lt;span class=&#34;k&#34;&gt;font-size&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;mi&#34;&gt;40&lt;/span&gt;&lt;span class=&#34;kt&#34;&gt;px&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;   &lt;/span&gt;&lt;span class=&#34;k&#34;&gt;height&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;mi&#34;&gt;200&lt;/span&gt;&lt;span class=&#34;kt&#34;&gt;px&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;nc&#34;&gt;warning&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;   &lt;/span&gt;&lt;span class=&#34;k&#34;&gt;color&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;kc&#34;&gt;red&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;   &lt;/span&gt;&lt;span class=&#34;k&#34;&gt;font-weight&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;kc&#34;&gt;bold&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;#&lt;/span&gt;&lt;span class=&#34;nn&#34;&gt;footer&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;   &lt;/span&gt;&lt;span class=&#34;k&#34;&gt;background-color&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;kc&#34;&gt;gray&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;p&gt;You have three &lt;dfn&gt;selectors&lt;/dfn&gt; up there, &lt;code&gt;h1&lt;/code&gt;, &lt;code&gt;.warning&lt;/code&gt; and &lt;code&gt;#footer&lt;/code&gt;. A selector simply points to somewhere in your HTML document. It can be built in many ways and can be a combination of the following building blocks:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Element&lt;/li&gt;
&lt;li&gt;Class&lt;/li&gt;
&lt;li&gt;Id&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;I&#39;m going to go through all three of them and explain what they do.&lt;/p&gt;
&lt;p&gt;An &lt;dfn&gt;element&lt;/dfn&gt; points at a HTML-tag somewhere on your page. In the example above we want to style the &lt;code&gt;&amp;lt;h1&amp;gt;&lt;/code&gt;-tag. Note that using an element like that affects all tags with that name, so using &lt;span class=&#34;margin-left: 100px; &#34;&gt;&lt;code&gt;p&lt;/code&gt;&lt;/span&gt; gives &lt;em&gt;all&lt;/em&gt; &lt;code&gt;p&lt;/code&gt;-tags a left-margin.&lt;/p&gt;
&lt;p&gt;Using a &lt;dfn&gt;class&lt;/dfn&gt; is just as simple. When writing &lt;code&gt;.your_class&lt;/code&gt; you style all tags with a class with the name &amp;quot;your_class&amp;quot;. In the example above we have &lt;code&gt;.warning&lt;/code&gt; which will style e.g. &lt;code&gt;&amp;lt;div class=&amp;quot;warning&amp;quot;&amp;gt;&lt;/code&gt; and &lt;code&gt;&amp;lt;em class=&amp;quot;warning&amp;quot;&amp;gt;&lt;/code&gt;, that is, any element with the class warning. Classes are used when you want to style just a few of your tags in a way, perhaps you want some of your links red? Add a class to all those links.&lt;/p&gt;
&lt;p&gt;You need one more building block: the &lt;dfn&gt;id&lt;/dfn&gt;. This time you style an element with the attribute &amp;quot;id&amp;quot; set to the id you have chosen. Ids work exactly like classes except for one thing; you can only have one id with a certain name in each of your HTML documents. In the example above we style &lt;code&gt;&amp;lt;div id=&amp;quot;footer&amp;quot;&amp;gt;&lt;/code&gt;. If you look at the example it does make sense: a HTML document may contain several warnings but only one footer. Ids should be used when you want to style just one specific tag.&lt;/p&gt;
&lt;p&gt;Using those three building blocks will take you far but when you get to more advanced layouts you might want to combine the building blocks into more advanced selectors. Just to give you two examples of what you can do: &lt;code&gt;em.warning&lt;/code&gt; to style only those &lt;code&gt;&amp;lt;em&amp;gt;&lt;/code&gt;-tags with the class &lt;code&gt;.warning&lt;/code&gt; set. You can also use &lt;code&gt;#footer a&lt;/code&gt; to style only the links that are nested inside the tag with id &amp;quot;footer&amp;quot;. Pretty nice, isn&#39;t it?&lt;/p&gt;
&lt;p&gt;I could go on forever about the advanced uses of selectors but this is a beginner tutorial so I won&#39;t. If you want all the finer details, go have a look at the excellent &lt;a href=&#34;http://css.maxdesign.com.au/selectutorial/&#34;&gt;Maxdesigns Selectutorial&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Let&#39;s go on explaining the code above. Each of the selectors has a set of &lt;dfn&gt;declarations&lt;/dfn&gt; tied to them. Each declaration has a &lt;dfn&gt;property&lt;/dfn&gt;, describing what we want to change and a &lt;dfn&gt;value&lt;/dfn&gt;, what we should change it to. Too many terms there? Are you still with me? Let me explain with an example: &lt;span class=&#34;color: Blue; font-size: 3em; &#34;&gt;&lt;code&gt;a&lt;/code&gt;&lt;/span&gt;. You have the &lt;dfn&gt;selector&lt;/dfn&gt; &lt;code&gt;a&lt;/code&gt; there, so all links in your document will be styled. We have two &lt;dfn&gt;declarations&lt;/dfn&gt;: &lt;code&gt;color: Blue&lt;/code&gt; and &lt;code&gt;font-size: 3em;&lt;/code&gt;. Lastly each declaration consists of two parts: the &lt;dfn&gt;property&lt;/dfn&gt; &lt;code&gt;color&lt;/code&gt; and the &lt;dfn&gt;value&lt;/dfn&gt; &lt;code&gt;Blue&lt;/code&gt;. Phew! Well done for making it this far. The terms above are good to know since it gives you a way to talk about your CSS. If you join a CSS-channel asking for help with your code and they tell you &amp;quot;You have an error in your a-selector in the second declaration&amp;quot; you know exactly where! Right? :)&lt;/p&gt;
&lt;p&gt;Now you will probably ask what properties there are. You have seen &lt;code&gt;font-size&lt;/code&gt; and &lt;code&gt;color&lt;/code&gt; but what else is there? The answer is that there are a &lt;em&gt;LOT&lt;/em&gt; of things you can style and play with. Additionally (close to) all tags are equal in CSS, so you can set e.g. borders and colors of &lt;em&gt;any&lt;/em&gt; element just like you could with a table if you used only HTML. Starting to see the possibilities?&lt;/p&gt;
&lt;p&gt;I won&#39;t go through all the properties here, it would just bore you to death. Instead I&#39;ll point you to another great resource: &lt;a href=&#34;http://www.w3schools.com/css/&#34;&gt;w3schools section about CSS&lt;/a&gt;. Just select one of the menu options to the left to start exploring what CSS can do.&lt;/p&gt;
&lt;p&gt;But don&#39;t you leave me all alone here, there is more to learn! Next we will talk about good and bad coding and there will be a lot of colorful examples for you. Sounds good?&lt;/p&gt;
&lt;h2 id=&#34;separation&#34;&gt;CSS is all about separation&lt;a href=&#34;#separation&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;One of the least followed parts of CSS is the very idea behind it, the idea of separation of content and design. The idea here is that all sites contain two major parts, the content: all your articles, text and photos and the design: rounded corners, colors and effects. Usually those two are made in different parts of a webpage&#39;s lifetime. The design is determined at the beginning and then you start filling it with content and keep the design fixed. So if you just want to add content to your site you don&#39;t want to be forced to mess around with the design, do you? The same thing is true the other way around, if you decide on a redesign, why should you have to mess around with the content, making sure it fits in the new layout?&lt;/p&gt;
&lt;p&gt;In CSS you just add the nifty &lt;code&gt;&amp;lt;link&amp;gt;&lt;/code&gt;-tag I&#39;ve told you about to the head of your HTML document and you have created a link to your design. In the HTML document you put content only, and that link of yours makes sure it looks right. You can also use the exact same link on many of your pages, giving them all of them the same design. You want to add content? Just write a plain HTML document and think about marking things up like &amp;quot;header&amp;quot; instead of &amp;quot;big blue header&amp;quot; and use CSS to make &lt;em&gt;all&lt;/em&gt; headers look the way you want!&lt;/p&gt;
&lt;p&gt;This is a different way of thinking about webpages, and it&#39;s something that took a while for me to understand. To help you I have written some examples of good and bad coding. What&#39;s wrong with this?&lt;/p&gt;
&lt;div class=&#34;incorrect&#34;&gt;&lt;div class=&#34;highlight&#34; data-language=&#34;HTML&#34;&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;font&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;size&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;3&amp;quot;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;Welcome to my page&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;font&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;&lt;p&gt;Comment: The font-tag is design and design shouldn&#39;t be in the HTML document. All design should be in the CSS-file! Instead do this:&lt;/p&gt;
&lt;p&gt;In the HTML:&lt;/p&gt;
&lt;div class=&#34;correct&#34;&gt;&lt;div class=&#34;highlight&#34; data-language=&#34;HTML&#34;&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;h1&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;Welcome to my page&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;h1&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;&lt;p&gt;In the CSS:&lt;/p&gt;
&lt;div class=&#34;correct&#34;&gt;&lt;div class=&#34;highlight&#34; data-language=&#34;CSS&#34;&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;h1&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;k&#34;&gt;font-size&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;mi&#34;&gt;2&lt;/span&gt;&lt;span class=&#34;kt&#34;&gt;em&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;&lt;p&gt;One more example:&lt;/p&gt;
&lt;div class=&#34;incorrect&#34;&gt;&lt;div class=&#34;highlight&#34; data-language=&#34;HTML&#34;&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;b&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;An error occurred&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;b&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;&lt;p&gt;Comment: This looks right doesn&#39;t it? But if you look up what &lt;code&gt;&amp;lt;b&amp;gt;&lt;/code&gt; stands for you quickly find &lt;em&gt;bold&lt;/em&gt;. But bold is certainly design, so it still doesn&#39;t belong in the HTML document. A better choice is &lt;code&gt;&amp;lt;em&amp;gt;&lt;/code&gt; that stands for &lt;em&gt;emphasis&lt;/em&gt; or simply &amp;quot;this piece of text is important&amp;quot;. So instead of saying &amp;quot;this text looks like this&amp;quot; you are saying &amp;quot;this text is important&amp;quot; and you let the looks be decided by the CSS. Seems like a minor change, but it illustrates how to select your tags. Use this instead:&lt;/p&gt;
&lt;p&gt;In the HTML:&lt;/p&gt;
&lt;div class=&#34;correct&#34;&gt;&lt;div class=&#34;highlight&#34; data-language=&#34;HTML&#34;&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;em&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;An error occured&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;em&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;&lt;p&gt;In the CSS:&lt;/p&gt;
&lt;div class=&#34;correct&#34;&gt;&lt;div class=&#34;highlight&#34; data-language=&#34;CSS&#34;&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;em&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;   &lt;/span&gt;&lt;span class=&#34;k&#34;&gt;font-weight&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;kc&#34;&gt;bold&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;   &lt;/span&gt;&lt;span class=&#34;k&#34;&gt;color&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;n&#34;&gt;Red&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;&lt;p&gt;One last example:&lt;/p&gt;
&lt;div class=&#34;incorrect&#34;&gt;&lt;div class=&#34;highlight&#34; data-language=&#34;HTML&#34;&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;table&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
  &lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;tr&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
    &lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;td&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;href&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;&amp;quot;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;first link&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;td&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
  &lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;tr&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
  &lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;tr&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
    &lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;td&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;href&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;&amp;quot;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;second link&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;td&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
  &lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;tr&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
  ...
&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;table&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;&lt;p&gt;Comment: Lots of people format their navigation menu like the above example. But is a navigation menu really a table? If you look up the definition of a table you see that it&#39;s made for tabular data, the same kind of data you would put in an Excel sheet. The example has only one column of data, and no headers… Some people state that they use tables because that means that they can get borders and a background color on their navigation, but that&#39;s exactly what your CSS file is for (not the HTML document). So what should we do? Look deep in the list of &lt;a href=&#34;http://www.w3schools.com/html/&#34;&gt;HTML elements at w3schools&lt;/a&gt; and you&#39;ll find something called an unordered list, &lt;code&gt;&amp;lt;ul&amp;gt;&lt;/code&gt;. Have a look at this:&lt;/p&gt;
&lt;p&gt;In the HTML:&lt;/p&gt;
&lt;div class=&#34;correct&#34;&gt;&lt;div class=&#34;highlight&#34; data-language=&#34;HTML&#34;&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;ul&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
  &lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;href&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;&amp;quot;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;first link&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
  &lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;href&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;&amp;quot;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;second link&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
  ...
&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;ul&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;&lt;p&gt;In the CSS:&lt;/p&gt;
&lt;div class=&#34;correct&#34;&gt;&lt;div class=&#34;highlight&#34; data-language=&#34;CSS&#34;&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;   &lt;/span&gt;&lt;span class=&#34;k&#34;&gt;border&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;mi&#34;&gt;1&lt;/span&gt;&lt;span class=&#34;kt&#34;&gt;px&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;kc&#34;&gt;solid&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;&lt;p&gt;This is probably a different way of thinking about HTML than you&#39;re used to but trust me, when you&#39;ve worked with it for a while you&#39;ll see the power of it. Not only does this way of coding give you a more logical structure, there is also proof that this improves your ranking in search engines and makes it easier for accessibility devices to read your site. This way of designing is great.&lt;/p&gt;
&lt;p&gt;Next we will build a simple HTML template to use as a start when building a new page. Like to see it?&lt;/p&gt;
&lt;h2 id=&#34;building-a-standards-based-html-template&#34;&gt;Building a standards based HTML template&lt;a href=&#34;#building-a-standards-based-html-template&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;We have talked a lot about the theory behind CSS and HTML working together to form a site with good structure that is separated from the design. But the first parts of building pages are always the same, you type&lt;/p&gt;
&lt;div class=&#34;highlight&#34; data-language=&#34;HTML&#34;&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;span class=&#34;cp&#34;&gt;&amp;lt;!doctype html&amp;gt;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;html&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
  &lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;body&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
    &lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;div&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;id&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;header&amp;quot;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
       &lt;span class=&#34;cm&#34;&gt;&amp;lt;!-- Header here! --&amp;gt;&lt;/span&gt;
    &lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;div&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
    &lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;div&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;id&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;navigation&amp;quot;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
      &lt;span class=&#34;cm&#34;&gt;&amp;lt;!-- Navigaiton here! --&amp;gt;&lt;/span&gt;
    &lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;div&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
    &lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;div&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;id&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;content&amp;quot;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
      &lt;span class=&#34;cm&#34;&gt;&amp;lt;!-- Content here --&amp;gt;&lt;/span&gt;
    &lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;div&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
  &lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;body&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;html&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;p&gt;Ok, there might be some new stuff there so let&#39;s go through the lines one by one. First we state this document&#39;s doctype: what language we use. You might have heard of XHTML, another similar web language, but for a first page we don&#39;t need the features that gives us access to, keep it simple, just go with HTML. Also, the &lt;code&gt;&amp;lt;!doctype html&amp;gt;&lt;/code&gt; above sets the document to use &lt;em&gt;Strict&lt;/em&gt; HTML. To understand that you need to know that there are two kinds of rendering in a browser. One that follows the standards set up by the &lt;a href=&#34;http://www.w3c.org&#34;&gt;W3C&lt;/a&gt;, &lt;dfn&gt;&amp;quot;standards mode&amp;quot;&lt;/dfn&gt;, and one for older pages, called &lt;dfn&gt;&amp;quot;quirks mode&amp;quot;&lt;/dfn&gt;. Standards mode is what we want to use. It makes the pages render (almost) the same in modern browsers and it frees us from being dependent on a specific browser, we&#39;ll just follow the standard. Quirks mode is something of a bug mode. It&#39;s there to keep old pages looking the same as they did before browsers started trying to follow the standards and is therefore intentionally filled with strange bugs. A browser determines which rendering mode to use based on what doctype we use, so make sure you use the right one!&lt;/p&gt;
&lt;p&gt;Ok. That&#39;s a lot of explaining for a single line of code, I&#39;ll be swifter now, next line. You have probably written &lt;code&gt;&amp;lt;html&amp;gt;&lt;/code&gt; before in the beginning of your documents. My line is almost like that except that I have added &lt;code&gt;lang=&amp;quot;en&amp;quot;&lt;/code&gt; there. That line tells the browser which language we will use. Why does it matter what language we use? you ask… Well, there is assistive technology that read webpages to people out loud called screen readers. Those &lt;em&gt;have to&lt;/em&gt; know what language it is to be able to pronounce the words. It&#39;s so easy for you to add those few characters so why not do it? If you don&#39;t plan on making an English page you can find your own language code by visiting &lt;a href=&#34;http://www.w3.org/WAI/ER/IG/ert/iso639.htm#2letter&#34;&gt;WAIs Language Codes&lt;/a&gt; and check out the two-letter names there (&lt;em&gt;Note:&lt;/em&gt; language codes are in lowercase).&lt;/p&gt;
&lt;p&gt;Next we have the &lt;em&gt;head&lt;/em&gt; of the document. The head contains a some of meta-information about the page, like character encoding, title and what stylesheet (CSS file) to use. The charset there is the trickiest one so let&#39;s take that first. There are a lot of different letters in a language. When computers where first constructed the engineers only thought about the American/English language, they didn&#39;t even think about the swedish letters å, ä, ö or the deutsch umlaut ü or what about the &amp;amp;-sign? There are a lot of characters and at first there was no general consensus on how to handle them. Then someone came up with the smart idea of grouping them into &lt;em&gt;sets&lt;/em&gt;, groups of characters that are used in certain parts of the world. So, what the meta-tag does is simply to state: &amp;quot;This person wants to input western characters (latin-1 characters)&amp;quot;, and this tells the browser what character set to use. A more genaral approach is to use the utf-8 character set but that quickly gets tricky. Finally we have a text/html there that simply tells the server to send the document as a HTML, not like an image or something like that. The &lt;code&gt;&amp;lt;title&amp;gt;&lt;/code&gt; and &lt;code&gt;&amp;lt;link&amp;gt;&lt;/code&gt; you should be familiar with, if not, google it :)&lt;/p&gt;
&lt;p&gt;That was a lot of info on just a few lines of code, I hope I didn&#39;t give the impression that this stuff is hard, because it&#39;s not. To use the stuff above you just copy and paste it and start filling it with content.&lt;/p&gt;
&lt;p&gt;The body of the document consists of a bunch of divisions, let&#39;s add some content to them:&lt;/p&gt;
&lt;div id=&#34;semantics&#34;&gt;&lt;/div&gt;

&lt;div class=&#34;highlight&#34; data-language=&#34;HTML&#34;&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;...
&lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;div&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;id&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;header&amp;quot;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
  &lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;h1&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;The name of this page&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;h1&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;div&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;div&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;id&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;navigation&amp;quot;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
  &lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;h2&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;Navigation&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;h2&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
  &lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;ul&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
  &lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;href&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;first.html&amp;quot;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;First&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
  &lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;href&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;second.html&amp;quot;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;Second&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
  &lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;href&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;third.html&amp;quot;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;Third&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
  &lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;ul&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;div&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;div&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;id&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;content&amp;quot;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
  &lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;h2&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;Content&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;h2&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
  Some sample content, add your own here
&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;div&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;div&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;id&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;footer&amp;quot;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
  This page is written by [Your name] and builds on a &lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;href&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;http://friendlybit.com&amp;quot;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;Friendlybit template&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;.
&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;div&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
...
&lt;/pre&gt;&lt;/div&gt;
&lt;p&gt;What have we done here? First you should note that a quick overview of the document tells you quite much about the content. You can easily see that some stuff are headers (h1, h2) and some are just a list of links (ul, li, a). Let&#39;s go through the code quickly:&lt;/p&gt;
&lt;p&gt;First we have a header. A header is something that&#39;s most often a big image and some text. Some pages don&#39;t have the header in the HTML at all, they just link to an image and have the text in that image. Problem with that is that neither search engines nor screen readers can get the title text. With the title text being the most important piece of description a visitor has to what page they have come to, you do have a problem. So trust me, keep that text there.&lt;/p&gt;
&lt;p&gt;Next up we have the navigation. Navigation should almost always be marked up as an unordered list of links. I&#39;ve seen the strangest variants of this with tables, nested tables, ``-tags after each line and so on but the only content there is a list of links, why make it something it isn&#39;t? Using a list doesn&#39;t mean it will have to look a certain way, remember that all design is handled in the CSS later on, this is just HTML we are dealing with here. Note: you can easily remove the bullet marks with &lt;code&gt;list-style: none;&lt;/code&gt;, that&#39;s not a reason to use some other HTML.&lt;/p&gt;
&lt;p&gt;The most important part of your HTML document is the content. This is the reason people will visit your page and this is where you should put most of your effort. Mark your headers with appropriate header-tags and make sure they look different from the ordinary text, this makes it easier quickly get a grip of what you&#39;re are trying to say. Use paragraph tags around your paragraphs to make is easier to style your text. The CSS &lt;code&gt;text-indent: 2em;&lt;/code&gt; adds some space before only the first word in each paragraph, just to name one simple thing you can do with CSS when you&#39;ve used good markup.&lt;/p&gt;
&lt;p&gt;Lastly, it could be a good idea to add a footer to your page. Make sure you have some kind of contact information here or somewhere else on your site, who knows what people will want to ask you? If you want to help me you could add a link to this site somewhere on your site too. If you do, thanks alot!&lt;/p&gt;
&lt;p&gt;On the next (and last) page of this short beginners guide we will wrap everything up and add some sample CSS to the mix. All is free for you to copy and use on your page. Ready?&lt;/p&gt;
&lt;h2 id=&#34;full-html-template-and-sample-css&#34;&gt;Full HTML template and sample CSS&lt;a href=&#34;#full-html-template-and-sample-css&#34;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;Let&#39;s start by putting the two pieces of HTML I showed you together and combine it with some sample CSS: &lt;a href=&#34;/files/example1/&#34; data-no-instant&gt;Sample HTML + CSS&lt;/a&gt;. You can find all code that makes that page below. Feel free to copy the code below and experiment on your own.&lt;/p&gt;
&lt;div class=&#34;highlight&#34; data-language=&#34;HTML&#34;&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;span class=&#34;cp&#34;&gt;&amp;lt;!doctype html&amp;gt;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;html&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;lang&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;en&amp;quot;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
  &lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;body&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
    &lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;div&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;id&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;header&amp;quot;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
      &lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;h1&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;The name of this page&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;h1&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
    &lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;div&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
    &lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;div&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;id&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;navigation&amp;quot;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
      &lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;h2&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;Navigation&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;h2&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
      &lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;ul&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
        &lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;href&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;first.html&amp;quot;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;First&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
        &lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;href&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;second.html&amp;quot;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;Second&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
        &lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;href&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;third.html&amp;quot;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;Third&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
      &lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;ul&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
    &lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;div&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
    &lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;div&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;id&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;content&amp;quot;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
      &lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;h2&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;Content&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;h2&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
      Some sample content, add your own here
    &lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;div&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
    &lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;div&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;id&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;footer&amp;quot;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
      This page is written by [Your name] and builds on a &lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;href&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;quot;http://friendlybit.com&amp;quot;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;Friendlybit template&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;.
    &lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;div&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
  &lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;body&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;html&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;p&gt;You should be able to tell what each part of the HTML does by now. Let&#39;s instead have a look at some sample CSS for the structure we have above. If you want to experiment with this code you can copy it to a file named style.css (or any other filename you reference in the &lt;code&gt;&amp;lt;link&amp;gt;&lt;/code&gt;-tag in the HTML) and place it in the same directory as the HTML document.&lt;/p&gt;
&lt;div class=&#34;highlight&#34; data-language=&#34;CSS&#34;&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;body&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;	&lt;/span&gt;&lt;span class=&#34;k&#34;&gt;background-color&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;n&#34;&gt;Green&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;span class=&#34;nt&#34;&gt;div&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;	&lt;/span&gt;&lt;span class=&#34;k&#34;&gt;border&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;mi&#34;&gt;3&lt;/span&gt;&lt;span class=&#34;kt&#34;&gt;px&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;kc&#34;&gt;solid&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;n&#34;&gt;Black&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;	&lt;/span&gt;&lt;span class=&#34;k&#34;&gt;padding&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;mi&#34;&gt;7&lt;/span&gt;&lt;span class=&#34;kt&#34;&gt;px&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;	&lt;/span&gt;&lt;span class=&#34;k&#34;&gt;width&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;mi&#34;&gt;600&lt;/span&gt;&lt;span class=&#34;kt&#34;&gt;px&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;span class=&#34;nt&#34;&gt;h1&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;,&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;h2&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;,&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;h3&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;,&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;h4&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;,&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;h5&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;,&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;h6&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;	&lt;/span&gt;&lt;span class=&#34;k&#34;&gt;margin&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;mi&#34;&gt;0&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;#&lt;/span&gt;&lt;span class=&#34;nn&#34;&gt;navigation&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;	&lt;/span&gt;&lt;span class=&#34;k&#34;&gt;float&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;kc&#34;&gt;left&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;	&lt;/span&gt;&lt;span class=&#34;k&#34;&gt;width&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;mi&#34;&gt;150&lt;/span&gt;&lt;span class=&#34;kt&#34;&gt;px&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;#&lt;/span&gt;&lt;span class=&#34;nn&#34;&gt;content&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;	&lt;/span&gt;&lt;span class=&#34;k&#34;&gt;float&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;kc&#34;&gt;left&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;	&lt;/span&gt;&lt;span class=&#34;k&#34;&gt;width&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;mi&#34;&gt;430&lt;/span&gt;&lt;span class=&#34;kt&#34;&gt;px&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;#&lt;/span&gt;&lt;span class=&#34;nn&#34;&gt;footer&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;span class=&#34;w&#34;&gt;	&lt;/span&gt;&lt;span class=&#34;k&#34;&gt;clear&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;kc&#34;&gt;both&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;p&gt;Let&#39;s go through the six rules above. First we set the background-color of body, and body is the background of everything, so this will do the same as bgcolor did in HTML.&lt;/p&gt;
&lt;p&gt;Next we set some styles on all divisions on the page. We have four of them and with this single rule we affect them all. First we set a black border to be 3 pixels wide (note that there is no space between number and unit in CSS). We then set a padding (the space between the border and content) to be 7 pixels and lastly we set the width of all divs to 600 pixels (note that margins, borders and padding are not included in the width).&lt;/p&gt;
&lt;p&gt;The third rule selects all headers on the page and removes the margins (the space between the border and other nearby elements) from them. The commas are used between the elements to apply the same CSS to all of them.&lt;/p&gt;
&lt;p&gt;Next we have some specific rules for three of the divisions. We position the navigation to the left of the content. This is done by using &lt;dfn&gt;floats&lt;/dfn&gt;, a way to put things side by side. If you have used the align-attribute on images in HTML you will know how floats work, they move the element as far to the left as possible and then let the next element follow right next to it. If you want to put something below a float you need to &lt;dfn&gt;clear&lt;/dfn&gt; it. Clearing moves the element down until it&#39;s below any floats, exactly where we want the footer. So both navigation and content are floated and given a width to match the 600 pixels wide header, and the footer is cleared.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Update:&lt;/strong&gt; I have added some &lt;a href=&#34;/css/simple-css-templates/&#34;&gt;simple layouts&lt;/a&gt; for you to look at, and a list of &lt;a href=&#34;/css/web-development-pack/&#34;&gt;tools I use when developing&lt;/a&gt;. Hope they help all of you out there that learn by examples.&lt;/p&gt;
&lt;p&gt;Now it&#39;s your turn, you will learn CSS by using it and trying out how things work. So go ahead and play with the sample above. Thanks for reading, and good luck!&lt;/p&gt;
&lt;p&gt;Any ideas of how this guide could be improved? Just leave a comment to the right.&lt;/p&gt;

            </content>
        </entry>
    
</feed>