<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:blogger='http://schemas.google.com/blogger/2008' xmlns:georss='http://www.georss.org/georss' xmlns:gd="http://schemas.google.com/g/2005" xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-398584839682458587</id><updated>2024-08-29T03:00:50.336-07:00</updated><category term="IE"/><category term="Java"/><category term="JavaScript"/><category term="Android"/><category term="Apple"/><category term="Google"/><category term="HTML"/><category term="HTML 5"/><category term="IDE"/><category term="IE9"/><category term="Netbeans"/><category term="REST"/><category term="SMTP"/><category term="Windows 7"/><category term="class"/><category term="code"/><category term="date"/><category term="email"/><category term="frameworks"/><category term="iOS"/><category term="jQuery"/><category term="microtemplating"/><category term="mobile"/><category term="regexp"/><category term="regular expression"/><category term="snippet"/><category term="style"/><category term="syntax highlighting"/><category term="template"/><category term="web services"/><title type='text'>Tempoc&#39;s Dev Blog</title><subtitle type='html'>Making sure I don&#39;t end up looking for the same answer twice.</subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://tempocdev.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/398584839682458587/posts/default?redirect=false'/><link rel='alternate' type='text/html' href='http://tempocdev.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>Gabriel F. Rodríguez</name><uri>http://www.blogger.com/profile/10332533752137475497</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>19</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>25</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-398584839682458587.post-2733664450221288958</id><published>2012-11-14T09:32:00.000-08:00</published><updated>2012-11-14T09:32:26.442-08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="code"/><category scheme="http://www.blogger.com/atom/ns#" term="date"/><category scheme="http://www.blogger.com/atom/ns#" term="Java"/><category scheme="http://www.blogger.com/atom/ns#" term="snippet"/><title type='text'>Days of a Month</title><content type='html'>Here&#39;s a little something that&#39;s useful. Just give me some credit for putting it together. Syntax is in Java, but it should be translatable to your favorite language.&lt;br /&gt;
&lt;br /&gt;
Given the month number, m [1, 12], and the 4-digit year, this calculates the days of the month.&lt;br /&gt;
&lt;br /&gt;
&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;return m != 2 ? (((m &amp;lt; 8 &amp;amp;&amp;amp; m % 2 != 0) || (m &amp;gt; 7 &amp;amp;&amp;amp; m % 2 == 0)) ? 31 : 30) : (!(year % 400 == 0 || year % 100 != 0 &amp;amp;&amp;amp; year % 4 == 0) ? 28 : 29);&lt;/span&gt;</content><link rel='replies' type='application/atom+xml' href='http://tempocdev.blogspot.com/feeds/2733664450221288958/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://tempocdev.blogspot.com/2012/11/days-of-month.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/398584839682458587/posts/default/2733664450221288958'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/398584839682458587/posts/default/2733664450221288958'/><link rel='alternate' type='text/html' href='http://tempocdev.blogspot.com/2012/11/days-of-month.html' title='Days of a Month'/><author><name>Gabriel F. Rodríguez</name><uri>http://www.blogger.com/profile/10332533752137475497</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-398584839682458587.post-2455489625131881254</id><published>2012-06-25T15:29:00.000-07:00</published><updated>2012-06-25T15:29:56.568-07:00</updated><title type='text'>Google IO 2012</title><content type='html'>I&#39;ll be following some of the live sessions of Google IO 2012 and being a loud-mouth if I feel like it. You can watch it &lt;a href=&quot;http://tempocdev.blogspot.com/p/google-io-2012-live-blog.html&quot; target=&quot;_blank&quot;&gt;here&lt;/a&gt; and follow any Google announcements, and get the commentary.</content><link rel='replies' type='application/atom+xml' href='http://tempocdev.blogspot.com/feeds/2455489625131881254/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://tempocdev.blogspot.com/2012/06/google-io-2012.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/398584839682458587/posts/default/2455489625131881254'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/398584839682458587/posts/default/2455489625131881254'/><link rel='alternate' type='text/html' href='http://tempocdev.blogspot.com/2012/06/google-io-2012.html' title='Google IO 2012'/><author><name>Gabriel F. Rodríguez</name><uri>http://www.blogger.com/profile/10332533752137475497</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-398584839682458587.post-2534368046426329288</id><published>2012-04-03T14:54:00.002-07:00</published><updated>2012-04-05T10:45:47.900-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Android"/><category scheme="http://www.blogger.com/atom/ns#" term="Apple"/><category scheme="http://www.blogger.com/atom/ns#" term="Google"/><category scheme="http://www.blogger.com/atom/ns#" term="iOS"/><category scheme="http://www.blogger.com/atom/ns#" term="mobile"/><title type='text'>Android: Cutting edge tech 2 years behind</title><content type='html'>&lt;div&gt;
iOS and Android have never been at a loss for die-hard fans, but ever since Android was introduced they have both been competing for the &lt;i&gt;virgin&lt;/i&gt;&amp;nbsp;customer. In my opinion what dispenses points of market share one way or the other boils down to 2 things: Who strikes first, and the impact caused during that first strike. When it comes to technology they constantly outdo each other. But what, from the jockeys&#39; seat, might look like a daily photo-finish actually looks like Android never left the gate, to most bettors.&lt;br /&gt;
&lt;h2&gt;


&lt;span style=&quot;font-weight: normal;&quot;&gt;Some History&lt;/span&gt;&lt;/h2&gt;
When Apple came out with the iPhone in January, 2007, it certainly was a game-changer, but being the first of its kind also meant that some lessons would only be learned with time. Some things were foreseeable. Clearly Apple was planning to roll out more apps as time went by. Some other things escaped Apple&#39;s foresight. During the first 2 years Apple modified the OS to devote more resources to call handling, changed the keyboard to allow multi-touch key presses, and introduced much desired features like a dedicated &lt;i&gt;Gmail &lt;/i&gt;account type button in &lt;i&gt;Settings&lt;/i&gt;.&lt;br /&gt;
&lt;br /&gt;
Android&#39;s roll-out was in many ways analogous to that of iPhone OS. The first Android phone didn&#39;t reach the market until September, 2008, and although then the difference in capabilities between the two platforms was vast they&#39;ve matured technologically to the point where they are more or less evenly capable. For the record, this article&#39;s focus is not the difference in original roll-out dates of the platforms.&lt;br /&gt;
&lt;h2&gt;


&lt;span style=&quot;font-weight: normal;&quot;&gt;Android&#39;s Permanent 2-year Lag&lt;/span&gt;&lt;/h2&gt;
The case of the &lt;i&gt;virgin&lt;/i&gt;&amp;nbsp;customer is unique. Whatever the phone selected the customer is likely to be pleasantly surprised to find what a phone has become. And if the customer is like most mobile phone owners he&#39;ll be tied to that piece of hardware for 2 years or pay a premium to change it. So why does this only affect Android negatively? Strategy, or lack, thereof.&lt;br /&gt;
&lt;br /&gt;
When a customer purchases an iPhone he can&#39;t make a wrong choice. There&#39;s only one choice (in 2 colors, 2 memory capacities). There won&#39;t be any guilt associated with having selected the wrong device. Even better: he can rely on Apple&#39;s track record to hope that, although the hardware will look two generations less tasty in 2 years, the manufacturer won&#39;t consider his phone obsolete during that time and he&#39;ll be entitled to prompt bug fixes and releases of the best features his hardware can handle. Warm and fuzzy at no extra cost. Your phone may come to be 2 years old, but it will never feel quite &lt;i&gt;that&lt;/i&gt;&amp;nbsp;old.&lt;br /&gt;
&lt;br /&gt;
If the customer purchases an Android device the experience is the opposite. Many flavors to choose from, from a choice of manufacturers, most with a good portion of bloatware, some with spyware right out of the box. Of course no one will tell this to the customer before the purchase, so some guilt is included for free with every purchase. But wait, there&#39;s more! Even after Google tried to get manufacturers to make a commitment to keep the phones regularly up to date with reasonably recent features and bug fixes the task is easier said than done and probably not policed. Your phone may come to be 2 years old, and it will &lt;i&gt;most definitely&lt;/i&gt;&amp;nbsp;feel 2 years old.&lt;br /&gt;
&lt;br /&gt;
But but but... Ice Cream Sandwich (Android 4.0) is awesome! Yes. But it was ready last year. When you finally find a phone with it on your carrier it will already be last year&#39;s OS. It &lt;i&gt;will &lt;/i&gt;have bloatware. It&#39;s software, so it &lt;i&gt;will &lt;/i&gt;have bugs. But fear not: since you will never see an update from the manufacturer they will never be fixed on your phone.&lt;br /&gt;
&lt;br /&gt;
&lt;h2&gt;


&lt;span style=&quot;font-weight: normal;&quot;&gt;Wake up, Google!&lt;/span&gt;&lt;/h2&gt;
&lt;div&gt;
&lt;span style=&quot;font-weight: normal;&quot;&gt;Google&#39;s web browser, Google Chrome, has been gaining market share with very little resistance. This would not have been possible using the Android strategy. Can you imagine what would have happened if every computer manufacturer had had a say in when and how we get Chrome releases instead of the regular 6-week-ish cycles?&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;
&lt;span style=&quot;font-weight: normal;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;
&lt;span style=&quot;font-weight: normal;&quot;&gt;I&#39;ve been an iPhone user. I&#39;ve been an Android user. They&#39;re both excellent. But Android is always 2 years behind when it gets to my pocket.&lt;/span&gt;&lt;/div&gt;
&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://tempocdev.blogspot.com/feeds/2534368046426329288/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://tempocdev.blogspot.com/2012/04/android-cutting-edge-tech-2-years.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/398584839682458587/posts/default/2534368046426329288'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/398584839682458587/posts/default/2534368046426329288'/><link rel='alternate' type='text/html' href='http://tempocdev.blogspot.com/2012/04/android-cutting-edge-tech-2-years.html' title='Android: Cutting edge tech 2 years behind'/><author><name>Gabriel F. Rodríguez</name><uri>http://www.blogger.com/profile/10332533752137475497</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-398584839682458587.post-6951535784944937936</id><published>2011-06-06T08:44:00.000-07:00</published><updated>2011-06-06T08:44:59.186-07:00</updated><title type='text'>The 10 JavaScript Mistakes you’re Making</title><content type='html'>&lt;a href=&quot;http://feedproxy.google.com/~r/nettuts/~3/FLbwQsC3hxA/&quot;&gt;The 10 JavaScript Mistakes you’re Making&lt;/a&gt;: &quot;&lt;a href=&quot;http://rss.buysellads.com/click.php?z=1260013&amp;amp;k=d754f1e9ba63a736ba8ff5ece958f7dd&amp;amp;a=20413&amp;amp;c=1021336657&quot;&gt;&lt;img src=&quot;http://rss.buysellads.com/img.php?z=1260013&amp;amp;k=d754f1e9ba63a736ba8ff5ece958f7dd&amp;amp;a=20413&amp;amp;c=1021336657&quot; border=&quot;0&quot; alt=&quot;&quot; /&gt;&lt;/a&gt;&lt;p&gt;&lt;a href=&quot;http://buysellads.com/buy/sitedetails/pubkey/d754f1e9ba63a736ba8ff5ece958f7dd/zone/1260013&quot;&gt;Advertise here&lt;/a&gt;&lt;/p&gt;&lt;p&gt;JavaScript is relatively easy to learn. However, gotchas abound in this tricky language. Are you sure that you’re not following any bad practices? Today, I’ll point out ten big mistakes you could be making. &lt;/p&gt;&lt;br /&gt;&lt;p&gt;&lt;span&gt;&lt;/span&gt;&lt;/p&gt;&lt;br /&gt;&lt;hr /&gt;&lt;br /&gt;&lt;h2&gt;&lt;span&gt;Mistake 1 -&lt;/span&gt; You’re Using Global Variables&lt;/h2&gt;&lt;br /&gt;&lt;p&gt;If you’re just getting started with JavaScript, you probably think it’s a great thing that all variables are global. Actually, if you’re just getting started, you might not know what that means. Global variables are variables that are accessible from anywhere in your JavaScript, even in different files loaded on the same page. Sounds great, doesn’t it? Any variable you might every want to change is always accessible.&lt;/p&gt;&lt;br /&gt;&lt;p&gt;Actually, no.&lt;/p&gt;&lt;br /&gt;&lt;p&gt;The reason this is a bad idea is because it’s easy to overwrite values unintentionally. Say you’ve got a web store, and you’re using JavaScript to display the price of all the items in the shopping cart (of course, you’ll recalculate this on the server side; this just enhances the user experience). Here’s some code you might have:&lt;/p&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;var total = 0,    // total price&lt;br /&gt;  tax   = 0.05; // 5%&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;Now, let’s say that you’re also using some code you found online to display some tweets on the page … or to make a sharp little gallery for your products. They might have some code like this:&lt;/p&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;var total = 15; // number of tweets pulled from twitter&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;Or,&lt;/p&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;var tax = function () { /* ... */ }; // Trigger Animation eXperience function&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;Now, you’re in trouble: two important variables have been overwritten, and you might not even realize it; your code will be producing errors, and you’ll pay dearly in time and hair to get things working again.&lt;/p&gt;&lt;br /&gt;&lt;p&gt;So what’s the solution? In a word, &lt;strong&gt;encapsulation&lt;/strong&gt;; but there are many ways to do this. Firstly, you could just write all your code within a self-invoking, anonymous function:&lt;/p&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;(function () {&lt;br /&gt;  var total = 0, tax = 0.05;&lt;br /&gt;&lt;br /&gt;  // other code&lt;br /&gt;}());&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;This way, absolutely no code outside the function can get to the values you have inside the function. This works for “personal” code, but it’s not so great for functionality that you want to distribute. For example, if we wanted to create a shopping cart totaller that others could use, using the &lt;a href=&quot;http://www.yuiblog.com/blog/2007/06/12/module-pattern/&quot;&gt;module pattern&lt;/a&gt; would be great:&lt;/p&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;var cartTotaler = (function () {&lt;br /&gt;  var total = 0; tax = 0.05;&lt;br /&gt;&lt;br /&gt;  // other code&lt;br /&gt;&lt;br /&gt;  return {&lt;br /&gt;    addItem : function (item) { },&lt;br /&gt;    removeItem : function (item) { },&lt;br /&gt;    calculateTitle : function () { }&lt;br /&gt;  };&lt;br /&gt;}());&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;One more thing about global variable: note that if you don’t use the &lt;code&gt;var&lt;/code&gt; keyword when creating a variable, the JavaScript engine will create a global variable by default. So:&lt;/p&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;(function () {&lt;br /&gt;tax = 0.05;&lt;br /&gt;}());&lt;br /&gt;&lt;br /&gt;var totalPrice = 100 + (100 * tax); // 105&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;The variable &lt;code&gt;tax&lt;/code&gt; is available outside the function because it’s not declared with the &lt;code&gt;var&lt;/code&gt; keyword. Watch out for this.&lt;/p&gt;&lt;br /&gt;&lt;hr /&gt;&lt;br /&gt;&lt;h2&gt;&lt;span&gt;Mistake 2 -&lt;/span&gt; You’re Not Using Semicolons&lt;/h2&gt;&lt;br /&gt;&lt;p&gt;Every statement in JavaScript must end with a semicolon. It’s that simple. The issue here is that is you don’t put it in, the compiler will: this is called &lt;em&gt;semicolon insertion&lt;/em&gt;. So the question is, if the compiler will insert them for you, why waste your time?&lt;/p&gt;&lt;br /&gt;&lt;p&gt;Well, in some places, it’s absolutely necessary; for example, you must put semicolons between the statements in a for-loop’s condition, or you’ll get a syntax error. But what about at the end of lines?&lt;/p&gt;&lt;br /&gt;&lt;p&gt;The JavaScript community is really divided on this. I’ve read very well-respected professionals on both sides of the debate. Here’s my argument: whenever you’re relying on the JavaScript compiler to change your code (even in what seems like a small way), you’re in dangerous waters.&lt;/p&gt;&lt;br /&gt;&lt;p&gt;For example, look at this simple function:&lt;/p&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;function returnPerson (name) {&lt;br /&gt;  return&lt;br /&gt;  {&lt;br /&gt;      name : name&lt;br /&gt;  };&lt;br /&gt;}&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;This looks like it should return a cute little object … but in reality, the JavaScript compiler assumes you meant to put a semicolon after &lt;code&gt;return&lt;/code&gt;, and will therefore return nothing; that object will get ignored. Your solution would be to do this:&lt;/p&gt;&lt;br /&gt;&lt;blockquote&gt;&lt;br /&gt;&lt;p&gt;&lt;strong&gt;Editor’s Note- &lt;/strong&gt;Another way to look at it: unless you’re aware of every single situation where they can successfully be omitted, don’t risk it.&lt;/p&gt;&lt;br /&gt;&lt;/blockquote&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;return {&lt;br /&gt;  name : name&lt;br /&gt;};&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;I’m going to go with “diligently insert semicolons”; honestly, it becomes habit pretty quickly. Also, as a web developer, you’ll probably use other languages (like PHP) where semicolons are required. Why switch back and forth when you don’t have to?&lt;/p&gt;&lt;br /&gt;&lt;hr /&gt;&lt;br /&gt;&lt;h2&gt;&lt;span&gt;Mistake 3 -&lt;/span&gt; You’re Using ==&lt;/h2&gt;&lt;br /&gt;&lt;p&gt;If you left your computer right now and walked until you met any random JavaScript developer (that might take a while), and asked him/her to give you one common JavaScript mistake, this is probably what he/she would say: “using double-equals instead of triple-equals.” What’s this mean?&lt;/p&gt;&lt;br /&gt;&lt;p&gt;Try this:&lt;/p&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;if (1 == 1) {&lt;br /&gt;  console.log(&quot;it&#39;s true!&quot;);&lt;br /&gt;}&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;You’d expect that to work, right? Well, now try this:&lt;/p&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;if (1 == &#39;1&#39;) {&lt;br /&gt;  console.log(&quot;it&#39;s true!&quot;);&lt;br /&gt;}&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;Yes, you got “it’s true!” output to the console … and yes, that’s a bad thing. What’s going on here is that the &lt;code&gt;==&lt;/code&gt; equality operator is coercing the values: this means it’s actually changing them to try to make the two values more similar. In this case, it’s converting the string “1” to the number 1 … so that our if-statement condition passes.&lt;/p&gt;&lt;br /&gt;&lt;p&gt;The solution here is to use &lt;code&gt;===&lt;/code&gt;; this doesn’t perform any type coercion, so the values are what you expect them to be. Of course, this all goes for the &lt;code&gt;!=&lt;/code&gt; and &lt;code&gt;!==&lt;/code&gt; operators as well.&lt;/p&gt;&lt;br /&gt;&lt;p&gt;Now, for your amusement, here’s a few of the incredible inconsistencies that you’ll get if you use double-equals:&lt;/p&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;&#39;&#39;         == &#39;0&#39; // false&lt;br /&gt;&#39;0&#39;        == &#39;&#39;  // true&lt;br /&gt;false      == &#39;0&#39; // true&lt;br /&gt;&#39; \t\r\n &#39; == 0   // true &lt;/pre&gt;&lt;br /&gt;&lt;hr /&gt;&lt;br /&gt;&lt;h2&gt;&lt;span&gt;Mistake 4 -&lt;/span&gt; You’re using Type Wrapper Objects&lt;/h2&gt;&lt;br /&gt;&lt;p&gt;JavaScript kindly (um?) gives us some type wrappers for easy (um?) creation of primitive types:&lt;/p&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;new Number(10);&lt;br /&gt;new String(&quot;hello&quot;);&lt;br /&gt;new Boolean(true);&lt;br /&gt;new Object();&lt;br /&gt;new Array(&quot;one&quot;, &quot;two&quot;, &quot;three&quot;);&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;First off, this is just super inconvenient. All these things can be done with many fewer keystrokes:&lt;/p&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;10;&lt;br /&gt;&quot;hello&quot;;&lt;br /&gt;true;&lt;br /&gt;{};&lt;br /&gt;[&quot;one&quot;, &quot;two&quot;, &quot;three&quot;];&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;But, wait, there’s more: these two things aren’t exactly equal. Here’s Douglas Crockford on the topic:&lt;/p&gt;&lt;br /&gt;&lt;blockquote&gt;&lt;br /&gt;&lt;p&gt;For example, &lt;code&gt;new boolean(false)&lt;/code&gt; produces an object that has a &lt;code&gt;valueOf&lt;/code&gt; method that returns the wrapped value.&lt;/p&gt;&lt;br /&gt;&lt;p&gt;- &lt;em&gt;JavaScript: The Good Parts&lt;/em&gt;, page 114&lt;/p&gt;&lt;br /&gt;&lt;/blockquote&gt;&lt;br /&gt;&lt;p&gt;This means that if you run &lt;code&gt;typeof new Number(10)&lt;/code&gt; or &lt;code&gt;typeof new String(&quot;hello&quot;)&lt;/code&gt;, you’ll get ‘object’—not what you want. Plus, using wrapper objects can cause behaviour that you’re not expecting if you’re used to primitive values.&lt;/p&gt;&lt;br /&gt;&lt;p&gt;So why does JavaScript provide these objects? It’s because they’re used internally. Primitive values don’t actually have methods (because they aren’t object); so, when you call a method on a primitive object (such as &lt;code&gt;&quot;hello&quot;.replace(&quot;ello&quot;, &quot;i&quot;)&lt;/code&gt;), JavaScript creates a wrapper object for that string, does what you want, and then discards the object.&lt;/p&gt;&lt;br /&gt;&lt;p&gt;Leave the typed wrappers up to JavaScript and use the primitive values.&lt;/p&gt;&lt;br /&gt;&lt;p&gt;Note: this should go without saying, but I want to make this clear for the newbies: I’m not saying you shouldn’t use constructor functions and &lt;code&gt;new&lt;/code&gt; (although some do recommend that). This advice specifically applies to primitive value types—numbers, strings, and booleans—arrays, and blank objects.&lt;/p&gt;&lt;br /&gt;&lt;hr /&gt;&lt;br /&gt;&lt;h2&gt;&lt;span&gt;Mistake 5 -&lt;/span&gt; You’re not Property-Checking when Using For-In&lt;/h2&gt;&lt;br /&gt;&lt;p&gt;We’re all familiar with iterating over arrays; however, you’ll probably find yourself wanting to iterate over the properties of an object. (Digression: the items in an array are actually just numbered properties in an object.) If you’ve done this before, you’ve used a for-in loop:&lt;/p&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;var prop, obj = { name: &quot;Joe&quot;, job: &quot;Coder&quot;, age: 25 };&lt;br /&gt;&lt;br /&gt;for (var prop in obj) {&lt;br /&gt;console.log(prop + &quot;: &quot; + obj[prop]);&lt;br /&gt;}&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;If you run the above code, you should see this output:&lt;/p&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;name: Joe&lt;br /&gt;job: Coder&lt;br /&gt;age: 25&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;However, browsers will include properties and methods from further up the prototype chain. Most of the time you won’t want to see these when enumerating properties. You should be using the &lt;code&gt;hasOwnProperties&lt;/code&gt; to filter out properties that aren’t actually on the object:&lt;/p&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;Function Dog (name) {&lt;br /&gt;  this.name = name;&lt;br /&gt;}&lt;br /&gt;Dog.prototype.legs = 4;&lt;br /&gt;Dog.prototype.speak = function () {&lt;br /&gt;  return &quot;woof!&quot;;&lt;br /&gt;};&lt;br /&gt;&lt;br /&gt;var d = new Dog(&quot;Bowser&quot;);&lt;br /&gt;&lt;br /&gt;for (var prop in d) {&lt;br /&gt;  console.log( prop + &quot;: &quot; + d[prop] );&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;console.log(&quot;=====&quot;);&lt;br /&gt;&lt;br /&gt;for (var prop in d) {&lt;br /&gt;if (d.hasOwnProperty(prop)) {&lt;br /&gt;  console.log( prop + &quot;: &quot; + d[prop] );&lt;br /&gt;}&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;// Output&lt;br /&gt;&lt;br /&gt;// name: Bowser&lt;br /&gt;// legs: 4&lt;br /&gt;// speak: function () {&lt;br /&gt;      return &quot;woof!&quot;;&lt;br /&gt;// }&lt;br /&gt;// =====&lt;br /&gt;// name: Bowser&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;Sometimes, you’ll want to let the properties through, but filter out any methods. You can do that by using &lt;code&gt;typeof&lt;/code&gt;:&lt;/p&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;for (var prop in d) {&lt;br /&gt;if (typeof d[prop] !== &#39;function&#39;) {&lt;br /&gt;  console.log( prop + &quot;: &quot; + d[prop] );&lt;br /&gt;}&lt;br /&gt;}&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;Either way, always be sure to clarify your for-in statements to avoid unwanted results.&lt;/p&gt;&lt;br /&gt;&lt;hr /&gt;&lt;br /&gt;&lt;h2&gt;&lt;span&gt;Mistake 6 -&lt;/span&gt; You’re Using &lt;code&gt;with&lt;/code&gt; or &lt;code&gt;eval&lt;/code&gt;&lt;/h2&gt;&lt;br /&gt;&lt;p&gt;Thankfully, most sources for learning JavaScript today don’t teach you about &lt;code&gt;with&lt;/code&gt; or &lt;code&gt;eval&lt;/code&gt;. But if you’re using some older material—or using a less-than-reputable source (because sometimes good material is hard to find on the web)—you might have found &lt;code&gt;with&lt;/code&gt; and &lt;code&gt;eval&lt;/code&gt; and given them a try. Terrible move, web developer.&lt;/p&gt;&lt;br /&gt;&lt;p&gt;Let’s start with &lt;code&gt;with&lt;/code&gt;. Two main reasons not to use it:&lt;/p&gt;&lt;br /&gt;&lt;ol&gt;&lt;br /&gt;&lt;li&gt;It really slows down the execution of your JavaScript.&lt;/li&gt;&lt;br /&gt;&lt;li&gt;It’s not always clear what you’re doing.&lt;/li&gt;&lt;br /&gt;&lt;/ol&gt;&lt;br /&gt;&lt;p&gt;Point one stands on its own, so let’s look at the second. Quickly, here’s how with works: You pass an object to a with statement; then, inside the with statement block, you can access properties of the object as variables:&lt;/p&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;var person = { name: &quot;Joe&quot;, age : 10 };&lt;br /&gt;&lt;br /&gt;with (person) {&lt;br /&gt;console.log(name); // Joe&lt;br /&gt;console.log(age);  // 10&lt;br /&gt;}&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;But, what if we have a variable with the same name as a property of the object we’re &lt;code&gt;with&lt;/code&gt;-ing? Basically, if both a variable and a property with the same name exist, the variable will be used. The other gotcha is that you can’t add a property to the object inside a with statement: if no property or variable exists, it will be made a variable of the scope outside the with statement:&lt;/p&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;var person = { name: &quot;Joe&quot;, age : 10 },&lt;br /&gt;  name = &quot;Billy&quot;;&lt;br /&gt;&lt;br /&gt;with (person) {&lt;br /&gt;console.log(name); // Billy&lt;br /&gt;job = &quot;Designer&quot;;&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;console.log(person.job); // undefined;&lt;br /&gt;console.log(job); // Designer&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;So, how about &lt;code&gt;eval&lt;/code&gt;? In a nutshell, you can pass a string of code to the function and it will execute the code.&lt;/p&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;eval( &quot;Console.log(&#39;hello!&#39;);&quot; );&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;Sounds harmless, even powerful, right? Actually, that’s the main problem: it’s too powerful. There’s obviously no reason to just hand it a hard string that you write directly into your code, because 1) why not just write the code? And 2) &lt;code&gt;eval&lt;/code&gt; is slower, just like &lt;code&gt;with&lt;/code&gt;. Therefore, the primary use of &lt;code&gt;eval&lt;/code&gt; is to execute code that you don’t have at runtime. You could be getting this from the server, or taking code directly from the user. Do you really want to give your website users complete control of your code? I hope not. Also, it opens your site up to unnumbered hackers: using &lt;code&gt;eval&lt;/code&gt; is basically a sign that says ”I’m away, and the key is under the mat.” If you love yourself or your users: don’t use it.&lt;/p&gt;&lt;br /&gt;&lt;hr /&gt;&lt;br /&gt;&lt;h2&gt;&lt;span&gt;Mistake 7 -&lt;/span&gt; You’re Not Using a Radix When Using &lt;code&gt;parseInt&lt;/code&gt;&lt;/h2&gt;&lt;br /&gt;&lt;p&gt;JavaScript has a great little helper function called &lt;code&gt;parseInt&lt;/code&gt; that allows you to convert a string that contains a number to a number:&lt;/p&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;parseInt(&quot;200&quot;); // 200&lt;br /&gt;parseInt(&quot;043&quot;); // 35&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;Um, what happened there? Shouldn’t that second example be 43? Actually, &lt;code&gt;parseInt&lt;/code&gt; will work with more than just decimal values: so, when &lt;code&gt;parseInt&lt;/code&gt; sees a string that starts with a 0, it assumes that it’s an octal number (base 8). That’s why it’s a mistake not to pass a radix; this tells &lt;code&gt;parseInt&lt;/code&gt; what base the number is in (it always outputs a decimal number).&lt;/p&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;parseInt(&quot;020&quot;, 10); // 20&lt;br /&gt;parseInt(&quot;100&quot;, 2);  // 4&lt;/pre&gt;&lt;br /&gt;&lt;hr /&gt;&lt;br /&gt;&lt;h2&gt;&lt;span&gt;Mistake 8 -&lt;/span&gt; You’re Not Using Braces on &lt;code&gt;if&lt;/code&gt; and &lt;code&gt;while&lt;/code&gt; statements&lt;/h2&gt;&lt;br /&gt;&lt;p&gt;One of the most obvious beauties of JavaScript is its flexibility. But sometimes, that can come back to fight you. That’s certainly the case with braces on if- and while-statement blocks. These braces are optional if you only have one line of code in the block:&lt;/p&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;if (true)&lt;br /&gt;console.log(&quot;inside the if statement&quot;);&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;This is great, because you can even put them on the same line:&lt;/p&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;var arr = [&quot;one&quot;, &quot;two&quot;, &quot;three&quot;, &quot;four&quot;, &quot;five&quot;, &quot;six&quot;, &quot;seven&quot;, &quot;eight&quot;, &quot;nine&quot;, &quot;ten&quot;],&lt;br /&gt;  i   = arr.length - i;&lt;br /&gt;&lt;br /&gt;while (i) console.log( arr[i--] );&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;But this isn’t smart for a couple of reasons: firstly, it can become unclear:&lt;/p&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;if (true)&lt;br /&gt;console.log(&quot;inside the if-statement.&quot;);&lt;br /&gt;console.log(&quot;outside the if-statement.&quot;);&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;See what I mean? That second line isn’t in the if-statement, but it sure looks like it. Braces would make that clear. Also, if you ever want to add a line to the block, you have to remember to add the braces as well. Just adding them in the first place is so much easier. Do it.&lt;/p&gt;&lt;br /&gt;&lt;hr /&gt;&lt;br /&gt;&lt;h2&gt;&lt;span&gt;Mistake 9 -&lt;/span&gt; You’re Adding Elements to the DOM Individually&lt;/h2&gt;&lt;br /&gt;&lt;p&gt;All right, all right: this isn’t really JavaScript itself. But, in 99 of 100 cases, JavaScript means using the DOM. While there’s a lot of mistakes you can make when working with the DOM, this is a big one.&lt;/p&gt;&lt;br /&gt;&lt;p&gt;I fondly remember the day when I inserted my first DOM element via JavaScript. It’s fun to do, and oh-so-useful, but it unfortunately is a strain on the page: inserting a DOM element forces the browser to completely repaint the page, so if you have a whole bunch of elements to add, adding them one by one is a bad idea:&lt;/p&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;var list = document.getElementById(&quot;list&quot;),&lt;br /&gt;  items = [&quot;one&quot;, &quot;two&quot;, &quot;three&quot;, &quot;four&quot;],&lt;br /&gt;  el;&lt;br /&gt;&lt;br /&gt;for (var i = 0; items[i]; i++) {&lt;br /&gt;el = document.createElement(&quot;li&quot;);&lt;br /&gt;el.appendChild( document.createTextNode(items[i]) );&lt;br /&gt;list.appendChild(el); // slow, bad idea&lt;br /&gt;}&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;Here’s what you should do instead: use document fragments. Document fragments are a container to hold DOM elements; then instead of inserting each element individually, you can insert them all at once. The document fragment isn’t a node in itself and there will be nothing to show for it in the DOM: it’s just an invisible net for holding DOM elements before you put them into the DOM. So, here’s how you do it:&lt;/p&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;var list = document.getElementById(&quot;list&quot;),&lt;br /&gt;  frag = document.createDocumentFragment(),&lt;br /&gt;  items = [&quot;one&quot;, &quot;two&quot;, &quot;three&quot;, &quot;four&quot;],&lt;br /&gt;  el;&lt;br /&gt;&lt;br /&gt;for (var i = 0; items[i]; i++) {&lt;br /&gt;el = document.createElement(&quot;li&quot;);&lt;br /&gt;el.appendChild( document.createTextNode(items[i]) );&lt;br /&gt;frag.appendChild(el); // better!&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;list.appendChild(frag);&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;Faster, quicker, cleaner—what’s not to love?&lt;/p&gt;&lt;br /&gt;&lt;hr /&gt;&lt;br /&gt;&lt;h2&gt;&lt;span&gt;Mistake 10 -&lt;/span&gt; You’re Not Learning JavaScript&lt;/h2&gt;&lt;br /&gt;&lt;blockquote&gt;&lt;br /&gt;&lt;p&gt;Many people don’t take the time to learn JavaScript right.&lt;/p&gt;&lt;br /&gt;&lt;/blockquote&gt;&lt;br /&gt;&lt;p&gt;JavaScript does not equal jQuery. Did I just shock your sock off? If you found yourself guilty of committing several of the mistakes listed above, you probably need to do some serious JavaScript studying. JavaScript is a language that you can use almost without learning it, which means that so many people don’t take the time to learn it right. Don’t be one of those people: there are &lt;a href=&quot;http://net.tutsplus.com/category/tutorials/javascript-ajax/&quot;&gt;so many awesome&lt;/a&gt; &lt;a href=&quot;http://marketplace.tutsplus.com/category/web-development/javascript-ajax&quot;&gt;JavaScript tutorials&lt;/a&gt; out there that you have no excuse for not learning the language. If all you know is jQuery (or Mootools, or whatever), you’re really putting yourself in a bad spot.&lt;/p&gt;&lt;br /&gt;&lt;hr /&gt;&lt;br /&gt;&lt;h2&gt;&lt;span&gt;Mistake 11 -&lt;/span&gt; You’re Following all the Rules&lt;/h2&gt;&lt;br /&gt;&lt;blockquote&gt;&lt;br /&gt;&lt;p&gt;Rules are made to be broken.&lt;/p&gt;&lt;br /&gt;&lt;/blockquote&gt;&lt;br /&gt;&lt;p&gt;The last and final mistake you’re making is that you’re following all the rules. Yes, even some of the rules I’ve listed here. As with anything, rules are made to be broken. If you’re relatively new to JavaScript, you should probably avoid with fervour all the mistakes I’ve outlined for you today. But the truth is that if you understand why it’s recommended not to do something, that thing becomes a tool that you might use in just the right circumstance. For example, &lt;code&gt;eval&lt;/code&gt; is preached against loudly, but it’s the only tool you can use to parse JSON from a server. Of course, there are many security checks in place when you do it (you should probably use &lt;a href=&quot;https://github.com/douglascrockford/JSON-js&quot;&gt;a library&lt;/a&gt;). But the point is that you shouldn’t be afraid to knowledgeably use the “bad practices” I’ve listed above if the need arises. It’s the same close-mindedness that causes you to make these mistakes in the first place is the same close-mindedness that keeps you from using them when they are the right tool.&lt;/p&gt;&lt;br /&gt;&lt;p&gt;Of course, never make mistake 10 -&lt;/p&gt;&lt;br /&gt;&lt;hr /&gt;&lt;br /&gt;&lt;h2&gt;Conclusion&lt;/h2&gt;&lt;br /&gt;&lt;p&gt;If you’re new to JavaScript, hopefully you’re a better JavaScript developer now. If you consider yourself a JavaScript pro (then how are you even still reading this?), what have I missed? Let us all know in the comments!&lt;/p&gt;&lt;div&gt;&lt;br /&gt;&lt;a href=&quot;http://feeds.feedburner.com/~ff/nettuts?a=FLbwQsC3hxA:JH80VESN4GU:yIl2AUoC8zA&quot;&gt;&lt;img src=&quot;http://feeds.feedburner.com/~ff/nettuts?d=yIl2AUoC8zA&quot; border=&quot;0&quot; /&gt;&lt;/a&gt; &lt;a href=&quot;http://feeds.feedburner.com/~ff/nettuts?a=FLbwQsC3hxA:JH80VESN4GU:F7zBnMyn0Lo&quot;&gt;&lt;img src=&quot;http://feeds.feedburner.com/~ff/nettuts?i=FLbwQsC3hxA:JH80VESN4GU:F7zBnMyn0Lo&quot; border=&quot;0&quot; /&gt;&lt;/a&gt; &lt;a href=&quot;http://feeds.feedburner.com/~ff/nettuts?a=FLbwQsC3hxA:JH80VESN4GU:V_sGLiPBpWU&quot;&gt;&lt;img src=&quot;http://feeds.feedburner.com/~ff/nettuts?i=FLbwQsC3hxA:JH80VESN4GU:V_sGLiPBpWU&quot; border=&quot;0&quot; /&gt;&lt;/a&gt; &lt;a href=&quot;http://feeds.feedburner.com/~ff/nettuts?a=FLbwQsC3hxA:JH80VESN4GU:gIN9vFwOqvQ&quot;&gt;&lt;img src=&quot;http://feeds.feedburner.com/~ff/nettuts?i=FLbwQsC3hxA:JH80VESN4GU:gIN9vFwOqvQ&quot; border=&quot;0&quot; /&gt;&lt;/a&gt; &lt;a href=&quot;http://feeds.feedburner.com/~ff/nettuts?a=FLbwQsC3hxA:JH80VESN4GU:TzevzKxY174&quot;&gt;&lt;img src=&quot;http://feeds.feedburner.com/~ff/nettuts?d=TzevzKxY174&quot; border=&quot;0&quot; /&gt;&lt;/a&gt;&lt;br /&gt;&lt;/div&gt;&lt;img src=&quot;http://feeds.feedburner.com/~r/nettuts/~4/FLbwQsC3hxA&quot; height=&quot;1&quot; width=&quot;1&quot; /&gt;&quot;</content><link rel='replies' type='application/atom+xml' href='http://tempocdev.blogspot.com/feeds/6951535784944937936/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://tempocdev.blogspot.com/2011/06/10-javascript-mistakes-youre-making.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/398584839682458587/posts/default/6951535784944937936'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/398584839682458587/posts/default/6951535784944937936'/><link rel='alternate' type='text/html' href='http://tempocdev.blogspot.com/2011/06/10-javascript-mistakes-youre-making.html' title='The 10 JavaScript Mistakes you’re Making'/><author><name>Gabriel F. Rodríguez</name><uri>http://www.blogger.com/profile/10332533752137475497</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-398584839682458587.post-2594074902074151677</id><published>2011-02-10T16:44:00.000-08:00</published><updated>2011-02-10T16:44:44.084-08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="IE"/><category scheme="http://www.blogger.com/atom/ns#" term="IE9"/><category scheme="http://www.blogger.com/atom/ns#" term="Windows 7"/><title type='text'>Internet Explorer 9 Looks Promising</title><content type='html'>Here&#39;s something developers can get out of IE9 and the Windows 7 taskbar.&lt;br /&gt;
&lt;br /&gt;
&lt;a href=&quot;http://msdn.microsoft.com/en-us/library/gg131029(VS.85).aspx&quot;&gt;http://msdn.microsoft.com/en-us/library/gg131029(VS.85).aspx&lt;/a&gt;</content><link rel='replies' type='application/atom+xml' href='http://tempocdev.blogspot.com/feeds/2594074902074151677/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://tempocdev.blogspot.com/2011/02/internet-explorer-9-looks-promising.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/398584839682458587/posts/default/2594074902074151677'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/398584839682458587/posts/default/2594074902074151677'/><link rel='alternate' type='text/html' href='http://tempocdev.blogspot.com/2011/02/internet-explorer-9-looks-promising.html' title='Internet Explorer 9 Looks Promising'/><author><name>Gabriel F. Rodríguez</name><uri>http://www.blogger.com/profile/10332533752137475497</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-398584839682458587.post-67229661218458959</id><published>2011-02-03T09:49:00.000-08:00</published><updated>2013-07-02T20:04:05.272-07:00</updated><title type='text'>Semantics.pdf - Powered by Google Docs</title><content type='html'>&lt;iframe src=&quot;https://docs.google.com/file/d/1G1X8_MGUgRMdm9GSePyzIXI2f6oCiT_nk4aIl1zo9KnQ1OwDgZ3FWT9mH4Sj/preview?authkey=CLTG5ekJ&amp;hl=en&quot; width=&quot;640&quot; height=&quot;480&quot;&gt;&lt;/iframe&gt;</content><link rel='replies' type='application/atom+xml' href='http://tempocdev.blogspot.com/feeds/67229661218458959/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://tempocdev.blogspot.com/2011/02/semanticspdf-powered-by-google-docs.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/398584839682458587/posts/default/67229661218458959'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/398584839682458587/posts/default/67229661218458959'/><link rel='alternate' type='text/html' href='http://tempocdev.blogspot.com/2011/02/semanticspdf-powered-by-google-docs.html' title='Semantics.pdf - Powered by Google Docs'/><author><name>Gabriel F. Rodríguez</name><uri>http://www.blogger.com/profile/10332533752137475497</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-398584839682458587.post-7723551987816570933</id><published>2011-01-21T13:07:00.000-08:00</published><updated>2011-01-21T13:07:39.513-08:00</updated><title type='text'>Twilio Cloud Communications | Web Service API for building Voice and SMS Applications</title><content type='html'>&lt;a href=&quot;http://www.twilio.com/&quot;&gt;Twilio Cloud Communications | Web Service API for building Voice and SMS Applications&lt;/a&gt;</content><link rel='replies' type='application/atom+xml' href='http://tempocdev.blogspot.com/feeds/7723551987816570933/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://tempocdev.blogspot.com/2011/01/twilio-cloud-communications-web-service.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/398584839682458587/posts/default/7723551987816570933'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/398584839682458587/posts/default/7723551987816570933'/><link rel='alternate' type='text/html' href='http://tempocdev.blogspot.com/2011/01/twilio-cloud-communications-web-service.html' title='Twilio Cloud Communications | Web Service API for building Voice and SMS Applications'/><author><name>Gabriel F. Rodríguez</name><uri>http://www.blogger.com/profile/10332533752137475497</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-398584839682458587.post-1728171097673130617</id><published>2011-01-20T09:21:00.000-08:00</published><updated>2011-01-20T09:49:47.013-08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="JavaScript"/><category scheme="http://www.blogger.com/atom/ns#" term="jQuery"/><category scheme="http://www.blogger.com/atom/ns#" term="microtemplating"/><title type='text'>jQuery Microtemplating Tutorial</title><content type='html'>&lt;div class=&quot;MsoNormal&quot;&gt;&lt;a href=&quot;http://www.myliferunsoncode.com/micro.zip&quot;&gt;www.myliferunsoncode.com/micro.zip&lt;/a&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;br /&gt;
&lt;br /&gt;
Documentation:&amp;nbsp;&lt;a href=&quot;http://api.jquery.com/category/plugins/templates/&quot;&gt;http://api.jquery.com/category/plugins/templates/&lt;/a&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://tempocdev.blogspot.com/feeds/1728171097673130617/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://tempocdev.blogspot.com/2011/01/jquery-microtemplating-tutorial.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/398584839682458587/posts/default/1728171097673130617'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/398584839682458587/posts/default/1728171097673130617'/><link rel='alternate' type='text/html' href='http://tempocdev.blogspot.com/2011/01/jquery-microtemplating-tutorial.html' title='jQuery Microtemplating Tutorial'/><author><name>Gabriel F. Rodríguez</name><uri>http://www.blogger.com/profile/10332533752137475497</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-398584839682458587.post-1647325191307813171</id><published>2010-11-04T17:42:00.000-07:00</published><updated>2010-11-04T17:42:12.495-07:00</updated><title type='text'>The 30 CSS Selectors you Must Memorize</title><content type='html'>&lt;a href=&quot;http://feedproxy.google.com/~r/nettuts/~3/j6GxxU_jbjk/&quot;&gt;The 30 CSS Selectors you Must Memorize&lt;/a&gt;: &quot;&lt;p&gt;&lt;a href=&quot;http://feedads.g.doubleclick.net/~a/9RcWP-wHEcICpE3uVju9Zp6rWVE/0/da&quot;&gt;&lt;img src=&quot;http://feedads.g.doubleclick.net/~a/9RcWP-wHEcICpE3uVju9Zp6rWVE/0/di&quot; border=&quot;0&quot; ismap=&quot;&quot; /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;a href=&quot;http://feedads.g.doubleclick.net/~a/9RcWP-wHEcICpE3uVju9Zp6rWVE/1/da&quot;&gt;&lt;img src=&quot;http://feedads.g.doubleclick.net/~a/9RcWP-wHEcICpE3uVju9Zp6rWVE/1/di&quot; border=&quot;0&quot; ismap=&quot;&quot; /&gt;&lt;/a&gt;&lt;/p&gt;&lt;p&gt;So you learned the base &lt;code&gt;id&lt;/code&gt;, &lt;code&gt;class&lt;/code&gt;, and &lt;code&gt;descendant&lt;/code&gt; selectors – and then called it a day? If so, you’re missing out on an enormous level of flexibility. While many of the selectors mentioned in this article are part of the CSS3 spec, and are, consequently, only available in modern browsers, you owe it to yourself to commit these to memory.&lt;br /&gt;&lt;br /&gt;&lt;span&gt;&lt;/span&gt;&lt;/p&gt;&lt;br /&gt;&lt;hr /&gt;&lt;br /&gt;&lt;h2&gt;&lt;span&gt; 1. &lt;/span&gt;*&lt;/h2&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;&lt;br /&gt;* {&lt;br /&gt;margin: 0;&lt;br /&gt;padding: 0;&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;Let’s knock the obvious ones out, for the beginners, before we move onto the more advanced selectors.&lt;/p&gt;&lt;br /&gt;&lt;p&gt;The star symbol will target every single element on the page. Many developers will use this trick to zero out the &lt;code&gt;margin&lt;/code&gt;s and &lt;code&gt;padding&lt;/code&gt;. While this is certainly fine for quick tests, I’d advise you to never use this in production code. It adds too much &lt;em&gt;weight&lt;/em&gt; on the browser, and is unnecessary.&lt;/p&gt;&lt;br /&gt;&lt;p&gt;The &lt;code&gt;*&lt;/code&gt; can also be used with child selectors. &lt;/p&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;&lt;br /&gt;#container * {&lt;br /&gt;border: 1px solid black;&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;This will target every single element that is a child of the &lt;code&gt;#container&lt;/code&gt; &lt;code&gt;div&lt;/code&gt;. Again, try not to use this technique very much, if every.&lt;/p&gt;&lt;br /&gt;&lt;h5&gt; &lt;a href=&quot;http://d2o0t5hpnwv4c1.cloudfront.net/840_cssSelectors/selectors/star.html&quot;&gt;View Demo &lt;/a&gt;&lt;/h5&gt;&lt;br /&gt;&lt;hr /&gt;&lt;br /&gt;&lt;h2&gt;&lt;span&gt; 2. &lt;/span&gt;#X&lt;/h2&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;&lt;br /&gt;#container {&lt;br /&gt;  width: 960px;&lt;br /&gt;  margin: auto;&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;Prefixing the hash symbol to a selector allows us to target by &lt;code&gt;id&lt;/code&gt;. This is easily the most common usage, however be cautious when using &lt;code&gt;id&lt;/code&gt; selectors.&lt;/p&gt;&lt;br /&gt;&lt;blockquote&gt;&lt;br /&gt;&lt;p&gt;Ask yourself: do I absolutely need to apply an &lt;code&gt;id&lt;/code&gt; to this element in order to target it?&lt;/p&gt;&lt;br /&gt;&lt;/blockquote&gt;&lt;br /&gt;&lt;p&gt;&lt;code&gt;id&lt;/code&gt; selectors are rigid and don’t allow for reuse. If possible, first try to use a tag name, one of the new HTML5 elements, or even a pseudo-class.&lt;/p&gt;&lt;br /&gt;&lt;h5&gt; &lt;a href=&quot;http://d2o0t5hpnwv4c1.cloudfront.net/840_cssSelectors/selectors/id.html&quot;&gt;View Demo &lt;/a&gt; &lt;/h5&gt;&lt;br /&gt;&lt;hr /&gt;&lt;br /&gt;&lt;h2&gt;&lt;span&gt; 3. &lt;/span&gt;.X&lt;/h2&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;&lt;br /&gt;.error {&lt;br /&gt; color: red;&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;This is a &lt;code&gt;class&lt;/code&gt; selector. The difference between &lt;code&gt;id&lt;/code&gt;s and &lt;code&gt;class&lt;/code&gt;es is that, with the latter, you can target multiple elements. Use &lt;code&gt;class&lt;/code&gt;es when you want your styling to apply to a group of elements. Alternatively, use &lt;code&gt;id&lt;/code&gt;s to find a needle-in-a-haystack, and style only that specific element.&lt;/p&gt;&lt;br /&gt;&lt;h5&gt; &lt;a href=&quot;http://d2o0t5hpnwv4c1.cloudfront.net/840_cssSelectors/selectors/class.html&quot;&gt;View Demo &lt;/a&gt; &lt;/h5&gt;&lt;br /&gt;&lt;hr /&gt;&lt;br /&gt;&lt;h2&gt;&lt;span&gt; 4. &lt;/span&gt;X Y&lt;/h2&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;&lt;br /&gt;li a {&lt;br /&gt; text-decoration: none;&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;The next most comment selector is the &lt;code&gt;descendant&lt;/code&gt; selector. When you need to be more specific with your selectors, you use these. For example, what if, rather than targeting &lt;em&gt;all&lt;/em&gt; anchor tags, you only need to target the anchors which are within an unordered list? This is specifically when you’d use a descendant selector. &lt;/p&gt;&lt;br /&gt;&lt;blockquote&gt;&lt;br /&gt;&lt;p&gt;&lt;strong&gt;Pro-tip&lt;/strong&gt; – If your selector looks like &lt;code&gt;X Y Z A B.error&lt;/code&gt;, you’re doing it wrong. Always ask yourself if it’s absolutely necessary to apply all of that &lt;em&gt;weight&lt;/em&gt;.&lt;/p&gt;&lt;br /&gt;&lt;/blockquote&gt;&lt;br /&gt;&lt;h5&gt; &lt;a href=&quot;http://d2o0t5hpnwv4c1.cloudfront.net/840_cssSelectors/selectors/descend.html&quot;&gt;View Demo &lt;/a&gt; &lt;/h5&gt;&lt;br /&gt;&lt;hr /&gt;&lt;br /&gt;&lt;h2&gt;&lt;span&gt; 5. &lt;/span&gt;X&lt;/h2&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;&lt;br /&gt;a { color: red; }&lt;br /&gt;ul { margin-left: 0; }&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;What if you want to target all elements on a page, according to their &lt;code&gt;type&lt;/code&gt;, rather than an &lt;code&gt;id&lt;/code&gt; or &lt;code&gt;class&lt;/code&gt;name? Keep it simple, and use a type selector. If you need to target all unordered lists, use &lt;code&gt;ul {}&lt;/code&gt;.&lt;/p&gt;&lt;br /&gt;&lt;h5&gt; &lt;a href=&quot;http://d2o0t5hpnwv4c1.cloudfront.net/840_cssSelectors/selectors/tagName.html&quot;&gt;View Demo &lt;/a&gt; &lt;/h5&gt;&lt;br /&gt;&lt;hr /&gt;&lt;br /&gt;&lt;h2&gt;&lt;span&gt; 6. &lt;/span&gt;X:visited and X:link&lt;/h2&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;&lt;br /&gt;a:link { color: red; }&lt;br /&gt;a:visted { color: purple; }&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;We use the &lt;code&gt;:link&lt;/code&gt; pseudo-class to target all anchors tags which have yet to be clicked on.&lt;/p&gt;&lt;br /&gt;&lt;p&gt;Alternatively, we also have the &lt;code&gt;:visited&lt;/code&gt; pseudo class, which, as you’d expected, allows us to apply specific styling to only the anchor tags on the page which &lt;em&gt;have&lt;/em&gt; been clicked on, or &lt;em&gt;visited&lt;/em&gt;.&lt;/p&gt;&lt;br /&gt;&lt;h5&gt; &lt;a href=&quot;http://d2o0t5hpnwv4c1.cloudfront.net/840_cssSelectors/selectors/links.html&quot;&gt;View Demo &lt;/a&gt; &lt;/h5&gt;&lt;br /&gt;&lt;hr /&gt;&lt;br /&gt;&lt;h2&gt;&lt;span&gt;7.&lt;/span&gt; X + Y&lt;/h2&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;&lt;br /&gt;ul + p {&lt;br /&gt;  color: red;&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;This is referred to as an adjacent selector. It will select &lt;em&gt;only&lt;/em&gt; the element that is immediately proceeded by the former element. In this case, only the first paragraph after each &lt;code&gt;ul&lt;/code&gt; will have red text.&lt;/p&gt;&lt;br /&gt;&lt;h5&gt; &lt;a href=&quot;http://d2o0t5hpnwv4c1.cloudfront.net/840_cssSelectors/selectors/adjacent.html&quot;&gt;View Demo &lt;/a&gt; &lt;/h5&gt;&lt;br /&gt;&lt;hr /&gt;&lt;br /&gt;&lt;h2&gt;&lt;span&gt;8.&lt;/span&gt; X &amp;gt; Y&lt;/h2&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;&lt;br /&gt;div#container &amp;gt; ul {&lt;br /&gt; border: 1px solid black;&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;The difference between the standard &lt;code&gt;X Y&lt;/code&gt; and &lt;code&gt;X &amp;gt; Y&lt;/code&gt; is that the latter will only select direct children. For example, consider the following markup.&lt;/p&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;&lt;br /&gt;  &amp;lt;div id=&quot;container&quot;&amp;gt;&lt;br /&gt;     &amp;lt;ul&amp;gt;&lt;br /&gt;        &amp;lt;li&amp;gt; List Item&lt;br /&gt;          &amp;lt;ul&amp;gt;&lt;br /&gt;             &amp;lt;li&amp;gt; Child &amp;lt;/li&amp;gt;&lt;br /&gt;          &amp;lt;/ul&amp;gt;&lt;br /&gt;        &amp;lt;/li&amp;gt;&lt;br /&gt;        &amp;lt;li&amp;gt; List Item &amp;lt;/li&amp;gt;&lt;br /&gt;        &amp;lt;li&amp;gt; List Item &amp;lt;/li&amp;gt;&lt;br /&gt;        &amp;lt;li&amp;gt; List Item &amp;lt;/li&amp;gt;&lt;br /&gt;     &amp;lt;/ul&amp;gt;&lt;br /&gt;  &amp;lt;/div&amp;gt;&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;A selector of &lt;code&gt;#container &amp;gt; ul&lt;/code&gt; will only target the &lt;code&gt;ul&lt;/code&gt;s which are direct children of the &lt;code&gt;div&lt;/code&gt; with an &lt;code&gt;id&lt;/code&gt; of &lt;code&gt;container&lt;/code&gt;. It will not target, for instance, the &lt;code&gt;ul&lt;/code&gt; that is a child of the first &lt;code&gt;li&lt;/code&gt;. &lt;/p&gt;&lt;br /&gt;&lt;p&gt;For this reason, there are performance benefits in using the child combinator. In fact, it’s recommended particularly when working with JavaScript-based CSS selector engines.&lt;/p&gt;&lt;br /&gt;&lt;h5&gt; &lt;a href=&quot;http://d2o0t5hpnwv4c1.cloudfront.net/840_cssSelectors/selectors/childcombinator.html&quot;&gt;View Demo &lt;/a&gt; &lt;/h5&gt;&lt;br /&gt;&lt;hr /&gt;&lt;br /&gt;&lt;h2&gt;&lt;span&gt; 9.&lt;/span&gt; X ~ Y&lt;/h2&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;&lt;br /&gt;ul ~ p {&lt;br /&gt;  color: red;&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;This sibling combinator is similar to &lt;code&gt;X + Y&lt;/code&gt;, however, it’s less strict. While an adjacent selector (&lt;code&gt;ul + p&lt;/code&gt;) will only select the first element that is &lt;em&gt;immediately&lt;/em&gt; proceeded by the former selector, this one is more generalized. It will select, referring to our example above, any &lt;code&gt;p&lt;/code&gt; elements, as long as they are followed by a &lt;code&gt;ul&lt;/code&gt;. &lt;/p&gt;&lt;br /&gt;&lt;h5&gt; &lt;a href=&quot;http://d2o0t5hpnwv4c1.cloudfront.net/840_cssSelectors/selectors/generalcombinator.html&quot;&gt;View Demo &lt;/a&gt; &lt;/h5&gt;&lt;br /&gt;&lt;hr /&gt;&lt;br /&gt;&lt;h2&gt;&lt;span&gt; 10.&lt;/span&gt; X[title]&lt;/h2&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;&lt;br /&gt;a[title] {&lt;br /&gt;  color: green;&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;Referred to as an &lt;em&gt;attributes selector&lt;/em&gt;, in our example above, this will only select the anchor tags that have a &lt;code&gt;title&lt;/code&gt; attribute. Anchor tags which do not will not receive this particular styling. But, what if you need to be more specific? Well…&lt;/p&gt;&lt;br /&gt;&lt;h5&gt; &lt;a href=&quot;http://d2o0t5hpnwv4c1.cloudfront.net/840_cssSelectors/selectors/attributes.html&quot;&gt;View Demo &lt;/a&gt; &lt;/h5&gt;&lt;br /&gt;&lt;hr /&gt;&lt;br /&gt;&lt;h2&gt;&lt;span&gt; 11.&lt;/span&gt; X[href=&#39;foo&#39;]&lt;/h2&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;&lt;br /&gt;a[href=&#39;http://net.tutsplus.com&#39;] {&lt;br /&gt; color: #1f6053; /* nettuts green */&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;The snippet above will style all anchor tags which link to &lt;em&gt;http://net.tutsplus.com&lt;/em&gt;; they’ll receive our branded green color. All other anchor tags will remain unaffected.&lt;/p&gt;&lt;br /&gt;&lt;blockquote&gt;&lt;br /&gt;&lt;p&gt;&lt;br /&gt;Note that we’re wrapping the value in quotes. Remember to also do this when using a JavaScript CSS selector engine. When possible, always use CSS3 selectors over unofficial methods.&lt;br /&gt;&lt;/p&gt;&lt;br /&gt;&lt;/blockquote&gt;&lt;br /&gt;&lt;p&gt;This works well, though, it’s a bit rigid. What if the link does indeed direct to Nettuts+, but, maybe, the path is &lt;em&gt;nettuts.com&lt;/em&gt; rather than the full url? In those cases we can use a bit of the regular expressions syntax.&lt;/p&gt;&lt;br /&gt;&lt;h5&gt; &lt;a href=&quot;http://d2o0t5hpnwv4c1.cloudfront.net/840_cssSelectors/selectors/attributes2.html&quot;&gt;View Demo &lt;/a&gt; &lt;/h5&gt;&lt;br /&gt;&lt;hr /&gt;&lt;br /&gt;&lt;h2&gt;&lt;span&gt; 12.&lt;/span&gt; X[href*=&#39;nettuts&#39;]&lt;/h2&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;&lt;br /&gt;a[href*=&#39;tuts&#39;] {&lt;br /&gt; color: #1f6053; /* nettuts green */&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;There we go; that’s what we need. The star designates that the proceeding value must appear &lt;em&gt;somewhere&lt;/em&gt; in the attribute’s value. That way, this covers &lt;em&gt;nettuts.com&lt;/em&gt;, &lt;em&gt;net.tutsplus.com,&lt;/em&gt; and even &lt;em&gt;tutsplus.com&lt;/em&gt;. &lt;/p&gt;&lt;br /&gt;&lt;p&gt;Keep in mind that this is a broad statement. What if the anchor tag linked to some non-Envato site with the string &lt;em&gt;tuts&lt;/em&gt; in the url? When you need to be more specific, use &lt;code&gt;^&lt;/code&gt; and &lt;code&gt;&amp;amp;&lt;/code&gt;, to reference the beginning and end of a string, respectively.&lt;/p&gt;&lt;br /&gt;&lt;h5&gt; &lt;a href=&quot;http://d2o0t5hpnwv4c1.cloudfront.net/840_cssSelectors/selectors/attributes3.html&quot;&gt;View Demo &lt;/a&gt; &lt;/h5&gt;&lt;br /&gt;&lt;hr /&gt;&lt;br /&gt;&lt;h2&gt;&lt;span&gt; 13. &lt;/span&gt; X[href^=&#39;http&#39;]&lt;/h2&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;&lt;br /&gt;a[href^=&#39;http&#39;] {&lt;br /&gt;  background: url(path/to/external/icon.png) no-repeat;&lt;br /&gt;  padding-left: 10px;&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;Ever wonder how some websites are able to display a little icon next to the links which are external? I’m sure you’ve seen these before; they’re nice reminders that the link will direct you to an entirely different website.&lt;/p&gt;&lt;br /&gt;&lt;p&gt;This is a cinch with the carat symbol. It’s most commonly used in regular expressions to designate the beginning of a string. If we want to target all anchor tags that have a &lt;code&gt;href&lt;/code&gt; which begins with &lt;code&gt;http&lt;/code&gt;, we could use a selector similar to the snippet shown above.&lt;/p&gt;&lt;br /&gt;&lt;blockquote&gt;&lt;br /&gt;&lt;p&gt;Notice that we’re not searching for &lt;code&gt;http://&lt;/code&gt;; that’s unnecessary, and doesn’t account for the urls that begin with &lt;code&gt;https://&lt;/code&gt;. &lt;/p&gt;&lt;br /&gt;&lt;/blockquote&gt;&lt;br /&gt;&lt;p&gt;Now, what if we wanted to instead style all anchors which link to, say, a photo? In those cases, let’s search for the &lt;em&gt;end&lt;/em&gt; of the string.&lt;/p&gt;&lt;br /&gt;&lt;h5&gt; &lt;a href=&quot;http://d2o0t5hpnwv4c1.cloudfront.net/840_cssSelectors/selectors/attributes4.html&quot;&gt;View Demo &lt;/a&gt; &lt;/h5&gt;&lt;br /&gt;&lt;hr /&gt;&lt;br /&gt;&lt;h2&gt;&lt;span&gt; 14. &lt;/span&gt;X[href$=&#39;.jpg&#39;]&lt;/h2&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;&lt;br /&gt;a[href$=&#39;.jpg&#39;] {&lt;br /&gt;  color: red;&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;Again, we use a regular expressions symbol, &lt;code&gt;$&lt;/code&gt;, to refer to the end of a string. In this case, we’re searching for all anchors which link to an image — or at least a url that ends with &lt;code&gt;.jpg&lt;/code&gt;. Keep in mind that this certainly won’t work for &lt;code&gt;gifs&lt;/code&gt; and &lt;code&gt;pngs&lt;/code&gt;.&lt;/p&gt;&lt;br /&gt;&lt;h5&gt; &lt;a href=&quot;http://d2o0t5hpnwv4c1.cloudfront.net/840_cssSelectors/selectors/attributes5.html&quot;&gt;View Demo &lt;/a&gt; &lt;/h5&gt;&lt;br /&gt;&lt;hr /&gt;&lt;br /&gt;&lt;h2&gt;&lt;span&gt; 15.&lt;/span&gt; X[data-*=&#39;foo&#39;]&lt;/h2&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;&lt;br /&gt;a[data-filetype=&#39;image&#39;] {&lt;br /&gt;  color: red;&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;Refer back to number eight; how do we compensate for all of the various image types: &lt;code&gt;png&lt;/code&gt;, &lt;code&gt;jpeg,&lt;/code&gt;&lt;code&gt;jpg&lt;/code&gt;, &lt;code&gt;gif&lt;/code&gt;? Well, we could create multiple selectors, such as:&lt;/p&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;&lt;br /&gt;a[href$=&#39;.jpg&#39;],&lt;br /&gt;a[href$=&#39;.jpeg&#39;],&lt;br /&gt;a[href$=&#39;.png&#39;],&lt;br /&gt;a[href$=&#39;.gif&#39;] {&lt;br /&gt;  color: red;&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;But, that’s a pain in the butt, and is inefficient. Another possible solution is to use custom attributes. What if we added our own &lt;code&gt;data-filetype&lt;/code&gt; attribute to each anchor that links to an image?&lt;/p&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;&lt;br /&gt;&amp;lt;a href=&quot;path/to/image.jpg&quot; data-filetype=&quot;image&quot;&amp;gt; Image Link &amp;lt;/a&amp;gt;&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;Then, with that &lt;em&gt;hook&lt;/em&gt; in place, we can use a standard attributes selector to target only those anchors. &lt;/p&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;&lt;br /&gt;a[data-filetype=&#39;image&#39;] {&lt;br /&gt;  color: red;&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;h5&gt; &lt;a href=&quot;http://d2o0t5hpnwv4c1.cloudfront.net/840_cssSelectors/selectors/attributes6.html&quot;&gt;View Demo &lt;/a&gt; &lt;/h5&gt;&lt;br /&gt;&lt;hr /&gt;&lt;br /&gt;&lt;h2&gt;&lt;span&gt; 16. &lt;/span&gt;X[foo~=&#39;bar&#39;]&lt;/h2&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;&lt;br /&gt;a[data-info~=&#39;external&#39;] {&lt;br /&gt;  color: red;&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;a[data-info~=&#39;image&#39;] {&lt;br /&gt;  border: 1px solid black;&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;Here’s a special one that’ll impress your friends. Not too many people know about this trick. The tilda (&lt;code&gt;~&lt;/code&gt;) symbol allows us to target an attribute which has a spaced-separated list of values. &lt;/p&gt;&lt;br /&gt;&lt;p&gt;Going along with our custom attribute from number nine, above, we could create a &lt;code&gt;data-info&lt;/code&gt; attribute, which can receive a space-separated list of anything we need to make note of. In this case, we’ll make note of external links and links to images — just for the example.&lt;/p&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;&lt;br /&gt;&quot;&amp;lt;a href=&quot;path/to/image.jpg&quot; data-info=&quot;external image&quot;&amp;gt; Click Me, Fool &amp;lt;/a&amp;gt;&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;With that markup in place, now we can target any tags that have either of those values, by using the ~ attributes selector trick.&lt;/p&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;&lt;br /&gt;/* Target data-info attr that contains the value &#39;external&#39; */&lt;br /&gt;a[data-info~=&#39;external&#39;] {&lt;br /&gt;  color: red;&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;/* And which contain the value &#39;image&#39; */&lt;br /&gt;a[data-info~=&#39;image&#39;] {&lt;br /&gt; border: 1px solid black;&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;Pretty nifty, ay?&lt;br /&gt;&lt;br /&gt;&lt;/p&gt;&lt;br /&gt;&lt;h5&gt; &lt;a href=&quot;http://d2o0t5hpnwv4c1.cloudfront.net/840_cssSelectors/selectors/attributes7.html&quot;&gt;View Demo &lt;/a&gt; &lt;/h5&gt;&lt;br /&gt;&lt;hr /&gt;&lt;br /&gt;&lt;h2&gt;&lt;span&gt; 17.&lt;/span&gt; X:checked&lt;/h2&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;&lt;br /&gt;input[type=radio]:checked {&lt;br /&gt;  border: 1px solid black;&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;This pseudo class will only target a user interface element that has been &lt;em&gt;checked&lt;/em&gt; - like a radio button, or checkbox. It&#39;s as simple as that.&lt;/p&gt;&lt;br /&gt;&lt;h5&gt; &lt;a href=&quot;http://d2o0t5hpnwv4c1.cloudfront.net/840_cssSelectors/selectors/checked.html&quot;&gt;View Demo &lt;/a&gt; &lt;/h5&gt;&lt;br /&gt;&lt;hr /&gt;&lt;br /&gt;&lt;h2&gt;&lt;span&gt; 18. &lt;/span&gt;X:after&lt;/h2&gt;&lt;br /&gt;&lt;p&gt;The &lt;code&gt;before&lt;/code&gt; and &lt;code&gt;after&lt;/code&gt; pseudo elements kick butt. Every day, it seems, people are finding new and creative ways to use them effectively. They simply generate content around the selected element.&lt;/p&gt;&lt;br /&gt;&lt;p&gt;Many were first introduced to these classes when they encountered the clear-fix hack.&lt;/p&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;&lt;br /&gt;.clearfix:after {&lt;br /&gt;   content: &#39;&#39;;&lt;br /&gt;   display: block;&lt;br /&gt;   clear: both;&lt;br /&gt;   visibility: hidden;&lt;br /&gt;   font-size: 0;&lt;br /&gt;   height: 0;&lt;br /&gt;   }&lt;br /&gt;&lt;br /&gt;.clearfix {&lt;br /&gt;  _display: inline-block;&lt;br /&gt;  _height: 1%;&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;This &lt;em&gt;hack&lt;/em&gt; uses the &lt;code&gt;:after&lt;/code&gt; pseudo element to append a space after the element, and then clear it. It&#39;s an excellent trick to have in your tool bag, particularly in the cases when the &lt;code&gt;overflow: hidden;&lt;/code&gt; method isn&#39;t possible.&lt;/p&gt;&lt;br /&gt;&lt;p&gt;For another creative use of this, &lt;a href=&quot;http://net.tutsplus.com/tutorials/html-css-techniques/quick-tip-getting-clever-with-css3-shadows/&quot;&gt;refer to my quick tip on creating shadows&lt;/a&gt;. &lt;/p&gt;&lt;br /&gt;&lt;blockquote&gt;&lt;br /&gt;&lt;p&gt;According to the CSS3 Selectors specification, you should technically use the pseudo element syntax of two colons &lt;code&gt;::&lt;/code&gt;. However, to remain compatible, the user-agent will accept a single colon usage as well.&lt;/p&gt;&lt;br /&gt;&lt;/blockquote&gt;&lt;br /&gt;&lt;hr /&gt;&lt;br /&gt;&lt;h2&gt;&lt;span&gt; 19. &lt;/span&gt;X:hover&lt;/h2&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;&lt;br /&gt;div:hover {&lt;br /&gt; background: #e3e3e3;&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;Oh come on. You know this one. The official term for this is &lt;code&gt;user action pseudo class&lt;/code&gt;. It sounds confusing, but it really isn&#39;t. Want to apply specific styling when a user hovers over an element? This will get the job done!&lt;/p&gt;&lt;br /&gt;&lt;blockquote&gt;&lt;br /&gt;&lt;p&gt;Keep in mind that older version of Internet Explorer don&#39;t respond when the &lt;code&gt;:hover&lt;/code&gt; pseudo class is applied to anything other than an anchor tag. &lt;/p&gt;&lt;br /&gt;&lt;/blockquote&gt;&lt;br /&gt;&lt;p&gt;You&#39;ll most often use this selector when applying, for example, a &lt;code&gt;border-bottom&lt;/code&gt; to anchor tags, when hovered over.&lt;/p&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;&lt;br /&gt;a:hover {&lt;br /&gt;border-bottom: 1px solid black;&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;blockquote&gt;&lt;br /&gt;&lt;p&gt;&lt;strong&gt;Pro-tip&lt;/strong&gt; - &lt;code&gt;border-bottom: 1px solid black;&lt;/code&gt; looks better than &lt;code&gt;text-decoration: underline;&lt;/code&gt;. &lt;/p&gt;&lt;br /&gt;&lt;/blockquote&gt;&lt;br /&gt;&lt;hr /&gt;&lt;br /&gt;&lt;h2&gt;&lt;span&gt; 20. &lt;/span&gt; X:not(selector)&lt;/h2&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;&lt;br /&gt;div:not(#container) {&lt;br /&gt;  color: blue;&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;The &lt;code&gt;negation&lt;/code&gt; psuedo class is particularly helpful. Let&#39;s say I want to select all divs, except for the one which has an &lt;code&gt;id&lt;/code&gt; of &lt;code&gt;container&lt;/code&gt;. The snippet above will handle that task perfectly.&lt;/p&gt;&lt;br /&gt;&lt;p&gt;Or, if I wanted to select every single element (not advised) except for paragraph tags, we could do:&lt;/p&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;&lt;br /&gt;*:not(p) {&lt;br /&gt; color: green;&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;h5&gt; &lt;a href=&quot;http://d2o0t5hpnwv4c1.cloudfront.net/840_cssSelectors/selectors/not.html&quot;&gt;View Demo &lt;/a&gt; &lt;/h5&gt;&lt;br /&gt;&lt;hr /&gt;&lt;br /&gt;&lt;h2&gt;&lt;span&gt; 21. &lt;/span&gt; X::psuedoElement&lt;/h2&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;&lt;br /&gt;p::first-line {&lt;br /&gt;  font-weight: bold;&lt;br /&gt;  font-size: 1.2em;&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;We can use pseudo elements (designated by &lt;code&gt;::&lt;/code&gt;) to style fragments of an element, such as the first line, or the first letter. Keep in mind that these must be applied to block level elements in order to take effect.&lt;/p&gt;&lt;br /&gt;&lt;blockquote&gt;&lt;br /&gt;&lt;p&gt;A pseudo-element is composed of two colons: &lt;code&gt;::&lt;/code&gt;&lt;/p&gt;&lt;br /&gt;&lt;/blockquote&gt;&lt;br /&gt;&lt;h4&gt;Target the First Letter of a Paragraph&lt;/h4&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;&lt;br /&gt;p::first-letter {&lt;br /&gt;  float: left;&lt;br /&gt;  font-size: 2em;&lt;br /&gt;  font-weight: bold;&lt;br /&gt;  font-family: cursive;&lt;br /&gt;  padding-right: 2px;&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;This snippet is an abstraction that will find all paragraphs on the page, and then sub-target only the first letter of that element. &lt;/p&gt;&lt;br /&gt;&lt;p&gt;This is most often used to create newspaper-like styling for the first-letter of an article.&lt;/p&gt;&lt;br /&gt;&lt;h4&gt;Target the First Line of a Paragraph&lt;/h4&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;&lt;br /&gt;p::first-line {&lt;br /&gt;  font-weight: bold;&lt;br /&gt;  font-size: 1.2em;&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;Similarly, the &lt;code&gt;::first-line&lt;/code&gt; pseudo element will, as expected, style the first line of the element only. &lt;/p&gt;&lt;br /&gt;&lt;blockquote&gt;&lt;br /&gt;&lt;p&gt;&#39;For compatibility with existing style sheets, user agents must also accept the previous one-colon notation for pseudo-elements introduced in CSS levels 1 and 2 (namely, :first-line, :first-letter, :before and :after). This compatibility is not allowed for the new pseudo-elements introduced in this specification.&#39; - &lt;a href=&quot;http://www.w3.org/TR/css3-selectors/&quot;&gt;Source&lt;/a&gt;&lt;/p&gt;&lt;br /&gt;&lt;/blockquote&gt;&lt;br /&gt;&lt;h5&gt; &lt;a href=&quot;http://d2o0t5hpnwv4c1.cloudfront.net/840_cssSelectors/selectors/pseudoElements.html&quot;&gt;View Demo &lt;/a&gt; &lt;/h5&gt;&lt;br /&gt;&lt;hr /&gt;&lt;br /&gt;&lt;h2&gt;&lt;span&gt; 22. &lt;/span&gt;X:nth-child(n)&lt;/h2&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;&lt;br /&gt;li:nth-child(3) {&lt;br /&gt;  color: red;&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;Remember the days when we had no way to target specific elements in a stack? The &lt;code&gt;nth-child&lt;/code&gt; pseudo class solves that!&lt;/p&gt;&lt;br /&gt;&lt;p&gt;Please note that &lt;code&gt;nth-child&lt;/code&gt; accepts an integer as a parameter, however, this is not zero-based. If you wish to target the second list item, use &lt;code&gt;li:nth-child(2)&lt;/code&gt;. &lt;/p&gt;&lt;br /&gt;&lt;p&gt;We can even use this to select a variable set of children. For example, we could do &lt;code&gt;li:nth-child(4n)&lt;/code&gt; to select every fourth list item. &lt;/p&gt;&lt;br /&gt;&lt;h5&gt; &lt;a href=&quot;http://d2o0t5hpnwv4c1.cloudfront.net/840_cssSelectors/selectors/nth.html&quot;&gt;View Demo &lt;/a&gt; &lt;/h5&gt;&lt;br /&gt;&lt;hr /&gt;&lt;br /&gt;&lt;h2&gt;&lt;span&gt; 23. &lt;/span&gt;X:nth-last-child(n)&lt;/h2&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;&lt;br /&gt;li:nth-last-child(2) {&lt;br /&gt;  color: red;&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;What if you had a huge list of items in a &lt;code&gt;ul&lt;/code&gt;, and only needed to access, say, the third to the last item? Rather than doing &lt;code&gt;li:nth-child(397)&lt;/code&gt;, you could instead use the &lt;code&gt;nth-last-child&lt;/code&gt; pseudo class.&lt;/p&gt;&lt;br /&gt;&lt;p&gt;This technique works almost identically from number sixteen above, however, the difference is that it begins at the end of the collection, and works its way back.&lt;/p&gt;&lt;br /&gt;&lt;h5&gt; &lt;a href=&quot;http://d2o0t5hpnwv4c1.cloudfront.net/840_cssSelectors/selectors/nthLast.html&quot;&gt;View Demo &lt;/a&gt; &lt;/h5&gt;&lt;br /&gt;&lt;hr /&gt;&lt;br /&gt;&lt;h2&gt;&lt;span&gt; 24. &lt;/span&gt;X:nth-of-type(n)&lt;/h2&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;&lt;br /&gt;ul:nth-of-type(3) {&lt;br /&gt;  border: 1px solid black;&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;There will be times when, rather than selecting a &lt;code&gt;child&lt;/code&gt;, you instead need to select according to the &lt;code&gt;type&lt;/code&gt; of element. &lt;/p&gt;&lt;br /&gt;&lt;p&gt;Imagine mark-up that contains five unordered lists. If you wanted to style only the third &lt;code&gt;ul&lt;/code&gt;, and didn&#39;t have a unique &lt;code&gt;id&lt;/code&gt; to hook into, you could use the &lt;code&gt;nth-of-type(n)&lt;/code&gt; pseudo class. In the snippet above, only the third &lt;code&gt;ul&lt;/code&gt; will have a border around it.&lt;/p&gt;&lt;br /&gt;&lt;h5&gt; &lt;a href=&quot;http://d2o0t5hpnwv4c1.cloudfront.net/840_cssSelectors/selectors/nthOfType.html&quot;&gt;View Demo &lt;/a&gt; &lt;/h5&gt;&lt;br /&gt;&lt;hr /&gt;&lt;br /&gt;&lt;h2&gt;&lt;span&gt; 25. &lt;/span&gt;X:nth-last-of-type(n)&lt;/h2&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;&lt;br /&gt;ul:nth-last-of-type(3) {&lt;br /&gt;  border: 1px solid black;&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;And yes, to remain consistent, we can also use &lt;code&gt;nth-last-of-type&lt;/code&gt; to begin at the end of the selectors list, and work our way back to target the desired element.&lt;/p&gt;&lt;br /&gt;&lt;hr /&gt;&lt;br /&gt;&lt;h2&gt;&lt;span&gt; 26. &lt;/span&gt;X:first-child&lt;/h2&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;&lt;br /&gt;ul li:first-child {&lt;br /&gt;  border-top: none;&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;This structural pseudo class allows us to target only the first child of the element&#39;s parent. You&#39;ll often use this to remove borders from the first and last list items. &lt;/p&gt;&lt;br /&gt;&lt;p&gt;For example, let&#39;s say you have a list of rows, and each one has a &lt;code&gt;border-top&lt;/code&gt; and a &lt;code&gt;border-bottom&lt;/code&gt;. Well, with that arrangement, the first and last item in that set will look a bit odd. &lt;/p&gt;&lt;br /&gt;&lt;p&gt;Many designers apply classes of &lt;code&gt;first&lt;/code&gt; and &lt;code&gt;last&lt;/code&gt; to compensate for this. Instead, you can use these pseudo classes.&lt;/p&gt;&lt;br /&gt;&lt;h5&gt; &lt;a href=&quot;http://d2o0t5hpnwv4c1.cloudfront.net/840_cssSelectors/selectors/firstChild.html&quot;&gt;View Demo &lt;/a&gt; &lt;/h5&gt;&lt;br /&gt;&lt;hr /&gt;&lt;br /&gt;&lt;h2&gt;&lt;span&gt; 27. &lt;/span&gt;X:last-child&lt;/h2&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;&lt;br /&gt;ul &amp;gt; li:last-child {&lt;br /&gt;  color: green;&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;The opposite of &lt;code&gt;first-child&lt;/code&gt;, &lt;code&gt;last-child&lt;/code&gt; will target the last item of the element&#39;s parent.&lt;/p&gt;&lt;br /&gt;&lt;h3&gt;Example&lt;/h3&gt;&lt;br /&gt;&lt;p&gt;Let&#39;s build a simple example to demonstrate one possible use of these classes. We&#39;ll create a styled list item. &lt;/p&gt;&lt;br /&gt;&lt;h4&gt;Markup&lt;/h4&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;&lt;br /&gt; &amp;lt;ul&amp;gt;&lt;br /&gt;    &amp;lt;li&amp;gt; List Item &amp;lt;/li&amp;gt;&lt;br /&gt;    &amp;lt;li&amp;gt; List Item &amp;lt;/li&amp;gt;&lt;br /&gt;    &amp;lt;li&amp;gt; List Item &amp;lt;/li&amp;gt;&lt;br /&gt; &amp;lt;/ul&amp;gt;&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;Nothing special here; just a simple list.&lt;/p&gt;&lt;br /&gt;&lt;h4&gt;CSS&lt;/h4&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;&lt;br /&gt;ul {&lt;br /&gt;width: 200px;&lt;br /&gt;background: #292929;&lt;br /&gt;color: white;&lt;br /&gt;list-style: none;&lt;br /&gt;padding-left: 0;&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;li {&lt;br /&gt;padding: 10px;&lt;br /&gt;border-bottom: 1px solid black;&lt;br /&gt;border-top: 1px solid #3c3c3c;&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;This styling will set a background, remove the browser-default padding on the &lt;code&gt;ul&lt;/code&gt;, and apply borders to each &lt;code&gt;li&lt;/code&gt; to provide a bit of depth.&lt;/p&gt;&lt;br /&gt;&lt;div&gt;&lt;br /&gt;&lt;img src=&quot;http://d2o0t5hpnwv4c1.cloudfront.net/840_cssSelectors/extraBorders.png&quot; alt=&quot;Styled List&quot; /&gt;&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;blockquote&gt;&lt;br /&gt;&lt;p&gt;To add depth to your lists, apply a &lt;code&gt;border-bottom&lt;/code&gt; to each &lt;code&gt;li&lt;/code&gt; that is a shade or two darker than the &lt;code&gt;li&lt;/code&gt;&#39;s background color. Next, apply a &lt;code&gt;border-top&lt;/code&gt; which is a couple shades &lt;em&gt;lighter&lt;/em&gt;. &lt;/p&gt;&lt;br /&gt;&lt;/blockquote&gt;&lt;br /&gt;&lt;p&gt;The only problem, as shown in the image above, is that a border will be applied to the very top and bottom of the unordered list - which looks odd. Let&#39;s use the &lt;code&gt;:first-child&lt;/code&gt; and &lt;code&gt;:last-child&lt;/code&gt; pseudo classes to fix this.&lt;/p&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;&lt;br /&gt;li:first-child {&lt;br /&gt;   border-top: none;&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;li:last-child {&lt;br /&gt;  border-bottom: none;&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;div&gt;&lt;br /&gt;&lt;img src=&quot;http://d2o0t5hpnwv4c1.cloudfront.net/840_cssSelectors/fixed.png&quot; alt=&quot;Fixed&quot; /&gt;&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;p&gt;There we go; that fixes it!&lt;/p&gt;&lt;br /&gt;&lt;h5&gt; &lt;a href=&quot;http://d2o0t5hpnwv4c1.cloudfront.net/840_cssSelectors/selectors/firstChild.html&quot;&gt;View Demo &lt;/a&gt; &lt;/h5&gt;&lt;br /&gt;&lt;hr /&gt;&lt;br /&gt;&lt;h2&gt;&lt;span&gt; 28. &lt;/span&gt;X:only-child&lt;/h2&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;&lt;br /&gt;div p:only-child {&lt;br /&gt;  color: red;&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;Truthfully, you probably won&#39;t find yourself using the &lt;code&gt;only-child&lt;/code&gt; pseudo class too often. Nonetheless, it&#39;s available, should you need it.&lt;/p&gt;&lt;br /&gt;&lt;p&gt;It allows you to target elements which are the &lt;em&gt;only&lt;/em&gt; child of its parent. For example, referencing the snippet above, only the paragraph that is the only child of the &lt;code&gt;div&lt;/code&gt; will be colored, red.&lt;/p&gt;&lt;br /&gt;&lt;p&gt;Let&#39;s assume the following markup.&lt;/p&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;&lt;br /&gt;&amp;lt;div&amp;gt;&amp;lt;p&amp;gt; My paragraph here. &amp;lt;/p&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;div&amp;gt;&lt;br /&gt;  &amp;lt;p&amp;gt; Two paragraphs total. &amp;lt;/p&amp;gt;&lt;br /&gt;  &amp;lt;p&amp;gt; Two paragraphs total. &amp;lt;/p&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;In this case, the second &lt;code&gt;div&lt;/code&gt;&#39;s paragraphs will not be targeted; only the first &lt;code&gt;div&lt;/code&gt;. As soon as you apply more than one child to an element, the &lt;code&gt;only-child&lt;/code&gt; pseudo class ceases to take effect.&lt;/p&gt;&lt;br /&gt;&lt;h5&gt; &lt;a href=&quot;http://d2o0t5hpnwv4c1.cloudfront.net/840_cssSelectors/selectors/onlyChild.html&quot;&gt;View Demo &lt;/a&gt; &lt;/h5&gt;&lt;br /&gt;&lt;hr /&gt;&lt;br /&gt;&lt;h2&gt;&lt;span&gt; 29. &lt;/span&gt;X:only-of-type&lt;/h2&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;&lt;br /&gt;li:only-of-type {&lt;br /&gt;  font-weight: bold;&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;This structural pseudo class can be used in some clever ways. It will target elements that do not have any siblings within its parent container. As an example, let&#39;s target all &lt;code&gt;ul&lt;/code&gt;s, which have only a single list item. &lt;/p&gt;&lt;br /&gt;&lt;p&gt;First, ask yourself how you would accomplish this task? You could do &lt;code&gt;ul li&lt;/code&gt;, but, this would target &lt;em&gt;all&lt;/em&gt; list items. The only solution is to use &lt;code&gt;only-of-type&lt;/code&gt;.&lt;/p&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;&lt;br /&gt;ul &amp;gt; li:only-of-type {&lt;br /&gt;  font-weight: bold;&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;h5&gt; &lt;a href=&quot;http://d2o0t5hpnwv4c1.cloudfront.net/840_cssSelectors/selectors/onlyOfType.html&quot;&gt;View Demo &lt;/a&gt; &lt;/h5&gt;&lt;br /&gt;&lt;hr /&gt;&lt;br /&gt;&lt;h2&gt;&lt;span&gt; 30. &lt;/span&gt;X:first-of-type&lt;/h2&gt;&lt;br /&gt;&lt;p&gt;The &lt;code&gt;first-of-type&lt;/code&gt; pseudo class allows you to select the first siblings of its type. &lt;/p&gt;&lt;br /&gt;&lt;h4&gt;A Test&lt;/h4&gt;&lt;br /&gt;&lt;p&gt;To better understand this, let&#39;s have a test. Copy the following mark-up into your code editor:&lt;/p&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;&lt;br /&gt;&amp;lt;div&amp;gt;&lt;br /&gt;  &amp;lt;p&amp;gt; My paragraph here. &amp;lt;/p&amp;gt;&lt;br /&gt;  &amp;lt;ul&amp;gt;&lt;br /&gt;     &amp;lt;li&amp;gt; List Item 1 &amp;lt;/li&amp;gt;&lt;br /&gt;     &amp;lt;li&amp;gt; List Item 2 &amp;lt;/li&amp;gt;&lt;br /&gt;  &amp;lt;/ul&amp;gt;&lt;br /&gt;&lt;br /&gt;  &amp;lt;ul&amp;gt;&lt;br /&gt;     &amp;lt;li&amp;gt; List Item 3 &amp;lt;/li&amp;gt;&lt;br /&gt;     &amp;lt;li&amp;gt; List Item 4 &amp;lt;/li&amp;gt;&lt;br /&gt;  &amp;lt;/ul&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;Now, without reading further, try to figure out how to target only &lt;em&gt;&#39;List Item 2&#39;&lt;/em&gt;. When you&#39;ve figured it out (or given up), read on.&lt;/p&gt;&lt;br /&gt;&lt;h4&gt;Solution 1&lt;/h4&gt;&lt;br /&gt;&lt;p&gt;There are a variety of ways to solve this test. We&#39;ll review a handful of them. Let&#39;s begin by using &lt;code&gt;first-of-type&lt;/code&gt;. &lt;/p&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;&lt;br /&gt;ul:first-of-type &amp;gt; li:nth-child(2) {&lt;br /&gt;  font-weight: bold;&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;This snippet essentially says, &#39;find the first unordered list on the page, then find only the immediate children, which are list items. Next, filter that down to only the second list item in that set.&lt;/p&gt;&lt;br /&gt;&lt;h4&gt;Solution 2&lt;/h4&gt;&lt;br /&gt;&lt;p&gt;Another option is to use the adjacent selector.&lt;/p&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;&lt;br /&gt;p + ul li:last-child {&lt;br /&gt;  font-weight: bold;&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;In this scenario, we find the &lt;code&gt;ul&lt;/code&gt; that immediately proceeds the &lt;code&gt;p&lt;/code&gt; tag, and then find the very last child of the element.&lt;/p&gt;&lt;br /&gt;&lt;h4&gt;Solution 3&lt;/h4&gt;&lt;br /&gt;&lt;p&gt;We can be as obnoxious or as playful as we want with these selectors. &lt;/p&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot;&gt;&lt;br /&gt;ul:first-of-type li:nth-last-child(1) {&lt;br /&gt;  font-weight: bold;&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;p&gt;This time, we grab the first &lt;code&gt;ul&lt;/code&gt; on the page, and then find the very first list item, but starting from the bottom! &lt;img src=&quot;http://net.tutsplus.com/wp-includes/images/smilies/icon_smile.gif&quot; alt=&quot;:)&quot; /&gt; &lt;/p&gt;&lt;br /&gt;&lt;h5&gt; &lt;a href=&quot;http://d2o0t5hpnwv4c1.cloudfront.net/840_cssSelectors/selectors/firstOfType.html&quot;&gt;View Demo &lt;/a&gt; &lt;/h5&gt;&lt;br /&gt;&lt;hr /&gt;&lt;br /&gt;&lt;h2&gt; Conclusion &lt;/h2&gt;&lt;br /&gt;&lt;p&gt;&lt;br /&gt;If you&#39;re compensating for older browsers, like Internet Explorer 6, you still need to be careful when using these newer selectors. But, please don&#39;t let that deter you from learning these. You&#39;d be doing a huge disservice to yourself. &lt;/p&gt;&lt;br /&gt;&lt;p&gt;Secondly, when working with JavaScript libraries, like the popular jQuery, always try to use these native CSS3 selectors over the library&#39;s custom methods/selectors, when possible. It&#39;ll make your code faster, as the selector engine can use the browser&#39;s native parsing, rather than its own. &lt;/p&gt;&lt;br /&gt;&lt;p&gt;Thanks for reading, and I hope you picked up a trick or two! &lt;/p&gt;&lt;div&gt;&lt;br /&gt;&lt;a href=&quot;http://feeds.feedburner.com/~ff/nettuts?a=j6GxxU_jbjk:SnEieZycV3g:yIl2AUoC8zA&quot;&gt;&lt;img src=&quot;http://feeds.feedburner.com/~ff/nettuts?d=yIl2AUoC8zA&quot; border=&quot;0&quot; /&gt;&lt;/a&gt; &lt;a href=&quot;http://feeds.feedburner.com/~ff/nettuts?a=j6GxxU_jbjk:SnEieZycV3g:F7zBnMyn0Lo&quot;&gt;&lt;img src=&quot;http://feeds.feedburner.com/~ff/nettuts?i=j6GxxU_jbjk:SnEieZycV3g:F7zBnMyn0Lo&quot; border=&quot;0&quot; /&gt;&lt;/a&gt; &lt;a href=&quot;http://feeds.feedburner.com/~ff/nettuts?a=j6GxxU_jbjk:SnEieZycV3g:V_sGLiPBpWU&quot;&gt;&lt;img src=&quot;http://feeds.feedburner.com/~ff/nettuts?i=j6GxxU_jbjk:SnEieZycV3g:V_sGLiPBpWU&quot; border=&quot;0&quot; /&gt;&lt;/a&gt; &lt;a href=&quot;http://feeds.feedburner.com/~ff/nettuts?a=j6GxxU_jbjk:SnEieZycV3g:gIN9vFwOqvQ&quot;&gt;&lt;img src=&quot;http://feeds.feedburner.com/~ff/nettuts?i=j6GxxU_jbjk:SnEieZycV3g:gIN9vFwOqvQ&quot; border=&quot;0&quot; /&gt;&lt;/a&gt; &lt;a href=&quot;http://feeds.feedburner.com/~ff/nettuts?a=j6GxxU_jbjk:SnEieZycV3g:TzevzKxY174&quot;&gt;&lt;img src=&quot;http://feeds.feedburner.com/~ff/nettuts?d=TzevzKxY174&quot; border=&quot;0&quot; /&gt;&lt;/a&gt;&lt;br /&gt;&lt;/div&gt;&lt;img src=&quot;http://feeds.feedburner.com/~r/nettuts/~4/j6GxxU_jbjk&quot; height=&quot;1&quot; width=&quot;1&quot; /&gt;&quot;</content><link rel='replies' type='application/atom+xml' href='http://tempocdev.blogspot.com/feeds/1647325191307813171/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://tempocdev.blogspot.com/2010/11/30-css-selectors-you-must-memorize.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/398584839682458587/posts/default/1647325191307813171'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/398584839682458587/posts/default/1647325191307813171'/><link rel='alternate' type='text/html' href='http://tempocdev.blogspot.com/2010/11/30-css-selectors-you-must-memorize.html' title='The 30 CSS Selectors you Must Memorize'/><author><name>Gabriel F. Rodríguez</name><uri>http://www.blogger.com/profile/10332533752137475497</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-398584839682458587.post-7165488927064035642</id><published>2010-10-28T10:35:00.000-07:00</published><updated>2010-10-28T10:35:56.222-07:00</updated><title type='text'>Home - Gradle</title><content type='html'>Interesting project tool: &lt;a href=&quot;http://gradle.org/index.php&quot;&gt;Home - Gradle&lt;/a&gt;</content><link rel='replies' type='application/atom+xml' href='http://tempocdev.blogspot.com/feeds/7165488927064035642/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://tempocdev.blogspot.com/2010/10/home-gradle.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/398584839682458587/posts/default/7165488927064035642'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/398584839682458587/posts/default/7165488927064035642'/><link rel='alternate' type='text/html' href='http://tempocdev.blogspot.com/2010/10/home-gradle.html' title='Home - Gradle'/><author><name>Gabriel F. Rodríguez</name><uri>http://www.blogger.com/profile/10332533752137475497</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-398584839682458587.post-5724200974529551161</id><published>2010-10-20T15:18:00.000-07:00</published><updated>2010-10-20T15:18:47.726-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="frameworks"/><category scheme="http://www.blogger.com/atom/ns#" term="REST"/><category scheme="http://www.blogger.com/atom/ns#" term="web services"/><title type='text'>Apache CXF</title><content type='html'>Intend to explore &lt;a href=&quot;http://cxf.apache.org/&quot;&gt;Apache CXF&lt;/a&gt;</content><link rel='replies' type='application/atom+xml' href='http://tempocdev.blogspot.com/feeds/5724200974529551161/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://tempocdev.blogspot.com/2010/10/apache-cxf-index.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/398584839682458587/posts/default/5724200974529551161'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/398584839682458587/posts/default/5724200974529551161'/><link rel='alternate' type='text/html' href='http://tempocdev.blogspot.com/2010/10/apache-cxf-index.html' title='Apache CXF'/><author><name>Gabriel F. Rodríguez</name><uri>http://www.blogger.com/profile/10332533752137475497</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-398584839682458587.post-884148826425909184</id><published>2010-10-18T14:09:00.000-07:00</published><updated>2010-10-18T14:09:25.473-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="email"/><category scheme="http://www.blogger.com/atom/ns#" term="Java"/><category scheme="http://www.blogger.com/atom/ns#" term="SMTP"/><title type='text'>Send email using Gmail as a free SMTP with Java Mail</title><content type='html'>This has bugged me forever. No more!&lt;br /&gt;
&lt;br /&gt;
&lt;script class=&quot;brush: java&quot; type=&quot;syntaxhighlighter&quot;&gt;
&lt;![CDATA[
package mypackage;

import java.security.Security;
import java.util.Properties;

import javax.mail.Message;
import javax.mail.MessagingException;
import javax.mail.Session;
import javax.mail.Transport;
import javax.mail.internet.InternetAddress;
import javax.mail.internet.MimeMessage;
import org.slf4j.Logger;

/**
 *
 * @author tempoc
 */
public class GmailMailService implements MailService {
    private static final String TEXT_PLAIN = &quot;text/plain&quot;;
    private static final String SMTP_HOST_NAME = &quot;smtp.gmail.com&quot;;
    private static final String SMTP_AUTH_USER = &quot;you@gmail.com&quot;;
    private static final String SMTP_AUTH_PWD = &quot;your_password&quot;;

    private Properties props;

    private Logger log;

    {
        props = System.getProperties();
        props.setProperty(&quot;mail.smtps.host&quot;, SMTP_HOST_NAME);
        props.setProperty(&quot;mail.smtps.auth&quot;, &quot;true&quot;);
    }

    public GmailMailService(Logger log) {
        this.log = log;
    }

    public void send(String to, String subject, String message) throws MessagingException {
        log.debug(&quot;Will attempt to send message to &quot; + to);
        Security.addProvider(new com.sun.net.ssl.internal.ssl.Provider());

        Session mailSession = Session.getDefaultInstance(props, null);
        
        mailSession.setDebug(true);

        MimeMessage msg = new MimeMessage(mailSession);

        InternetAddress fromAddr = null;
        InternetAddress toAddr = null;

        fromAddr = new InternetAddress(SMTP_AUTH_USER);
        toAddr = new InternetAddress(to);

        if(fromAddr!=null &amp;&amp; toAddr!=null) {
            msg.setSender(fromAddr);
            msg.setSubject(subject);
            msg.setContent(message, TEXT_PLAIN);
            msg.setRecipient(Message.RecipientType.TO, toAddr);
            Transport transport = mailSession.getTransport(&quot;smtps&quot;);
            transport.connect(SMTP_HOST_NAME, SMTP_AUTH_USER, SMTP_AUTH_PWD);
            transport.sendMessage(msg, msg.getAllRecipients());
        }
        
    }

}

]]&gt;
&lt;/script&gt;&lt;br /&gt;
&lt;br /&gt;
This can be simplified to be tested with a Linux sendmail server or &lt;a href=&quot;http://james.apache.org/&quot;&gt;Apache James&lt;/a&gt; on Windows. Just make sure you test this on a network that won&#39;t block your test calls otherwise you&#39;ll go crazy trying to debug and won&#39;t find a problem in your code or configuration. Also make sure to poke the right holes through your firewall.</content><link rel='replies' type='application/atom+xml' href='http://tempocdev.blogspot.com/feeds/884148826425909184/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://tempocdev.blogspot.com/2010/10/send-email-using-gmail-as-free-smtp.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/398584839682458587/posts/default/884148826425909184'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/398584839682458587/posts/default/884148826425909184'/><link rel='alternate' type='text/html' href='http://tempocdev.blogspot.com/2010/10/send-email-using-gmail-as-free-smtp.html' title='Send email using Gmail as a free SMTP with Java Mail'/><author><name>Gabriel F. Rodríguez</name><uri>http://www.blogger.com/profile/10332533752137475497</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-398584839682458587.post-8659759153537807879</id><published>2010-10-18T13:57:00.001-07:00</published><updated>2010-10-18T13:57:54.849-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="syntax highlighting"/><title type='text'>Excellent syntax highlighting for websites and blogs!</title><content type='html'>&lt;a href=&quot;http://alexgorbatchev.com/SyntaxHighlighter/&quot;&gt;http://alexgorbatchev.com/SyntaxHighlighter/&lt;/a&gt;</content><link rel='replies' type='application/atom+xml' href='http://tempocdev.blogspot.com/feeds/8659759153537807879/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://tempocdev.blogspot.com/2010/10/excellent-syntax-highlighting-for.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/398584839682458587/posts/default/8659759153537807879'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/398584839682458587/posts/default/8659759153537807879'/><link rel='alternate' type='text/html' href='http://tempocdev.blogspot.com/2010/10/excellent-syntax-highlighting-for.html' title='Excellent syntax highlighting for websites and blogs!'/><author><name>Gabriel F. Rodríguez</name><uri>http://www.blogger.com/profile/10332533752137475497</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-398584839682458587.post-8842578743732778364</id><published>2010-10-13T09:26:00.000-07:00</published><updated>2010-10-13T09:26:02.547-07:00</updated><title type='text'>Usability Resources to Win Arguments</title><content type='html'>&lt;a href=&quot;http://www.webdesignerdepot.com/2010/10/usability-resources-to-win-arguments/&quot;&gt;Usability Resources to Win Arguments&lt;/a&gt;: &quot;&lt;p&gt;&lt;a href=&quot;http://netdna.webdesignerdepot.com/uploads/2010/10/thumb1.jpg&quot;&gt;&lt;img title=&quot;thumb&quot; src=&quot;http://netdna.webdesignerdepot.com/uploads/2010/10/thumb1.jpg&quot; alt=&quot;thumb&quot; width=&quot;200&quot; height=&quot;160&quot; /&gt;&lt;/a&gt;Today’s post is a big one and it’s most definitely one for your  bookmarks menu, because from time to time when speaking with clients it  becomes necessary to have material to backup the statements which you  are making.&lt;/p&gt;&lt;p&gt;Sometimes clients will suggest things such as forcing all users to register with a six page long form before they can even access the site. They aren’t web professionals, it’s not their fault for not knowing that this isn’t a good idea from a usability perspective.&lt;/p&gt;&lt;p&gt;If you’re going to convince them that this is a bad idea, however, then you’re going to need some rock solid material to back that up. While an element of trust is always important to a working relationship, you have to respect that sometimes clients will just need to see the facts in front of them to fully understand that what you’re saying is correct.&lt;/p&gt;&lt;p&gt;So, what we’ve done for you today is compiled a list of some of the biggest, most compelling usability articles which address common issues. Hopefully this should help you during tough conversations about what does and doesn’t work on a a website.&lt;/p&gt;&lt;p&gt;Bookmark this post, come back to it, use it in meetings and educate  your clients on the things which work for other websites, so that they might also work for them.&lt;/p&gt;&lt;p&gt;&lt;span&gt;&lt;/span&gt;&lt;/p&gt;&lt;h1&gt;How Not Forcing Users to Register Increased Sales by $300million&lt;/h1&gt;&lt;p&gt;&lt;a href=&quot;http://www.uie.com/articles/three_hund_million_button/&quot;&gt;&lt;img src=&quot;http://netdna.webdesignerdepot.com/uploads/2010/07/129.jpg&quot; alt=&quot;1&quot; width=&quot;615&quot; height=&quot;200&quot; /&gt;&lt;/a&gt;&lt;/p&gt;&lt;p&gt;A truly fascinating article covering how one ecommerce site removed   forced user-registration during the checkout process, with a result of a   $300million increase in revenue. Very impressive.&lt;/p&gt;&lt;p&gt;&lt;br /&gt;&lt;/p&gt;&lt;h1&gt;10 Useful Usability Findings and Guidelines&lt;/h1&gt;&lt;p&gt;&lt;a href=&quot;http://www.smashingmagazine.com/2009/09/24/10-useful-usability-findings-and-guidelines/&quot;&gt;&lt;img src=&quot;http://netdna.webdesignerdepot.com/uploads/2010/07/229.jpg&quot; alt=&quot;2&quot; width=&quot;615&quot; height=&quot;200&quot; /&gt;&lt;/a&gt;&lt;/p&gt;&lt;ul&gt;&lt;li&gt;Form labels work best above the field&lt;/li&gt;&lt;li&gt;Users focus on faces&lt;/li&gt;&lt;li&gt;Quality of design is an indicator of credibility&lt;/li&gt;&lt;li&gt;Most users &lt;em&gt;do&lt;/em&gt; know how to scroll&lt;/li&gt;&lt;li&gt;Blue is the best color for links&lt;/li&gt;&lt;li&gt;The ideal search box is 27 characters wide&lt;/li&gt;&lt;li&gt;White space improves comprehension&lt;/li&gt;&lt;li&gt;Effective user testing doesn’t have to be extensive&lt;/li&gt;&lt;li&gt;Informative product pages stand out&lt;/li&gt;&lt;li&gt;Most users are blind to advertising&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;&lt;br /&gt;&lt;/p&gt;&lt;h1&gt;Browser Resolution Stats by Google&lt;/h1&gt;&lt;p&gt;&lt;a href=&quot;http://browsersize.googlelabs.com/&quot;&gt;&lt;img src=&quot;http://netdna.webdesignerdepot.com/uploads/2010/07/325.jpg&quot; alt=&quot;3&quot; width=&quot;615&quot; height=&quot;200&quot; /&gt;&lt;/a&gt;&lt;/p&gt;&lt;p&gt;A big diagram by google showing browsers sizes overlaid on top of a web page and where you should place call to actions to ensure that they are immediately visible without the need to scroll.&lt;/p&gt;&lt;p&gt;&lt;br /&gt;&lt;/p&gt;&lt;h1&gt;The myth of the page fold: evidence from user testing&lt;/h1&gt;&lt;p&gt;&lt;a href=&quot;http://www.cxpartners.co.uk/thoughts/the_myth_of_the_page_fold_evidence_from_user_testing.htm&quot;&gt;&lt;img src=&quot;http://netdna.webdesignerdepot.com/uploads/2010/07/426.jpg&quot; alt=&quot;4&quot; width=&quot;615&quot; height=&quot;200&quot; /&gt;&lt;/a&gt;&lt;/p&gt;&lt;p&gt;“People tell us that they don’t mind scrolling and the behaviour we see  in user testing backs that up. We see that people are more than  comfortable scrolling long, long pages to find what they are looking  for. A quick snoop around the web will show you successful brands that  are not worrying about the fold either.”&lt;/p&gt;&lt;p&gt;&lt;br /&gt;&lt;/p&gt;&lt;h1&gt;247 web usability guidelines&lt;/h1&gt;&lt;p&gt;&lt;a href=&quot;http://www.userfocus.co.uk/resources/guidelines.html&quot;&gt;&lt;img src=&quot;http://netdna.webdesignerdepot.com/uploads/2010/07/517.jpg&quot; alt=&quot;5&quot; width=&quot;615&quot; height=&quot;200&quot; /&gt;&lt;/a&gt;&lt;/p&gt;&lt;p&gt;A massive post of usability articles covering:&lt;/p&gt;&lt;ul&gt;&lt;li&gt;Home page usability: 20 guidelines to evaluate the usability of home pages.&lt;/li&gt;&lt;li&gt;Task orientation: 44 guidelines to evaluate how well a web site supports the users tasks.&lt;/li&gt;&lt;li&gt;Navigation and IA: 29 guidelines to evaluate navigation and information architecture.&lt;/li&gt;&lt;li&gt;Forms and data entry: 23 guidelines to evaluate forms and data entry.&lt;/li&gt;&lt;li&gt;Trust and credibility: 13 guidelines to evaluate trust and credibility.&lt;/li&gt;&lt;li&gt;Writing and content quality: 23 guidelines to evaluate writing and content quality.&lt;/li&gt;&lt;li&gt;Page layout and visual design: 38 guidelines to evaluate page layout and visual design.&lt;/li&gt;&lt;li&gt;Search usability: 20 guidelines to evaluate search.&lt;/li&gt;&lt;li&gt;Help, feedback and error tolerance: 37 guidelines to evaluate help, feedback and errors&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;&lt;br /&gt;&lt;/p&gt;&lt;h1&gt;An Introduction to Using Patterns in Web Design&lt;/h1&gt;&lt;p&gt;&lt;a href=&quot;http://37signals.com/papers/introtopatterns//index&quot;&gt;&lt;img src=&quot;http://netdna.webdesignerdepot.com/uploads/2010/07/616.jpg&quot; alt=&quot;6&quot; width=&quot;615&quot; height=&quot;200&quot; /&gt;&lt;/a&gt;&lt;/p&gt;&lt;p&gt;A fascinating article covering the use of patterns for usability in web design, or “chunks” as the author calls them!&lt;/p&gt;&lt;p&gt;&lt;br /&gt;&lt;/p&gt;&lt;h1&gt;F-Shaped Pattern For Reading Web Content&lt;/h1&gt;&lt;p&gt;&lt;a href=&quot;http://www.useit.com/alertbox/reading_pattern.html&quot;&gt;&lt;img src=&quot;http://netdna.webdesignerdepot.com/uploads/2010/07/715.jpg&quot; alt=&quot;7&quot; width=&quot;615&quot; height=&quot;200&quot; /&gt;&lt;/a&gt;&lt;/p&gt;&lt;p&gt;Eye-tracking visualizations show that users often read Web pages in an  F-shaped pattern: two horizontal stripes followed by a vertical stripe.&lt;/p&gt;&lt;p&gt;&lt;br /&gt;&lt;/p&gt;&lt;h1&gt;Top Ten Mistakes in Web Design&lt;/h1&gt;&lt;p&gt;&lt;a href=&quot;http://www.useit.com/alertbox/9605.html&quot;&gt;&lt;img src=&quot;http://netdna.webdesignerdepot.com/uploads/2010/07/814.jpg&quot; alt=&quot;8&quot; width=&quot;615&quot; height=&quot;200&quot; /&gt;&lt;/a&gt;&lt;/p&gt;&lt;p&gt;The ten most egregious offenses against users. Web design disasters and  HTML horrors are legion, though many usability atrocities are less  common than they used to be.&lt;/p&gt;&lt;p&gt;&lt;br /&gt;&lt;/p&gt;&lt;h1&gt;Weblog Usability: The Top Ten Design Mistakes&lt;/h1&gt;&lt;p&gt;&lt;a href=&quot;http://www.useit.com/alertbox/weblogs.html&quot;&gt;&lt;img src=&quot;http://netdna.webdesignerdepot.com/uploads/2010/07/914.jpg&quot; alt=&quot;9&quot; width=&quot;615&quot; height=&quot;200&quot; /&gt;&lt;/a&gt;&lt;/p&gt;&lt;p&gt;Blogs are often too internally focused and ignore key usability issues,  making it hard for new readers to understand the site and trust the  author.&lt;/p&gt;&lt;p&gt;&lt;br /&gt;&lt;/p&gt;&lt;h1&gt;Top-10 Application-Design Mistakes&lt;/h1&gt;&lt;p&gt;&lt;a href=&quot;http://www.useit.com/alertbox/application-mistakes.html&quot;&gt;&lt;img src=&quot;http://netdna.webdesignerdepot.com/uploads/2010/07/105.jpg&quot; alt=&quot;10&quot; width=&quot;615&quot; height=&quot;200&quot; /&gt;&lt;/a&gt;&lt;/p&gt;&lt;p&gt;Application usability is enhanced when users know how to operate the UI  and it guides them through the workflow. Violating common guidelines  prevents both.&lt;/p&gt;&lt;p&gt;&lt;br /&gt;&lt;/p&gt;&lt;h1&gt;Mega Drop-Down Navigation Menus Work Well&lt;/h1&gt;&lt;p&gt;&lt;a href=&quot;http://www.useit.com/alertbox/mega-dropdown-menus.html&quot;&gt;&lt;img src=&quot;http://netdna.webdesignerdepot.com/uploads/2010/07/1110.jpg&quot; alt=&quot;11&quot; width=&quot;615&quot; height=&quot;200&quot; /&gt;&lt;/a&gt;&lt;/p&gt;&lt;p&gt;Big, two-dimensional drop-down panels group navigation options to  eliminate scrolling and use typography, icons, and tooltips to explain  the user’s choices.&lt;/p&gt;&lt;p&gt;&lt;br /&gt;&lt;/p&gt;&lt;h1&gt;10 Usability Crimes You Really Shouldn’t Commit&lt;/h1&gt;&lt;p&gt;&lt;a href=&quot;http://line25.com/articles/10-usability-crimes-you-really-shouldnt-commit&quot;&gt;&lt;img src=&quot;http://netdna.webdesignerdepot.com/uploads/2010/07/1210.jpg&quot; alt=&quot;12&quot; width=&quot;615&quot; height=&quot;200&quot; /&gt;&lt;/a&gt;&lt;/p&gt;&lt;p&gt;A big post by Chris Spooner covering forms, logo links, link states, alt attributes, background images, content, link text and text alignment.&lt;/p&gt;&lt;p&gt;&lt;br /&gt;&lt;/p&gt;&lt;h1&gt;101 Five-Minute Fixes to Incrementally Improve Your Web Site&lt;/h1&gt;&lt;p&gt;&lt;a href=&quot;http://www.insidecrm.com/features/101-web-site-fixes-031808/&quot;&gt;&lt;img src=&quot;http://netdna.webdesignerdepot.com/uploads/2010/07/135.jpg&quot; alt=&quot;13&quot; width=&quot;615&quot; height=&quot;200&quot; /&gt;&lt;/a&gt;&lt;/p&gt;&lt;p&gt;An absolutely huge post covering quick improvements for usability across so many different levels. This is great one for picking out things that your client’s site might &lt;em&gt;need&lt;/em&gt; to have done to it!&lt;/p&gt;&lt;p&gt;&lt;br /&gt;&lt;/p&gt;&lt;h1&gt;Blasting the Myth of the Fold&lt;/h1&gt;&lt;p&gt;&lt;a href=&quot;http://www.boxesandarrows.com/view/blasting-the-myth-of&quot;&gt;&lt;img src=&quot;http://netdna.webdesignerdepot.com/uploads/2010/07/144.jpg&quot; alt=&quot;14&quot; width=&quot;615&quot; height=&quot;200&quot; /&gt;&lt;/a&gt;&lt;/p&gt;&lt;p&gt;Another article slamming the idea that nothing below the fold ever gets seen. Users know how to scroll. The fold is relevant for a few things, but it is not the be-all and end-all.&lt;/p&gt;&lt;p&gt;&lt;br /&gt;&lt;/p&gt;&lt;h1&gt;UX Myths&lt;/h1&gt;&lt;p&gt;&lt;a href=&quot;http://uxmyths.com/&quot;&gt;&lt;img src=&quot;http://netdna.webdesignerdepot.com/uploads/2010/07/154.jpg&quot; alt=&quot;15&quot; width=&quot;615&quot; height=&quot;200&quot; /&gt;&lt;/a&gt;&lt;/p&gt;&lt;p&gt;A great site which is regularly updated with a list of (sometimes funny) myths of user experience issues, these include things such as “all pages should be accessible in 3 clicks” and “the home page is your more important one”.&lt;/p&gt;&lt;p&gt;&lt;br /&gt;&lt;/p&gt;&lt;h1&gt;Eyetracking points the way to effective news article design&lt;/h1&gt;&lt;p&gt;&lt;a href=&quot;http://www.ojr.org/ojr/stories/070312ruel/&quot;&gt;&lt;img src=&quot;http://netdna.webdesignerdepot.com/uploads/2010/07/164.jpg&quot; alt=&quot;16&quot; width=&quot;615&quot; height=&quot;200&quot; /&gt;&lt;/a&gt;&lt;/p&gt;&lt;p&gt;Real eye tracking tests carried out and showing interesting results with regards to the effectiveness of laying out new articles and blog posts.&lt;/p&gt;&lt;p&gt;&lt;br /&gt;&lt;/p&gt;&lt;h1&gt;Label Placement in Forms&lt;/h1&gt;&lt;p&gt;&lt;a href=&quot;http://www.uxmatters.com/mt/archives/2006/07/label-placement-in-forms.php&quot;&gt;&lt;img src=&quot;http://netdna.webdesignerdepot.com/uploads/2010/07/175.jpg&quot; alt=&quot;17&quot; width=&quot;615&quot; height=&quot;200&quot; /&gt;&lt;/a&gt;&lt;/p&gt;&lt;p&gt;A detailed case study showing that the optimum placement for label forms is to the top-right of the form field.&lt;/p&gt;&lt;p&gt;&lt;br /&gt;&lt;/p&gt;&lt;h1&gt;12 Standard Screen Patterns&lt;/h1&gt;&lt;p&gt;&lt;a href=&quot;http://designingwebinterfaces.com/designing-web-interfaces-12-screen-patterns&quot;&gt;&lt;img src=&quot;http://netdna.webdesignerdepot.com/uploads/2010/07/184.jpg&quot; alt=&quot;18&quot; width=&quot;615&quot; height=&quot;200&quot; /&gt;&lt;/a&gt;&lt;/p&gt;&lt;p&gt;A great rouncup of some standard screen layouts which may pursuade clients away from spherical invisible navigation, or similar.&lt;/p&gt;&lt;p&gt;&lt;br /&gt;&lt;/p&gt;&lt;h1&gt;“Mad Libs” Style Form Increases Conversion 25-40%&lt;/h1&gt;&lt;p&gt;&lt;a href=&quot;http://www.lukew.com/ff/entry.asp?1007&quot;&gt;&lt;img src=&quot;http://netdna.webdesignerdepot.com/uploads/2010/07/194.jpg&quot; alt=&quot;19&quot; width=&quot;615&quot; height=&quot;200&quot; /&gt;&lt;/a&gt;&lt;/p&gt;&lt;p&gt;This interesting article covers how well forms work when arranged as blanks within sentences rather than simple linear pages.&lt;/p&gt;&lt;p&gt;&lt;br /&gt;&lt;/p&gt;&lt;h1&gt;Breadcrumbs In Web Design: Examples And Best Practices&lt;/h1&gt;&lt;p&gt;&lt;a href=&quot;http://www.smashingmagazine.com/2009/03/17/breadcrumbs-in-web-design-examples-and-best-practices-2/&quot;&gt;&lt;img src=&quot;http://netdna.webdesignerdepot.com/uploads/2010/07/204.jpg&quot; alt=&quot;20&quot; width=&quot;615&quot; height=&quot;200&quot; /&gt;&lt;/a&gt;&lt;/p&gt;&lt;p&gt;“On websites that have a lot of pages, &lt;strong&gt;breadcrumb navigation&lt;/strong&gt; can greatly  enhance the way users find their way around.  In terms of  usability, breadcrumbs reduce the number of actions a website visitor   needs to take in order to get to a higher-level page, and they improve  the findability of website sections  and pages.”&lt;/p&gt;&lt;p&gt;&lt;br /&gt;&lt;/p&gt;&lt;h1&gt;Inline Validation in Web Forms&lt;/h1&gt;&lt;p&gt;&lt;a href=&quot;http://www.alistapart.com/articles/inline-validation-in-web-forms/&quot;&gt;&lt;img src=&quot;http://netdna.webdesignerdepot.com/uploads/2010/07/2110.jpg&quot; alt=&quot;21&quot; width=&quot;615&quot; height=&quot;200&quot; /&gt;&lt;/a&gt;&lt;/p&gt;&lt;p&gt;A study by A List Apart on inline validation in forms with live user videos showing the differences between standard forms vs inline validation.&lt;/p&gt;&lt;p&gt;&lt;br /&gt;&lt;/p&gt;&lt;p&gt;&lt;em&gt;This post was authored exclusively for WDD by &lt;a href=&quot;http://john.onolan.org/&quot;&gt;John   O’Nolan&lt;/a&gt;,   a core contributor to the WordPress UI Team, writer and entrepreneur   based in   Surrey in the United Kingdom. John loves to talk to people,   so why not follow &lt;a rel=&quot;nofollow&quot; href=&quot;http://twitter.com/johnonolan&quot;&gt;@JohnONolan&lt;/a&gt; on twitter too?&lt;/em&gt;&lt;/p&gt;&lt;p&gt;&lt;em&gt;&lt;strong&gt;What about you? Do you have any really great articles like these  which you think would be a good addition to the list? Drop us a line in  the comments below so that everyone can benefit from them!&lt;/strong&gt;&lt;/em&gt;&lt;/p&gt;&lt;p&gt;&lt;br /&gt;If you find an exclusive RSS freebie on this feed or on the live WDD website, please use the following code to download it: H0Oa9C&lt;/p&gt; &lt;a href=&quot;http://www.webdesignerdepot.com/2010/10/usability-resources-to-win-arguments/&quot;&gt;Source&lt;/a&gt;&lt;p&gt;&lt;/p&gt;&lt;img src=&quot;http://feeds.feedburner.com/~r/webdesignerdepot/~4/8FUcSCAuWB8&quot; height=&quot;1&quot; width=&quot;1&quot; /&gt;&quot;</content><link rel='replies' type='application/atom+xml' href='http://tempocdev.blogspot.com/feeds/8842578743732778364/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://tempocdev.blogspot.com/2010/10/usability-resources-to-win-arguments.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/398584839682458587/posts/default/8842578743732778364'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/398584839682458587/posts/default/8842578743732778364'/><link rel='alternate' type='text/html' href='http://tempocdev.blogspot.com/2010/10/usability-resources-to-win-arguments.html' title='Usability Resources to Win Arguments'/><author><name>Gabriel F. Rodríguez</name><uri>http://www.blogger.com/profile/10332533752137475497</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-398584839682458587.post-8922387414492225428</id><published>2010-10-05T12:58:00.000-07:00</published><updated>2010-10-05T12:58:53.889-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="class"/><category scheme="http://www.blogger.com/atom/ns#" term="HTML"/><category scheme="http://www.blogger.com/atom/ns#" term="regexp"/><category scheme="http://www.blogger.com/atom/ns#" term="regular expression"/><category scheme="http://www.blogger.com/atom/ns#" term="style"/><title type='text'>Finding all class declarations in an HTML document</title><content type='html'>I was charged with the ever so tedious task of removing all class declarations from XHTML documents. In order to find them it took me a while to find the proper general expression. I&#39;m not regexp-litterate. Here&#39;s the explained result:&lt;br /&gt;
&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: &#39;Courier New&#39;, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;background-color: #ffe599;&quot;&gt;&amp;nbsp;(class|styleClass)=\&quot;[^\&quot;]+\&quot;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
It means find a string with the following properties:&lt;br /&gt;
&lt;br /&gt;
&lt;ul&gt;&lt;li&gt;Starts with a space character (granted, this may not catch all cases, but you can tweak it).&lt;/li&gt;
&lt;li&gt;Then look for &quot;class&quot; or &quot;styleClass&quot;, which is a way to declare it in JSF&lt;/li&gt;
&lt;li&gt;Now an &quot;=&quot; and double quotes&lt;/li&gt;
&lt;li&gt;Followed by anything except double quotes (this keeps it from including the subsequent attributes in the find)&lt;/li&gt;
&lt;li&gt;Ends in double quotes&lt;/li&gt;
&lt;/ul&gt;</content><link rel='replies' type='application/atom+xml' href='http://tempocdev.blogspot.com/feeds/8922387414492225428/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://tempocdev.blogspot.com/2010/10/finding-all-class-declarations-in-html.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/398584839682458587/posts/default/8922387414492225428'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/398584839682458587/posts/default/8922387414492225428'/><link rel='alternate' type='text/html' href='http://tempocdev.blogspot.com/2010/10/finding-all-class-declarations-in-html.html' title='Finding all class declarations in an HTML document'/><author><name>Gabriel F. Rodríguez</name><uri>http://www.blogger.com/profile/10332533752137475497</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-398584839682458587.post-6887372879354679420</id><published>2010-07-08T17:11:00.000-07:00</published><updated>2010-07-08T17:12:39.281-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="HTML 5"/><title type='text'>30+ Very Useful HTML5 Tutorials, Techniques and Examples for Web Developers</title><content type='html'>&lt;div&gt;Looked too useful to not have around:&lt;/div&gt;&lt;div&gt;&lt;br /&gt;
&lt;/div&gt;&lt;a href=&quot;http://feedproxy.google.com/~r/tripwiremagazine/~3/5YpY-xtPWX4/30-very-useful-html5-tutorials-techniques-and-examples-for-web-developers.html&quot;&gt;30+ Very Useful HTML5 Tutorials, Techniques and Examples for Web Developers&lt;/a&gt;: &quot;&lt;br /&gt;
&lt;a href=&quot;http://www.tripwiremagazine.com/2010/07/30-very-useful-html5-tutorials-techniques-and-examples-for-web-developers.html&quot;&gt;&lt;img alt=&quot;html5tutorials&quot; border=&quot;0&quot; height=&quot;252&quot; src=&quot;http://www.tripwiremagazine.com/wp-content/uploads/2010/07/html5tutorials1.jpg&quot; style=&quot;border-bottom: 0px; border-left: 0px; border-right: 0px; border-top: 0px; display: inline;&quot; title=&quot;html5tutorials&quot; width=&quot;627&quot; /&gt;&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
HTML5 is being developed as the next major revision of HTML (HyperText Markup Language). The major market and internet leaders are already switching to the HTML 5 platform. With Apple and Google both pushing the standards in order to facilitate more advanced web development, we should see HTML 5 implementations popping up in the next year or two as more companies get on board with the advanced features.&lt;br /&gt;
&lt;br /&gt;
With the constant drop of Flash usage in web and internet applications, HTML5 is opening new doors to web designers and developers. In this scenario, it is indeed imperative for every web developer to know about basic tutorials, tricks and terms of HTML5.&lt;br /&gt;
&lt;br /&gt;
Here we present before you, a comprehensive list of more than 30 HTML5 tutorials and techniques that you can’t afford to miss if you are a web developer.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;h2&gt;&lt;a href=&quot;http://www.ibm.com/developerworks/web/library/wa-offlineweb/index.html&quot;&gt;Create Offline Web Application On Mobile Devices With HTML5&lt;/a&gt;&lt;/h2&gt;&lt;br /&gt;
&lt;a href=&quot;http://www.ibm.com/developerworks/web/library/wa-offlineweb/index.html&quot;&gt;&lt;img alt=&quot;image&quot; border=&quot;0&quot; height=&quot;322&quot; src=&quot;http://www.tripwiremagazine.com/wp-content/uploads/2010/07/image37.png&quot; style=&quot;border-bottom-width: 0px; border-left-width: 0px; border-right-width: 0px; border-top-width: 0px; display: inline;&quot; title=&quot;image&quot; width=&quot;627&quot; /&gt;&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
A comprehensive article from the technical library of IBM by IT Architect Dietmar Krueger. In this article, the author describes and explains how challenging it i s to write application for operating systems and mobile platforms. Instead of relying on learning the platform specific languages like Objective-C with Cocoa (on iPhone), the author takes the open way of developing things through HTML5.  A very clearly explained and in-depth article.&lt;br /&gt;
&lt;br /&gt;
&lt;h2&gt;&lt;abbr&gt;&lt;a href=&quot;http://html5demos.com/&quot;&gt;HTML 5 Demos and Examples&lt;/a&gt;&lt;/abbr&gt;&lt;/h2&gt;&lt;br /&gt;
&lt;a href=&quot;http://html5demos.com/&quot;&gt;&lt;img alt=&quot;image&quot; border=&quot;0&quot; height=&quot;322&quot; src=&quot;http://www.tripwiremagazine.com/wp-content/uploads/2010/07/image54.png&quot; style=&quot;border-bottom-width: 0px; border-left-width: 0px; border-right-width: 0px; border-top-width: 0px; display: inline;&quot; title=&quot;image&quot; width=&quot;624&quot; /&gt;&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;abbr&gt;HTML&lt;/abbr&gt; 5 experimentation and demos I’ve hacked together. Click on the browser support icon or the technology tag to filter the demos (the filter is an &lt;code&gt;OR&lt;/code&gt; filter).&lt;br /&gt;
&lt;br /&gt;
&lt;h2&gt;&lt;a href=&quot;http://www.focus.com/images/view/11905/&quot;&gt;WTF is HTML5&lt;/a&gt;&lt;/h2&gt;&lt;br /&gt;
&lt;a href=&quot;http://www.focus.com/images/view/11905/&quot;&gt;&lt;img alt=&quot;image&quot; border=&quot;0&quot; height=&quot;322&quot; src=&quot;http://www.tripwiremagazine.com/wp-content/uploads/2010/07/image55.png&quot; style=&quot;border-bottom-width: 0px; border-left-width: 0px; border-right-width: 0px; border-top-width: 0px; display: inline;&quot; title=&quot;image&quot; width=&quot;627&quot; /&gt;&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
One page overview of HTML5 – very useful!&lt;br /&gt;
&lt;br /&gt;
&lt;h2&gt;&lt;a href=&quot;http://www.webia.info/articles/tutorials/building-a-live-news-blogging-system-in-php-spiced-with-html5-css3-and-jquery-part-i/&quot;&gt;Building a live news blogging system in PHP, Spiced with HTML5&lt;/a&gt;&lt;/h2&gt;&lt;br /&gt;
&lt;h2&gt;&lt;a href=&quot;http://www.webia.info/articles/tutorials/building-a-live-news-blogging-system-in-php-spiced-with-html5-css3-and-jquery-part-i/&quot;&gt;&lt;img alt=&quot;image&quot; border=&quot;0&quot; height=&quot;322&quot; src=&quot;http://www.tripwiremagazine.com/wp-content/uploads/2010/07/image38.png&quot; style=&quot;border-bottom-width: 0px; border-left-width: 0px; border-right-width: 0px; border-top-width: 0px; display: inline;&quot; title=&quot;image&quot; width=&quot;627&quot; /&gt;&lt;/a&gt;&lt;/h2&gt;&lt;br /&gt;
This tutorial show you how to build a news website in HTML5 and CSS3. Every line of code is explained  for both HTML and CSS&lt;br /&gt;
&lt;br /&gt;
&lt;h2&gt;&lt;a href=&quot;http://html5doctor.com/designing-a-blog-with-html5/&quot;&gt;Designing A Blog With HTML5&lt;/a&gt;&lt;/h2&gt;&lt;br /&gt;
&lt;a href=&quot;http://html5doctor.com/designing-a-blog-with-html5/&quot;&gt;&lt;img alt=&quot;image&quot; border=&quot;0&quot; height=&quot;322&quot; src=&quot;http://www.tripwiremagazine.com/wp-content/uploads/2010/07/image39.png&quot; style=&quot;border-bottom-width: 0px; border-left-width: 0px; border-right-width: 0px; border-top-width: 0px; display: inline;&quot; title=&quot;image&quot; width=&quot;627&quot; /&gt;&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
Much of &lt;abbr&gt;HTML&lt;/abbr&gt; 5’s feature set involves JavaScript &lt;abbr&gt;API&lt;/abbr&gt;s that make it easier to develop interactive web pages but there are a slew of new elements that allow you extra semantics in your conventional Web 1.0 pages. This tutorial investigate these by setting u a blog layout.&lt;br /&gt;
&lt;br /&gt;
&lt;h2&gt;&lt;a href=&quot;http://www.alistapart.com/articles/semanticsinhtml5/&quot;&gt;Semantics in HTML 5&lt;/a&gt;&lt;/h2&gt;&lt;br /&gt;
&lt;a href=&quot;http://www.alistapart.com/articles/semanticsinhtml5/&quot;&gt;&lt;img alt=&quot;image&quot; border=&quot;0&quot; height=&quot;322&quot; src=&quot;http://www.tripwiremagazine.com/wp-content/uploads/2010/07/image40.png&quot; style=&quot;border-bottom-width: 0px; border-left-width: 0px; border-right-width: 0px; border-top-width: 0px; display: inline;&quot; title=&quot;image&quot; width=&quot;626&quot; /&gt;&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;a href=&quot;http://dev.w3.org/html5/spec/Overview.html&quot;&gt;HTML 5&lt;/a&gt;, the W3C’s recently redoubled effort to shape the next generation of HTML, has, over the last year or so, taken on considerable momentum. It is an enormous project, covering not simply the structure of HTML, but also parsing models, error-handling models, the DOM, algorithms for resource fetching, media content, 2D drawing, data templating, security models, page loading models, client-side data storage, and more.&lt;br /&gt;
&lt;br /&gt;
There are also revisions to the structure, syntax, and semantics of HTML, some of which Lachlan Hunt covered in “&lt;a href=&quot;http://www.alistapart.com/articles/previewofhtml5&quot;&gt;A Preview of HTML 5&lt;/a&gt;.”&lt;br /&gt;
&lt;br /&gt;
In this article, let’s turn solely to the semantics of HTML. It’s something the author has been interested in for many years, and something which he believe is fundamentally important to the future of HTML.&lt;br /&gt;
&lt;br /&gt;
&lt;h2&gt;&lt;a href=&quot;http://www.findmebyip.com/litmus/#html5-web-applications&quot;&gt;HTML5 Web Applications&lt;/a&gt;&lt;/h2&gt;&lt;br /&gt;
&lt;img alt=&quot;image&quot; border=&quot;0&quot; height=&quot;322&quot; src=&quot;http://www.tripwiremagazine.com/wp-content/uploads/2010/07/image56.png&quot; style=&quot;border-bottom-width: 0px; border-left-width: 0px; border-right-width: 0px; border-top-width: 0px; display: inline;&quot; title=&quot;image&quot; width=&quot;627&quot; /&gt;&lt;br /&gt;
&lt;br /&gt;
HTML 5 browser compatibility overview.&lt;br /&gt;
&lt;br /&gt;
&lt;h2&gt;&lt;a href=&quot;http://diveintohtml5.org/&quot;&gt;Dive into HTML5&lt;/a&gt;&lt;/h2&gt;&lt;br /&gt;
&lt;a href=&quot;http://diveintohtml5.org/&quot;&gt;&lt;img alt=&quot;image&quot; border=&quot;0&quot; height=&quot;322&quot; src=&quot;http://www.tripwiremagazine.com/wp-content/uploads/2010/07/image41.png&quot; style=&quot;border-bottom-width: 0px; border-left-width: 0px; border-right-width: 0px; border-top-width: 0px; display: inline;&quot; title=&quot;image&quot; width=&quot;627&quot; /&gt;&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
Dive Into &lt;abbr&gt;HTML&lt;/abbr&gt; 5 seeks to elaborate on a hand-picked Selection of features from the &lt;a href=&quot;http://www.whatwg.org/html5&quot;&gt;HTML5&lt;/a&gt; specification and other fine Standards. I shall publish Drafts periodically, as time permits. &lt;a href=&quot;http://diveintohtml5.org/about.html&quot;&gt;Please send feedback&lt;/a&gt;. The final manuscript will be published on paper by O’Reilly, under the Google Press imprint. &lt;a href=&quot;http://www.amazon.com/HTML5-Up-Running-Mark-Pilgrim/dp/0596806027?ie=UTF8&amp;amp;tag=diveintomark-20&amp;amp;creativeASIN=0596806027&quot;&gt;Pre-order the printed Work&lt;/a&gt; and be the first in your Community to receive it.&lt;br /&gt;
&lt;br /&gt;
&lt;h2&gt;&lt;a href=&quot;http://caniuse.com/&quot;&gt;When Can I Use&lt;/a&gt;&lt;/h2&gt;&lt;br /&gt;
&lt;a href=&quot;http://caniuse.com/&quot;&gt;&lt;img alt=&quot;image&quot; border=&quot;0&quot; height=&quot;322&quot; src=&quot;http://www.tripwiremagazine.com/wp-content/uploads/2010/07/image35.png&quot; style=&quot;border-bottom-width: 0px; border-left-width: 0px; border-right-width: 0px; border-top-width: 0px; display: inline;&quot; title=&quot;image&quot; width=&quot;627&quot; /&gt;&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;h4&gt;Here you will find very useful compatibility tables for features in HTML5, CSS3, SVG and other upcoming web technologies.&lt;/h4&gt;&lt;br /&gt;
&lt;h2&gt;&lt;a href=&quot;http://html5readiness.com/&quot;&gt;HTML5 &amp;amp; CSS3 Readiness&lt;/a&gt;&lt;/h2&gt;&lt;br /&gt;
&lt;a href=&quot;http://html5readiness.com/&quot;&gt;&lt;img alt=&quot;image&quot; border=&quot;0&quot; height=&quot;322&quot; src=&quot;http://www.tripwiremagazine.com/wp-content/uploads/2010/07/image57.png&quot; style=&quot;border-bottom-width: 0px; border-left-width: 0px; border-right-width: 0px; border-top-width: 0px; display: inline;&quot; title=&quot;image&quot; width=&quot;627&quot; /&gt;&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;h2&gt;&lt;a href=&quot;http://carsonified.com/blog/dev/html-5-dev/how-to-draw-with-html-5-canvas/&quot;&gt;How to Draw with HTML 5 Canvas&lt;/a&gt;&lt;/h2&gt;&lt;br /&gt;
&lt;h2&gt;&lt;a href=&quot;http://carsonified.com/blog/dev/html-5-dev/how-to-draw-with-html-5-canvas/&quot;&gt;&lt;img alt=&quot;image&quot; border=&quot;0&quot; height=&quot;322&quot; src=&quot;http://www.tripwiremagazine.com/wp-content/uploads/2010/07/image42.png&quot; style=&quot;border-bottom-width: 0px; border-left-width: 0px; border-right-width: 0px; border-top-width: 0px; display: inline;&quot; title=&quot;image&quot; width=&quot;627&quot; /&gt;&lt;/a&gt;&lt;/h2&gt;&lt;br /&gt;
Among the set of goodies in the HTML 5 specification is Canvas which is a way to programmatically draw using JavaScript. We’ll explore the ins and outs of Canvas in this article, demonstrating what is possible with examples and link&lt;br /&gt;
&lt;br /&gt;
&lt;h2&gt;&lt;a href=&quot;http://24ways.org/2009/have-a-field-day-with-html5-forms&quot;&gt;Have a Field Day with HTML5 Forms&lt;/a&gt;&lt;/h2&gt;&lt;br /&gt;
&lt;a href=&quot;http://24ways.org/2009/have-a-field-day-with-html5-forms&quot;&gt;&lt;img alt=&quot;image&quot; border=&quot;0&quot; height=&quot;322&quot; src=&quot;http://www.tripwiremagazine.com/wp-content/uploads/2010/07/image43.png&quot; style=&quot;border-bottom-width: 0px; border-left-width: 0px; border-right-width: 0px; border-top-width: 0px; display: inline;&quot; title=&quot;image&quot; width=&quot;627&quot; /&gt;&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
Forms are usually seen as that obnoxious thing we have to markup and style. I respectfully disagree: forms (on a par with tables) are the most &lt;em&gt;exciting&lt;/em&gt; thing we have to work with.&lt;br /&gt;
&lt;br /&gt;
Here we’re going to take a look at how to style a beautiful HTML5 form using some advanced CSS and latest CSS3 techniques. I promise you will &lt;em&gt;want&lt;/em&gt; to style your own forms after you’ve read this article.&lt;br /&gt;
&lt;br /&gt;
&lt;h2&gt;&lt;a href=&quot;http://line25.com/tutorials/coding-up-a-web-design-concept-into-html-css&quot;&gt;Coding Up a Web Design Concept into HTML5&lt;/a&gt;&lt;/h2&gt;&lt;br /&gt;
&lt;img alt=&quot;image&quot; border=&quot;0&quot; height=&quot;322&quot; src=&quot;http://www.tripwiremagazine.com/wp-content/uploads/2010/07/image44.png&quot; style=&quot;border-bottom-width: 0px; border-left-width: 0px; border-right-width: 0px; border-top-width: 0px; display: inline;&quot; title=&quot;image&quot; width=&quot;627&quot; /&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;h2&gt;&lt;a href=&quot;http://inspectelement.com/tutorials/code-a-backwards-compatible-one-page-portfolio-with-html5-and-css3/&quot;&gt;Code a Backwards Compatible, One Page Portfolio with HTML5 and CSS3&lt;/a&gt;&lt;/h2&gt;&lt;br /&gt;
&lt;a href=&quot;http://inspectelement.com/tutorials/code-a-backwards-compatible-one-page-portfolio-with-html5-and-css3/&quot;&gt;&lt;img alt=&quot;image&quot; border=&quot;0&quot; height=&quot;322&quot; src=&quot;http://www.tripwiremagazine.com/wp-content/uploads/2010/07/image45.png&quot; style=&quot;border-bottom-width: 0px; border-left-width: 0px; border-right-width: 0px; border-top-width: 0px; display: inline;&quot; title=&quot;image&quot; width=&quot;627&quot; /&gt;&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
HTML5 is the future of web development but believe it or not you can start using it today. HTML5 is much more considerate to semantics and accessibility as we don’t have to throw meaningless div’s everywhere. It introduces meaningful tags for common elements such as navigations and footers which makes much more sense and are more natural.&lt;br /&gt;
&lt;br /&gt;
This is a run through of the basics of HTML5 and CSS3 while still paying attention to older browsers. Before we start, make note of the answer to this question.&lt;br /&gt;
&lt;br /&gt;
&lt;h2&gt;&lt;a href=&quot;http://www.smashingmagazine.com/2009/08/04/designing-a-html-5-layout-from-scratch/&quot;&gt;Coding A HTML 5 Layout From Scratch&lt;/a&gt;&lt;/h2&gt;&lt;br /&gt;
&lt;a href=&quot;http://media.smashingmagazine.com/cdn_smash/wp-content/uploads/images/smashing-html5/files/index.html&quot;&gt;&lt;img alt=&quot;image&quot; border=&quot;0&quot; height=&quot;322&quot; src=&quot;http://www.tripwiremagazine.com/wp-content/uploads/2010/07/image46.png&quot; style=&quot;border-bottom-width: 0px; border-left-width: 0px; border-right-width: 0px; border-top-width: 0px; display: inline;&quot; title=&quot;image&quot; width=&quot;627&quot; /&gt;&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
While it is true HTML5 and CSS3 are both a work in progress and is going to stay that way for some time, there’s no reason not to start using it right now. After all, time’s proven that implementation of &lt;a href=&quot;http://www.w3.org/TR/CSS2/&quot;&gt;unfinished specifications&lt;/a&gt; does work and can be easily mistaken by a complete W3C recommendation. That’s were Progressive Enhancement and Graceful Degradation come into play.&lt;br /&gt;
&lt;br /&gt;
&lt;h2&gt;&lt;a href=&quot;http://sixrevisions.com/web-development/html5-iphone-app/&quot;&gt;How to Make an HTML5 iPhone App&lt;/a&gt;&lt;/h2&gt;&lt;br /&gt;
&lt;a href=&quot;http://sixrevisions.com/web-development/html5-iphone-app/&quot;&gt;&lt;img alt=&quot;image&quot; border=&quot;0&quot; height=&quot;322&quot; src=&quot;http://www.tripwiremagazine.com/wp-content/uploads/2010/07/image47.png&quot; style=&quot;border-bottom-width: 0px; border-left-width: 0px; border-right-width: 0px; border-top-width: 0px; display: inline;&quot; title=&quot;image&quot; width=&quot;627&quot; /&gt;&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
You’ve been depressed for like a year now, I know. All the hardcore Objective-C developers have been having a hay-day writing apps for the iPhone. You might have even tried reading a tutorial or two about developing for the iPhone, but its C—or a form of it—and it’s really hard to learn.&lt;br /&gt;
&lt;br /&gt;
You can also do it with the skill set you probably already have: HTML(5), CSS, and JavaScript.&lt;br /&gt;
&lt;br /&gt;
This tutorial show you how to create an &lt;strong&gt;offline HTML5 iPhone application&lt;/strong&gt;. More specifically, I’ll walk you through the process of building a Tetris game.&lt;br /&gt;
&lt;br /&gt;
&lt;h2&gt;&lt;a href=&quot;http://www.pvmgarage.com/2010/04/touch-the-future-create-an-elegant-website-with-hmtl-5-and-css3/&quot;&gt;Create An Elegant Website With HTML 5 And CSS3&lt;/a&gt;&lt;/h2&gt;&lt;br /&gt;
&lt;a href=&quot;http://www.pvmgarage.com/2010/04/touch-the-future-create-an-elegant-website-with-hmtl-5-and-css3/&quot;&gt;&lt;img alt=&quot;image&quot; border=&quot;0&quot; height=&quot;322&quot; src=&quot;http://www.tripwiremagazine.com/wp-content/uploads/2010/07/image48.png&quot; style=&quot;border-bottom-width: 0px; border-left-width: 0px; border-right-width: 0px; border-top-width: 0px; display: inline;&quot; title=&quot;image&quot; width=&quot;627&quot; /&gt;&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
Learn five macro-steps to build an effective website using brain, pencil, paper, Photoshop, HTML and CSS. But technology doesn’t stop, luckily, and we have other two great allies for the future to design better website: HTML 5 and CSS3.&lt;br /&gt;
&lt;br /&gt;
&lt;h2&gt;&lt;a href=&quot;http://tutorialzine.com/2010/02/html5-css3-website-template/&quot;&gt;Coding a CSS3 &amp;amp; HTML5 One-Page Website Template&lt;/a&gt;&lt;/h2&gt;&lt;br /&gt;
&lt;a href=&quot;http://tutorialzine.com/2010/02/html5-css3-website-template/&quot;&gt;&lt;img alt=&quot;image&quot; border=&quot;0&quot; height=&quot;322&quot; src=&quot;http://www.tripwiremagazine.com/wp-content/uploads/2010/07/image49.png&quot; style=&quot;border-bottom-width: 0px; border-left-width: 0px; border-right-width: 0px; border-top-width: 0px; display: inline;&quot; title=&quot;image&quot; width=&quot;627&quot; /&gt;&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
See how to create a HTML5 web template, using some of the new features brought by CSS3 and jQuery, with the scrollTo &lt;a href=&quot;http://demos.flesler.com/jquery/scrollTo/&quot;&gt;plug-in&lt;/a&gt;. As HTML5 is still a work in progress, you can optionally download a XHTML version of the template &lt;a href=&quot;http://tutorialzine.com/2010/02/free-xhtml-css3-website-template/&quot;&gt;here&lt;/a&gt;.&lt;br /&gt;
&lt;br /&gt;
&lt;h2&gt;&lt;a href=&quot;http://line25.com/tutorials/design-and-code-a-cool-iphone-app-website-in-html5&quot;&gt;Design &amp;amp; Code a Cool iPhone App Website in HTML5&lt;/a&gt;&lt;/h2&gt;&lt;br /&gt;
&lt;a href=&quot;http://line25.com/wp-content/uploads/2010/html5/demo/index.html&quot;&gt;&lt;img alt=&quot;image&quot; border=&quot;0&quot; height=&quot;322&quot; src=&quot;http://www.tripwiremagazine.com/wp-content/uploads/2010/07/image50.png&quot; style=&quot;border-bottom-width: 0px; border-left-width: 0px; border-right-width: 0px; border-top-width: 0px; display: inline;&quot; title=&quot;image&quot; width=&quot;627&quot; /&gt;&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
HTML5 is definitely the flavor of the month, with everyone in the design community getting excited about its release. In this tutorial we’ll get a taste of what’s to come by building a cool iPhone app website using a HTML5 structure, and visual styling with some CSS3 effects.&lt;br /&gt;
&lt;br /&gt;
&lt;h2&gt;&lt;a href=&quot;http://net.tutsplus.com/tutorials/html-css-techniques/html-5-and-css-3-the-techniques-youll-soon-be-using/&quot;&gt;HTML 5 and CSS 3: The Techniques You’ll Soon Be Using&lt;/a&gt;&lt;/h2&gt;&lt;br /&gt;
&lt;a href=&quot;http://net.tutsplus.com/tutorials/html-css-techniques/html-5-and-css-3-the-techniques-youll-soon-be-using/&quot;&gt;&lt;img alt=&quot;image&quot; border=&quot;0&quot; height=&quot;322&quot; src=&quot;http://www.tripwiremagazine.com/wp-content/uploads/2010/07/image51.png&quot; style=&quot;border-bottom-width: 0px; border-left-width: 0px; border-right-width: 0px; border-top-width: 0px; display: inline;&quot; title=&quot;image&quot; width=&quot;602&quot; /&gt;&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
In this tutorial, we are going to build a blog page using next-generation techniques from HTML 5 and CSS 3. The tutorial aims to demonstrate how we will be building websites when the specifications are finalized and the browser vendors have implemented them. If you already know HTML and CSS, it should be easy to follow along.&lt;br /&gt;
&lt;br /&gt;
&lt;h2&gt;&lt;a href=&quot;http://www.whatcreative.co.uk/blog/tutorials/html5-for-beginners-use-it-now-its-easy/&quot;&gt;HTML5 for Beginners. Use it now, its easy!&lt;/a&gt;&lt;/h2&gt;&lt;br /&gt;
&lt;img alt=&quot;image&quot; border=&quot;0&quot; height=&quot;322&quot; src=&quot;http://www.tripwiremagazine.com/wp-content/uploads/2010/07/image52.png&quot; style=&quot;border-bottom-width: 0px; border-left-width: 0px; border-right-width: 0px; border-top-width: 0px; display: inline;&quot; title=&quot;image&quot; width=&quot;627&quot; /&gt;&lt;br /&gt;
&lt;br /&gt;
HTML5 for Beginners. Use it now, its easy! This article cover some of the HTML5 basics in a funny way…&lt;br /&gt;
&lt;br /&gt;
&lt;h2&gt;&lt;a href=&quot;http://slides.html5rocks.com/&quot;&gt;Rocking HTML5&lt;/a&gt;&lt;/h2&gt;&lt;br /&gt;
&lt;img alt=&quot;image&quot; border=&quot;0&quot; height=&quot;322&quot; src=&quot;http://www.tripwiremagazine.com/wp-content/uploads/2010/07/image53.png&quot; style=&quot;border-bottom-width: 0px; border-left-width: 0px; border-right-width: 0px; border-top-width: 0px; display: inline;&quot; title=&quot;image&quot; width=&quot;627&quot; /&gt;&lt;br /&gt;
&lt;br /&gt;
This presentation is an HTML5 website and it is a very informative and easy to use overview of the HTML5 elements.&lt;br /&gt;
&lt;br /&gt;
&lt;h2&gt;&lt;a href=&quot;http://www.webmonkey.com/2010/02/building_web_pages_with_html_5/&quot;&gt;Building Web Pages With HTML 5&lt;/a&gt;&lt;/h2&gt;&lt;br /&gt;
&lt;a href=&quot;http://www.webmonkey.com/2010/02/building_web_pages_with_html_5/&quot;&gt;&lt;img alt=&quot;image&quot; border=&quot;0&quot; height=&quot;322&quot; src=&quot;http://www.tripwiremagazine.com/wp-content/uploads/2010/07/image58.png&quot; style=&quot;border-bottom-width: 0px; border-left-width: 0px; border-right-width: 0px; border-top-width: 0px; display: inline;&quot; title=&quot;image&quot; width=&quot;627&quot; /&gt;&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
Depending on who you ask, &lt;a href=&quot;http://www.whatwg.org/&quot;&gt;HTML 5&lt;/a&gt; is either the next important step toward creating a more semantic web or a disaster that’s going to trap the web in yet another set of incomplete tags and markup soup.&lt;br /&gt;
&lt;br /&gt;
The problem with both sides of the argument is that very few sites are using HTML 5 in the wild, so the theoretical solutions to its perceived problems remain largely untested.&lt;br /&gt;
&lt;br /&gt;
That said, it isn’t hard to see both the benefits and potential hang-ups with the next generation of web markup tools.&lt;br /&gt;
&lt;br /&gt;
&lt;h2&gt;&lt;a href=&quot;http://woork.blogspot.com/2009/09/html-5-visual-cheat-sheet-by-woork.html&quot;&gt;HTML5 Cheat Sheet&lt;/a&gt;&lt;/h2&gt;&lt;br /&gt;
&lt;a href=&quot;http://woork.blogspot.com/2009/09/html-5-visual-cheat-sheet-by-woork.html&quot;&gt;&lt;img alt=&quot;image&quot; border=&quot;0&quot; height=&quot;322&quot; src=&quot;http://www.tripwiremagazine.com/wp-content/uploads/2010/07/image59.png&quot; style=&quot;border-bottom-width: 0px; border-left-width: 0px; border-right-width: 0px; border-top-width: 0px; display: inline;&quot; title=&quot;image&quot; width=&quot;627&quot; /&gt;&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
HTML 5 Visual Cheat Sheet is an useful cheat sheet for web designers and developers designed by me. This cheat sheet is essentially a simple visual grid with a list of all HTML tags and of their related attributes supported by HTML versions 4.01 and/or 5. The simple visual style I used to design this sheet allows you to find at a glance everything you are looking for.&lt;br /&gt;
&lt;br /&gt;
&lt;h2&gt;&lt;a href=&quot;http://www.html5test.com/&quot; title=&quot;http://www.html5test.com/&quot;&gt;html5test.com&lt;/a&gt;&lt;/h2&gt;&lt;br /&gt;
&lt;a href=&quot;http://www.html5test.com/&quot;&gt;&lt;img alt=&quot;image&quot; border=&quot;0&quot; height=&quot;322&quot; src=&quot;http://www.tripwiremagazine.com/wp-content/uploads/2010/07/image60.png&quot; style=&quot;border-bottom-width: 0px; border-left-width: 0px; border-right-width: 0px; border-top-width: 0px; display: inline;&quot; title=&quot;image&quot; width=&quot;627&quot; /&gt;&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
This is a browser test with a lot of detail. Very useful.&lt;br /&gt;
&lt;br /&gt;
&lt;h2&gt;&lt;a href=&quot;http://9elements.com/io/?p=153&quot;&gt;HTML5 Canvas Experiment&lt;/a&gt;&lt;/h2&gt;&lt;br /&gt;
&lt;a href=&quot;http://9elements.com/io/projects/html5/canvas/&quot;&gt;&lt;img alt=&quot;image&quot; border=&quot;0&quot; height=&quot;322&quot; src=&quot;http://www.tripwiremagazine.com/wp-content/uploads/2010/07/image61.png&quot; style=&quot;border-bottom-width: 0px; border-left-width: 0px; border-right-width: 0px; border-top-width: 0px; display: inline;&quot; title=&quot;image&quot; width=&quot;627&quot; /&gt;&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
Time for us to play with this technology. We’ve created a little experiment which loads 100 tweets related to HTML5 and displays them using a javascript-based particle engine. Each particle represents a tweet – click on one of them and it’ll appear on the screen. (click on the image to see it in action)&lt;br /&gt;
&lt;br /&gt;
&lt;h2&gt;&lt;a href=&quot;http://www.smashingmagazine.com/2009/07/06/html-5-cheat-sheet-pdf/&quot;&gt;HTML 5 Cheat Sheet (PDF)&lt;/a&gt;&lt;/h2&gt;&lt;br /&gt;
&lt;a href=&quot;http://www.smashingmagazine.com/2009/07/06/html-5-cheat-sheet-pdf/&quot;&gt;&lt;img alt=&quot;image&quot; border=&quot;0&quot; height=&quot;322&quot; src=&quot;http://www.tripwiremagazine.com/wp-content/uploads/2010/07/image62.png&quot; style=&quot;border-bottom-width: 0px; border-left-width: 0px; border-right-width: 0px; border-top-width: 0px; display: inline;&quot; title=&quot;image&quot; width=&quot;627&quot; /&gt;&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;h2&gt;&lt;a href=&quot;http://adactio.com/extras/pocketbooks/html5/&quot; title=&quot;http://adactio.com/extras/pocketbooks/html5/&quot;&gt;html5 Pocketbooks&lt;/a&gt;&lt;/h2&gt;&lt;br /&gt;
&lt;a href=&quot;http://adactio.com/extras/pocketbooks/html5/&quot;&gt;&lt;img alt=&quot;image&quot; border=&quot;0&quot; height=&quot;322&quot; src=&quot;http://www.tripwiremagazine.com/wp-content/uploads/2010/07/image63.png&quot; style=&quot;border-bottom-width: 0px; border-left-width: 0px; border-right-width: 0px; border-top-width: 0px; display: inline;&quot; title=&quot;image&quot; width=&quot;627&quot; /&gt;&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;h2&gt;OK You have seen that HTML 5 is here, but should you use it?&lt;/h2&gt;&lt;br /&gt;
Generally I think it depends on the site you are working on. If it is a high traffic commercial website you may want to hold it back a bit. However if it is a personal blog I believe it is time to get started and learn how to use the new features in HTML 5.&lt;br /&gt;
&lt;br /&gt;
Actually HTML5 is used more than you may think already. You should check out the sites featured on &lt;a href=&quot;http://html5gallery.com/&quot;&gt;HTML 5 Gallery&lt;/a&gt; and view source to see what they’re doing. Also there is already a &lt;a href=&quot;http://diggingintowordpress.com/2009/07/free-html-5-wordpress-theme/&quot;&gt;HTML 5 Wordpress theme&lt;/a&gt; available.&lt;br /&gt;
&lt;br /&gt;
&lt;h2&gt;Other interesting posts on this topic&lt;/h2&gt;&lt;br /&gt;
&lt;ul&gt;&lt;li&gt;&lt;a href=&quot;http://carsonified.com/blog/dev/html-5-dev/23-essential-html-5-resources/&quot;&gt;23 Essential HTML 5 Resources&lt;/a&gt; @ carsonified.com &lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;http://www.webappers.com/2009/08/10/70-must-have-css3-and-html5-tutorials-and-resources/&quot;&gt;70 Must-Have CSS3 and HTML5 Tutorials and Resources&lt;/a&gt; @ webappers.com &lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;http://webdesignledger.com/tutorials/15-useful-html5-tutorials-and-cheat-sheets&quot;&gt;15 Useful HTML5 Tutorials and Cheat Sheets&lt;/a&gt; @ webdesignledger.com &lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;http://visionwidget.com/showcase/graphics/521-examples-of-fresh-html5-websites.html&quot;&gt;22 Examples of Fresh Html 5 Websites &lt;/a&gt;@visionwidget.com&lt;/li&gt;
&lt;/ul&gt;&lt;br /&gt;
Feed provided by &lt;a href=&quot;http://www.tripwiremagazine.com/&quot;&gt;tripwrire magazine&lt;/a&gt;, Visit this post here: &lt;a href=&quot;http://www.tripwiremagazine.com/2010/07/30-very-useful-html5-tutorials-techniques-and-examples-for-web-developers.html&quot;&gt;Permalink&lt;/a&gt;  &lt;img height=&quot;1&quot; src=&quot;http://feeds.feedburner.com/~r/tripwiremagazine/~4/5YpY-xtPWX4&quot; width=&quot;1&quot; /&gt;&quot;</content><link rel='replies' type='application/atom+xml' href='http://tempocdev.blogspot.com/feeds/6887372879354679420/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://tempocdev.blogspot.com/2010/07/30-very-useful-html5-tutorials.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/398584839682458587/posts/default/6887372879354679420'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/398584839682458587/posts/default/6887372879354679420'/><link rel='alternate' type='text/html' href='http://tempocdev.blogspot.com/2010/07/30-very-useful-html5-tutorials.html' title='30+ Very Useful HTML5 Tutorials, Techniques and Examples for Web Developers'/><author><name>Gabriel F. Rodríguez</name><uri>http://www.blogger.com/profile/10332533752137475497</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-398584839682458587.post-7617766042209945198</id><published>2010-06-18T11:08:00.000-07:00</published><updated>2010-06-18T11:08:37.581-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="IE"/><category scheme="http://www.blogger.com/atom/ns#" term="JavaScript"/><title type='text'>Multi-select events on IE</title><content type='html'>Internet Explorer 7 and 8 appear to have no support for clicking an option group in a multi-select. Either that or the JavaScript engine doesn&#39;t handle custom DOM properties correctly.</content><link rel='replies' type='application/atom+xml' href='http://tempocdev.blogspot.com/feeds/7617766042209945198/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://tempocdev.blogspot.com/2010/06/multi-select-events-on-ie.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/398584839682458587/posts/default/7617766042209945198'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/398584839682458587/posts/default/7617766042209945198'/><link rel='alternate' type='text/html' href='http://tempocdev.blogspot.com/2010/06/multi-select-events-on-ie.html' title='Multi-select events on IE'/><author><name>Gabriel F. Rodríguez</name><uri>http://www.blogger.com/profile/10332533752137475497</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-398584839682458587.post-6266879091207016897</id><published>2010-06-09T14:30:00.000-07:00</published><updated>2010-06-09T14:30:06.281-07:00</updated><title type='text'>Launch - Microsoft Visual Studio</title><content type='html'>&lt;div&gt;Apparently they caught up with 2007 Java IDE functionality!&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;a href=&quot;http://www.microsoft.com/visualstudio/en-us/visual-studio-2010-launch&quot;&gt;Launch - Microsoft Visual Studio&lt;/a&gt;</content><link rel='replies' type='application/atom+xml' href='http://tempocdev.blogspot.com/feeds/6266879091207016897/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://tempocdev.blogspot.com/2010/06/launch-microsoft-visual-studio.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/398584839682458587/posts/default/6266879091207016897'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/398584839682458587/posts/default/6266879091207016897'/><link rel='alternate' type='text/html' href='http://tempocdev.blogspot.com/2010/06/launch-microsoft-visual-studio.html' title='Launch - Microsoft Visual Studio'/><author><name>Gabriel F. Rodríguez</name><uri>http://www.blogger.com/profile/10332533752137475497</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-398584839682458587.post-2249293001175991206</id><published>2010-05-24T10:43:00.000-07:00</published><updated>2010-05-24T10:43:19.872-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="IDE"/><category scheme="http://www.blogger.com/atom/ns#" term="Netbeans"/><category scheme="http://www.blogger.com/atom/ns#" term="template"/><title type='text'>Removing Unwanted Lines from Netbeans File Templates</title><content type='html'>Here I am implementing a framework and every single file I create has the following text at the top:&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: &#39;Courier New&#39;, Courier, monospace;&quot;&gt;To change this template, choose Tools | Templates&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: &#39;Courier New&#39;, Courier, monospace;&quot;&gt;and open the template in the editor.&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
It took me a bit of searching and reading but I finally found an effective way to get rid of it without changing all the templates in the IDE.&lt;br /&gt;
&lt;br /&gt;
&lt;ol&gt;&lt;li&gt;Tools&lt;/li&gt;
&lt;li&gt;Templates&lt;/li&gt;
&lt;li&gt;Licenses&lt;/li&gt;
&lt;li&gt;Default License&lt;/li&gt;
&lt;li&gt;Open in Editor&lt;/li&gt;
&lt;li&gt;Get rid of the lines or modify as desired&lt;/li&gt;
&lt;/ol&gt;&lt;div&gt;This template is imported into who knows how many others so changing it affects a whole lot of them.&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://tempocdev.blogspot.com/feeds/2249293001175991206/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://tempocdev.blogspot.com/2010/05/removing-unwanted-lines-from-netbeans.html#comment-form' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/398584839682458587/posts/default/2249293001175991206'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/398584839682458587/posts/default/2249293001175991206'/><link rel='alternate' type='text/html' href='http://tempocdev.blogspot.com/2010/05/removing-unwanted-lines-from-netbeans.html' title='Removing Unwanted Lines from Netbeans File Templates'/><author><name>Gabriel F. Rodríguez</name><uri>http://www.blogger.com/profile/10332533752137475497</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry></feed>