<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Web Dev Bros &#187; general stuff</title>
	<atom:link href="http://www.webdevbros.net/category/uncategorized/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.webdevbros.net</link>
	<description>hot talk about web development</description>
	<lastBuildDate>Thu, 20 Jan 2011 19:55:06 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
		<item>
		<title>Role Based Access Control in ASP.Net MVC</title>
		<link>http://www.webdevbros.net/2009/12/16/role-based-access-control-in-asp-net-mvc/</link>
		<comments>http://www.webdevbros.net/2009/12/16/role-based-access-control-in-asp-net-mvc/#comments</comments>
		<pubDate>Wed, 16 Dec 2009 12:59:24 +0000</pubDate>
		<dc:creator>Dai Bok</dc:creator>
				<category><![CDATA[.net]]></category>
		<category><![CDATA[c#]]></category>
		<category><![CDATA[general stuff]]></category>
		<category><![CDATA[Access Control]]></category>
		<category><![CDATA[ASP.NET MVC]]></category>
		<category><![CDATA[Bitwise Operations]]></category>

		<guid isPermaLink="false">http://www.webdevbros.net/?p=874</guid>
		<description><![CDATA[Currently I am looking at access control systems, and how best to integrate them with ASP.Net MVC framework. While this framework already provides support for role based access control (RBAC), using the membership classes. I need to implement this on a legacy database, and some how integrate the old system with asp.net forms authentication. This [...]]]></description>
			<content:encoded><![CDATA[<p>Currently I am looking at access control systems, and how best to integrate them with ASP.Net MVC framework. While this framework already provides support for role based access control (RBAC), <a href="http://msdn.microsoft.com/en-us/library/system.web.security.membership.aspx">using the membership classes</a>. I need to implement this on a legacy database, and some how integrate the old system with asp.net forms authentication. This post is about how I realised this, and acts a potential solution. If you can think of a better way, of find any devastating flaws, let me know. ;-)</p>
<p>The scenario is simple, we have four roles defined for the system. They are Students, Graduates, Staff and Administrators. Some staff can be graduates, (or even Students). Administrators are, of course staff! So how you model this? We already know of one bitwise <a href="http://www.webdevbros.net/2006/12/02/toggle-states-like-active-deleted-etc-bitwise-negation-in-sql/">trick from Michal’s post</a>, so let us see how we can use bitwise operations to make this a reality!</p>
<p>First let us revise the results of the bitwise AND operations. You can check<a href="http://en.wikipedia.org/wiki/Bitwise_operation"> Wikipedia for full details</a>.</p>
<p align="center">
<table style="border:1px solid black" cellspacing="0">
<tr>
<td>1
<td>&amp;
<td>0
<td>=
<td>0 </tr>
<tr>
<td>0
<td>&amp;
<td>1
<td>=
<td>0 </tr>
<tr>
<td>0
<td>&amp;
<td>0
<td>=
<td>0 </tr>
<tr>
<td>1
<td>&amp;
<td>1
<td>=
<td>1 </tr>
</table>
<p>
</p>
<p>Converting these back to decimal 1001 is 9 and 0101 is 5. So 9 &amp; 5 = 8. If we convert each of these bits to represent a role in our system, we can come up with a table like this. </p>
<p align="center">
<table style="border:1px solid black" cellspacing="0">
<tr>
<td>Bit 1
<td>0 (false)
<td>Student</tr>
<tr>
<td>Bit 2
<td>0 (false)
<td>Graduate</tr>
<tr>
<td>Bit 3
<td>0 (false)
<td>Staff</tr>
<tr>
<td>Bit 4
<td>1 (true)
<td>Admin</tr>
</table>
<p>
</p>
<p>So a user of the system with a role number of 8 is an Admin, but in our case, an Admin is also a member of staff, and in fact, a member of staff could also be a student or a graduate. This is where using bitwise operations can really help model such a situation.  To get it working, a staff member who is a student will have bits 1 and 3 set to true, while a graduate who is also a staff member will have bits 2 and 3 set to true. We can represent these roles in decimal as User(Staff &amp; Graduate) = 6, while User (Staff &amp; Student) = 5. Get the picture?</p>
<p>Let’s look at a simple real world example. First we have a User class, with a Role property of the type int. The reason we use an integer, is that is can be easily stored in the database.</p>
<div style="font-family: Courier New;font-size: 10pt;color: black;background: white">
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;&nbsp;1</span>&nbsp;&nbsp;&nbsp;&nbsp; <span style="color: blue">public</span> <span style="color: blue">class</span> <span style="color: #2b91af">User</span> {</p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;&nbsp;2</span>&nbsp;</p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;&nbsp;3</span>&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; <span style="color: blue">public</span> <span style="color: blue">string</span> Name { <span style="color: blue">get</span>; <span style="color: blue">set</span>; }</p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;&nbsp;4</span>&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; <span style="color: blue">public</span> <span style="color: blue">int</span> Role { <span style="color: blue">get</span>; <span style="color: blue">set</span>; }</p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;&nbsp;5</span>&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; <span style="color: blue">public</span> <span style="color: blue">bool</span> IsInRole(<span style="color: #2b91af">Role</span> role) {</p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;&nbsp;6</span>&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; <span style="color: green">//todo</span></p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;&nbsp;7</span>&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; <span style="color: blue">return</span> <span style="color: blue">false</span>;</p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;&nbsp;8</span>&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; }</p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;&nbsp;9</span>&nbsp;&nbsp;&nbsp;&nbsp; }</p>
<p>
</div>
<p>We also need to create an enumeration, with a Flags attribute. The flags attribute tells the compiler that this enumeration can be treated as a bit field. We then define a value for each role. The reason for using exponents of 2 should become clearer later. </p>
<div style="font-family: Courier New;font-size: 10pt;color: black;background: white">
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;&nbsp;1</span>&nbsp;&nbsp;&nbsp;&nbsp; [<span style="color: #2b91af">Flags</span>]</p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;&nbsp;2</span>&nbsp;&nbsp;&nbsp;&nbsp; <span style="color: blue">public</span> <span style="color: blue">enum</span> <span style="color: #2b91af">Role</span> {</p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;&nbsp;3</span>&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; Student = 1,&nbsp;&nbsp;&nbsp; <span style="color: green">// 0001</span></p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;&nbsp;4</span>&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; Employer = 2,&nbsp;&nbsp; <span style="color: green">// 0010</span></p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;&nbsp;5</span>&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; Staff = 4,&nbsp;&nbsp;&nbsp; &nbsp; <span style="color: green">// 0100</span></p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;&nbsp;6</span>&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; Admin = 8&nbsp;&nbsp;&nbsp; &nbsp;&nbsp; <span style="color: green">// 1000</span></p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;&nbsp;7</span>&nbsp;&nbsp;&nbsp;&nbsp; }</p>
<p>
</div>
<p>The menu of our website needs to be generated depending on the user role.  The menu selection code below should generate the correct menu depending on the user role.</p>
<div style="font-family: Courier New;font-size: 10pt;color: black;background: white">
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;&nbsp;1</span>&nbsp;&nbsp;&nbsp;&nbsp; <span style="color: blue">&lt;</span><span style="color: #a31515">div</span> <span style="color: red">class</span><span style="color: blue">=&quot;LeftMenu&quot;&gt;</span>&nbsp; </p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;&nbsp;2</span>&nbsp;</p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;&nbsp;3</span>&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; <span style="background: #ffee62">&lt;%</span> <span style="color: blue">if</span> (user.IsInRole(<span style="color: #2b91af">Role</span>.Student)) <span style="background: #ffee62">%&gt;</span></p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;&nbsp;4</span>&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; <span style="background: #ffee62">&lt;%</span> Html.RenderPartial(<span style="color: #a31515">&quot;StudentMenu&quot;</span>); <span style="background: #ffee62">%&gt;</span></p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;&nbsp;5</span>&nbsp;</p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;&nbsp;6</span>&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; <span style="background: #ffee62">&lt;%</span> <span style="color: blue">if</span> (user.IsInRole(<span style="color: #2b91af">Role</span>.Graduate)) <span style="background: #ffee62">%&gt;</span></p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;&nbsp;7</span>&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; <span style="background: #ffee62">&lt;%</span> Html.RenderPartial(<span style="color: #a31515">&quot;GraduateMenu&quot;</span>); <span style="background: #ffee62">%&gt;</span></p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;&nbsp;8</span>&nbsp;</p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;&nbsp;9</span>&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; <span style="background: #ffee62">&lt;%</span> <span style="color: blue">if</span> (user.IsInRole(<span style="color: #2b91af">Role</span>.Staff)) <span style="background: #ffee62">%&gt;</span></p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;10</span>&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; <span style="background: #ffee62">&lt;%</span> Html.RenderPartial(<span style="color: #a31515">&quot;StaffMenu&quot;</span>); <span style="background: #ffee62">%&gt;</span></p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;11</span>&nbsp;</p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;12</span>&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; <span style="background: #ffee62">&lt;%</span> <span style="color: blue">if</span> (user.IsInRole(<span style="color: #2b91af">Role</span>.Admin)) <span style="background: #ffee62">%&gt;</span></p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;13</span>&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; <span style="background: #ffee62">&lt;%</span> Html.RenderPartial(<span style="color: #a31515">&quot;AdminMenu&quot;</span>); <span style="background: #ffee62">%&gt;</span></p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;14</span>&nbsp;</p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;15</span>&nbsp;&nbsp;&nbsp;&nbsp; <span style="color: blue">&lt;/</span><span style="color: #a31515">div</span><span style="color: blue">&gt;</span></p>
<p>
</div>
<p>Ok, so let see where the magic happens!  If we <a href="http://msdn.microsoft.com/en-us/library/sbf85k1c.aspx">AND (&amp;)</a> the user assigned role, with the role required, and we compare this result to the role required, we can determine if a user is in the role.  Summarised, the end result of the AND operation needs to equal that of the role required. In user class we have the method:</p>
<div style="font-family: Courier New;font-size: 10pt;color: black;background: white">
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;&nbsp;1</span>&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; <span style="color: blue">public</span> <span style="color: blue">bool</span> IsInRole(<span style="color: #2b91af">Role</span> role) {</p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;&nbsp;2</span>&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; <span style="color: #2b91af">Role</span> userRole = (<span style="color: #2b91af">Role</span>)<span style="color: blue">this</span>.Role;</p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;&nbsp;3</span>&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; <span style="color: blue">return</span> ((userRole &amp; role) == role);</p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;&nbsp;4</span>&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; }</p>
<p>
</div>
<p>Looking at some binary examples, we can see how it works. In the first example, an admin user wants accesses a graduate item. </p>
<p align="center">
<table style="border:1px solid black" cellspacing="0">
<tr>
<td>Role Required
<td style="color:red">Staff(4)
<td>0 1 0 0</tr>
<tr>
<td>User Role
<td style="color:green">Admin (8)
<td>1 0 0 0</tr>
<tr>
<td>Result of &amp;
<td style="color:red"> Access Denied (0)
<td>0 0 0 0</tr>
</table>
<p></br>
</p>
<p>It is clear that we have a problem here, because we said that admin could be both staff, and staff may also be graduates.  What we need to do is add up the roles, so that this user will access both admin and staff content. Assigning the user the role of Admin and Staff is easy. All we do is: </p>
<div style="font-family: Courier New;font-size: 10pt;color: black;background: white">
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;&nbsp;1</span>&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; <span style="color: #2b91af">User</span> user = <span style="color: blue">new</span> <span style="color: #2b91af">User</span>();</p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;&nbsp;2</span>&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; user.Role = (<span style="color: blue">int</span>)<span style="color: #2b91af">Role</span>.Staff;</p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;&nbsp;3</span>&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; user.Role += (<span style="color: blue">int</span>) <span style="color: #2b91af">Role</span>.Admin;</p>
<p>
</div>
<p>And the resulting table is: </p>
<table style="border:1px solid black" cellspacing="0">
<tr>
<td>Role Required
<td style="color:red">Staff(4)
<td>0 1 0 0</tr>
<tr>
<td>User Role
<td style="color:green">Admin  + Staff (12)
<td>1 1 0 0</tr>
<tr>
<td>Result of &amp;
<td style="color:green">Access Granted (4)
<td>0 1 0 0</tr>
</table>
<p>
</p>
<p>Now we can easily draw our menu depending on the roles assigned to a user. Adding or removing roles for a user is also easy, just add it or subtract it. I wrote a little project to go with this so you can test it our your self.  Thanks to Michi for introducing  this, and Dan for helping work it out! </p>
<p>Download the <a href='http://www.webdevbros.net/wp-content/uploads/2009/12/Roles.zip'>Roles sample project </a>  You’ll need to use <a href="http://www.nunit.org/">nUnit to test it</a>. </p>
<div><table> <td><iframe src='http://digg.com/api/diggthis.php?w=new&amp;u=http://www.webdevbros.net/2009/12/16/role-based-access-control-in-asp-net-mvc/&amp;t=Role+Based+Access+Control+in+ASP.Net+MVC&amp;s=normal' height='80' width='52' frameborder='0' scrolling='no'></iframe></td> <td><iframe src='http://www.reddit.com/button_content?newwindow=1&amp;url=http://www.webdevbros.net/2009/12/16/role-based-access-control-in-asp-net-mvc/&amp;title=Role+Based+Access+Control+in+ASP.Net+MVC&amp;t=2 ' height='80' width='52' scrolling='no' frameborder='0' ></iframe></td> <td><iframe src='http://widgets.dzone.com/links/widgets/zoneit.html?url=http://www.webdevbros.net/2009/12/16/role-based-access-control-in-asp-net-mvc/&amp;title=Role+Based+Access+Control+in+ASP.Net+MVC&amp;t=1 ' height='80' width='52' scrolling='no' frameborder='0' ></iframe></td> <td><script type="text/javascript"><!--yahooBuzzArticleHeadline=Role+Based+Access+Control+in+ASP.Net+MVC;//--></script><script type="text/javascript" src="http://d.yimg.com/ds/badge2.js" badgetype=square></script></td> <td><script type="text/javascript">tweetmeme_url='http://www.webdevbros.net/2009/12/16/role-based-access-control-in-asp-net-mvc/'; tweetmeme_style = 'normal';; </script><script type="text/javascript" src="http://tweetmeme.com/i/scripts/button.js" ></script></td></table></div><!-- This is a HTML comment, it will not display in any page. Feel free to remove this comment if it cause any inconvenient to you.
	Thanks for using digg digg, please visit http://www.mkyong.com/blog/digg-digg-wordpress-plugin for any comments and ideas, 
	
    Author : Yong Mook Kim
    Website : http://www.mkyong.com
	-->]]></content:encoded>
			<wfw:commentRss>http://www.webdevbros.net/2009/12/16/role-based-access-control-in-asp-net-mvc/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>FluentNhibernate and Stored Procedures</title>
		<link>http://www.webdevbros.net/2009/11/25/fluentnhibernate-and-stored-procedures/</link>
		<comments>http://www.webdevbros.net/2009/11/25/fluentnhibernate-and-stored-procedures/#comments</comments>
		<pubDate>Wed, 25 Nov 2009 10:59:27 +0000</pubDate>
		<dc:creator>Dai Bok</dc:creator>
				<category><![CDATA[SQL]]></category>
		<category><![CDATA[c#]]></category>
		<category><![CDATA[general stuff]]></category>
		<category><![CDATA[nhibernate]]></category>
		<category><![CDATA[Fluent NHibernate]]></category>

		<guid isPermaLink="false">http://www.webdevbros.net/?p=808</guid>
		<description><![CDATA[I am evaluating FluentNHibernate (FNH), to see if it is suitable for a project I am working on. Disappointingly, FNH does not support Store procedures of the box. Of course, FNH is under the BSD licence, so I am sure those who are confident enough can implement this for the rest of us! This post [...]]]></description>
			<content:encoded><![CDATA[<p>I am evaluating <a href="http://fluentnhibernate.org/">FluentNHibernate </a> (FNH), to see if it is suitable for a project I am working on. Disappointingly, FNH does not support Store procedures of the box. Of course, FNH is under the BSD licence, so I am sure those who are confident enough can implement this for the rest of us! This post will show how I got FNH to work with stored procedures, and can hopefully be followed as a working example.</p>
<p>FNH extends NHibernate, and automagically generates XML mapping files for your objects. Unfortunately, to get stored procedures to work, you need to take a step backwards, and create good old fashioned hbm.xml files, doing the mappings manually.</p>
<p>Firstly , let us look at the results  of the stored procedure that we want to map.</p>
<table border="0" align="center">
<tbody>
<tr>
<td>ID</td>
<td>enDescription</td>
<td>cyDescription</td>
<td>IsActive</td>
</tr>
<tr>
<td>1</td>
<td>Swansea</td>
<td>Abertawe</td>
<td>True</td>
</tr>
<tr>
<td>2</td>
<td>Cardiff</td>
<td>Caerdydd</td>
<td>True</td>
</tr>
<tr>
<td>3</td>
<td>Newport</td>
<td>Cas Newydd</td>
<td>False</td>
</tr>
</tbody>
</table>
<p>The class that will use this data is called lookup.</p>
<p>The code for this class is:</p>
<div style="font-family: Courier New;font-size: 10pt;color: black;background: white">
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;&nbsp;1</span>&nbsp;<span style="color: blue">namespace</span> Entities {</p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;&nbsp;2</span>&nbsp;&nbsp;&nbsp;&nbsp; <span style="color: blue">public</span> <span style="color: blue">class</span> <span style="color: #2b91af">Lookup</span>&nbsp; {</p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;&nbsp;3</span>&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; <span style="color: blue">public</span> <span style="color: blue">virtual</span> <span style="color: blue">int</span> Id { <span style="color: blue">get</span>; <span style="color: blue">set</span>; }</p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;&nbsp;4</span>&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; <span style="color: blue">public</span> <span style="color: blue">virtual</span> <span style="color: blue">string</span> EnDescription { <span style="color: blue">get</span>; <span style="color: blue">set</span>; }</p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;&nbsp;5</span>&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; <span style="color: blue">public</span> <span style="color: blue">virtual</span> <span style="color: blue">string</span> CyDescription { <span style="color: blue">get</span>; <span style="color: blue">set</span>; }</p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;&nbsp;6</span>&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; <span style="color: blue">public</span> <span style="color: blue">virtual</span> <span style="color: blue">bool</span> IsActive { <span style="color: blue">get</span>; <span style="color: blue">set</span>; }</p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;&nbsp;7</span>&nbsp;&nbsp;&nbsp;&nbsp; }</p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;&nbsp;8</span>&nbsp;}</p>
</div>
<p>&nbsp; <br />
This object will be used to populate a simple drop down list, so that a user can select their county.</p>
<p>When I started using FluentHNibernate, I wanted to totally avoid using XML mappings, so I skipped<a href="http://www.amazon.co.uk/gp/product/193239415X?ie=UTF8&amp;tag=daisramblin-21&amp;linkCode=as2&amp;camp=1634&amp;creative=19450&amp;creativeASIN=193239415X"> chapters 3 and 6 of Hibernate in Action.</a><img class=" luqmsfcfqseksqyogrfs luqmsfcfqseksqyogrfs luqmsfcfqseksqyogrfs luqmsfcfqseksqyogrfs luqmsfcfqseksqyogrfs luqmsfcfqseksqyogrfs luqmsfcfqseksqyogrfs luqmsfcfqseksqyogrfs luqmsfcfqseksqyogrfs luqmsfcfqseksqyogrfs luqmsfcfqseksqyogrfs luqmsfcfqseksqyogrfs pcshjncfdcdawbvrvmch pcshjncfdcdawbvrvmch" style="border:none !important;margin:0px !important" src="http://www.assoc-amazon.co.uk/e/ir?t=daisramblin-21&amp;l=as2&amp;o=2&amp;a=193239415X" border="0" alt="" width="1" height="1" /> My first mistake! So for those attempting this, it may be worth your while understanding Hibernate mappings before you proceed. (You may also ask why I have the Java Book and my code is in C#, that is because I am quite used to working in different programming languages, so those who prefer examples in .Net examples check <a href="http://www.amazon.co.uk/gp/product/1932394923?ie=UTF8&amp;tag=daisramblin-21&amp;linkCode=as2&amp;camp=1634&amp;creative=19450&amp;creativeASIN=1932394923">NHibernate in Action</a><img class=" luqmsfcfqseksqyogrfs" style="border:none !important;margin:0px !important" src="http://www.assoc-amazon.co.uk/e/ir?t=daisramblin-21&amp;l=as2&amp;o=2&amp;a=1932394923" border="0" alt="" width="1" height="1" />.)</p>
<p>Let’s move on to creating the mapping file.</p>
<p><em>IMPORTANT:</em> When you add the mapping file to your project, make sure you set the Build Action to Embedded Resource!</p>
<p>I have created a Lookup.hbm.xml file, and the source is below:</p>
<div style="font-family: Courier New;font-size: 10pt;color: black;background: white">
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;&nbsp;1</span>&nbsp;<span style="color: blue">&lt;?</span><span style="color: #a31515">xml</span><span style="color: blue"> </span><span style="color: red">version</span><span style="color: blue">=</span>&quot;<span style="color: blue">1.0</span>&quot;<span style="color: blue"> </span><span style="color: red">encoding</span><span style="color: blue">=</span>&quot;<span style="color: blue">utf-8</span>&quot;<span style="color: blue"> ?&gt;</span></p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;&nbsp;2</span>&nbsp;<span style="color: blue">&lt;</span><span style="color: #a31515">hibernate-mapping</span><span style="color: blue"> </span><span style="color: red">xmlns</span><span style="color: blue">=</span>&quot;<span style="color: blue">urn:nhibernate-mapping-2.2</span>&quot;</p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;&nbsp;3</span>&nbsp;<span style="color: blue">&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp; </span><span style="color: red">namespace</span><span style="color: blue">=</span>&quot;<span style="color: blue">Entities</span>&quot;<span style="color: blue">&gt;</span></p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;&nbsp;4</span>&nbsp;<span style="color: blue">&nbsp;&nbsp;&nbsp; &lt;</span><span style="color: #a31515">class</span><span style="color: blue"> </span><span style="color: red">name</span><span style="color: blue">=</span>&quot;<span style="color: blue">Lookup</span>&quot;<span style="color: blue"> </span><span style="color: red">table</span><span style="color: blue">=</span>&quot;<span style="color: blue">dbo.sp_GetLookups</span>&quot;<span style="color: blue"> &gt;</span></p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;&nbsp;5</span>&nbsp;<span style="color: blue">&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &lt;</span><span style="color: #a31515">id</span><span style="color: blue"> </span><span style="color: red">name</span><span style="color: blue">=</span>&quot;<span style="color: blue">Id</span>&quot;<span style="color: blue"> </span><span style="color: red">column</span><span style="color: blue">=</span>&quot;<span style="color: blue">Id</span>&quot;<span style="color: blue">&gt;</span></p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;&nbsp;6</span>&nbsp;<span style="color: blue">&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &lt;</span><span style="color: #a31515">generator</span><span style="color: blue"> </span><span style="color: red">class</span><span style="color: blue">=</span>&quot;<span style="color: blue">native</span>&quot;<span style="color: blue"> /&gt;</span></p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;&nbsp;7</span>&nbsp;<span style="color: blue">&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &lt;/</span><span style="color: #a31515">id</span><span style="color: blue">&gt;</span></p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;&nbsp;8</span>&nbsp;<span style="color: blue">&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &lt;</span><span style="color: #a31515">property</span><span style="color: blue"> </span><span style="color: red">name</span><span style="color: blue">=</span>&quot;<span style="color: blue">EnDescription</span>&quot;<span style="color: blue"> </span><span style="color: red">column</span><span style="color: blue">=</span>&quot;<span style="color: blue">enDescription</span>&quot;<span style="color: blue"> /&gt;</span></p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;&nbsp;9</span>&nbsp;<span style="color: blue">&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &lt;</span><span style="color: #a31515">property</span><span style="color: blue"> </span><span style="color: red">name</span><span style="color: blue">=</span>&quot;<span style="color: blue">CyDescription</span>&quot;<span style="color: blue"> </span><span style="color: red">column</span><span style="color: blue">=</span>&quot;<span style="color: blue">cyDescription</span>&quot;<span style="color: blue"> /&gt;</span></p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;10</span>&nbsp;<span style="color: blue">&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &lt;</span><span style="color: #a31515">property</span><span style="color: blue"> </span><span style="color: red">name</span><span style="color: blue">=</span>&quot;<span style="color: blue">IsActive</span>&quot;<span style="color: blue"> </span><span style="color: red">column</span><span style="color: blue">=</span>&quot;<span style="color: blue">IsActive</span>&quot;<span style="color: blue"> /&gt;</span></p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;11</span>&nbsp;<span style="color: blue">&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &lt;</span><span style="color: #a31515">loader</span><span style="color: blue"> </span><span style="color: red">query-ref</span><span style="color: blue">=</span>&quot;<span style="color: blue">dbo.sp_GetLookups</span>&quot;<span style="color: blue">/&gt;</span></p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;12</span>&nbsp;<span style="color: blue">&nbsp;&nbsp;&nbsp; &lt;/</span><span style="color: #a31515">class</span><span style="color: blue">&gt;</span></p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;13</span>&nbsp;</p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;14</span>&nbsp;<span style="color: blue">&nbsp;&nbsp;&nbsp; &lt;</span><span style="color: #a31515">sql-query</span><span style="color: blue"> </span><span style="color: red">name</span><span style="color: blue">=</span>&quot;<span style="color: blue">dbo.sp_GetLookups</span>&quot;<span style="color: blue"> &gt;</span></p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;15</span>&nbsp;<span style="color: blue">&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &lt;</span><span style="color: #a31515">return</span><span style="color: blue"> </span><span style="color: red">alias</span><span style="color: blue">=</span>&quot;<span style="color: blue">dbo.sp_GetLookups</span>&quot;<span style="color: blue"> </span><span style="color: red">class</span><span style="color: blue">=</span>&quot;<span style="color: blue">Lookup</span>&quot;<span style="color: blue">&gt;</span></p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;16</span>&nbsp;<span style="color: blue">&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &lt;</span><span style="color: #a31515">return-property</span><span style="color: blue"> </span><span style="color: red">name</span><span style="color: blue">=</span>&quot;<span style="color: blue">Id</span>&quot;<span style="color: blue"> </span><span style="color: red">column</span><span style="color: blue">=</span>&quot;<span style="color: blue">Id</span>&quot;<span style="color: blue">/&gt;</span></p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;17</span>&nbsp;<span style="color: blue">&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &lt;</span><span style="color: #a31515">return-property</span><span style="color: blue"> </span><span style="color: red">name</span><span style="color: blue">=</span>&quot;<span style="color: blue">EnDescription</span>&quot;<span style="color: blue"> </span><span style="color: red">column</span><span style="color: blue">=</span>&quot;<span style="color: blue">enDescription</span>&quot;<span style="color: blue">/&gt;</span></p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;18</span>&nbsp;<span style="color: blue">&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &lt;</span><span style="color: #a31515">return-property</span><span style="color: blue"> </span><span style="color: red">name</span><span style="color: blue">=</span>&quot;<span style="color: blue">CyDescription</span>&quot;<span style="color: blue"> </span><span style="color: red">column</span><span style="color: blue">=</span>&quot;<span style="color: blue">cyDescription</span>&quot;<span style="color: blue">/&gt;</span></p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;19</span>&nbsp;<span style="color: blue">&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &lt;</span><span style="color: #a31515">return-property</span><span style="color: blue"> </span><span style="color: red">name</span><span style="color: blue">=</span>&quot;<span style="color: blue">IsActive</span>&quot;<span style="color: blue"> </span><span style="color: red">column</span><span style="color: blue">=</span>&quot;<span style="color: blue">IsActive</span>&quot;<span style="color: blue">/&gt;</span></p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;20</span>&nbsp;<span style="color: blue">&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &lt;/</span><span style="color: #a31515">return</span><span style="color: blue">&gt;</span></p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;21</span>&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; exec dbo.sp_GetLookups</p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;22</span>&nbsp;<span style="color: blue">&nbsp;&nbsp;&nbsp; &lt;/</span><span style="color: #a31515">sql-query</span><span style="color: blue">&gt;</span></p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;23</span>&nbsp;<span style="color: blue">&lt;/</span><span style="color: #a31515">hibernate-mapping</span><span style="color: blue">&gt; </span></p>
</div>
<p>&nbsp; </p>
<p>To put it quite simply, lines 5 to 13 map my Lookup class to the columns in the stored procedure, while lines 16 to 20 map the results from the stored procedure my lookup class. Line 22 names the stored procedure. I am not sure if this is the best way to achieve the mappings, so any feedback would be appreciated.</p>
<p>Once your object is nicely  mapped, you then need to update your fluent configuration. All you need to do is tell FNH to load hbmMappings from the current assembly. See the snippet below:</p>
<div style="font-family: Courier New;font-size: 10pt;color: black;background: white">
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;1</span>&nbsp;&nbsp;&nbsp; .Mappings(m =&gt; {</p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;2</span>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; m.HbmMappings.AddFromAssembly(<span style="color: #2b91af">Assembly</span>.GetExecutingAssembly());</p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;3</span>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;  m.FluentMappings.AddFromAssembly(<span style="color: #2b91af">Assembly</span>.GetExecutingAssembly());</p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;4</span>&nbsp;&nbsp;&nbsp;&nbsp; })</p>
</div>
<p> &nbsp; </p>
<p>To retrieve the list of lookups, I do the following, which populates my results variable with a list of all my lookups.</p>
<div style="font-family: Courier New;font-size: 10pt;color: black;background: white">
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;&nbsp;1</span>&nbsp;&nbsp;&nbsp; <span style="color: blue">var</span> sessionfactory = CreateSessionFactory();</p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;&nbsp;2</span>&nbsp;&nbsp;&nbsp; <span style="color: blue">var</span> session = sessionfactory.OpenSession();</p>
<p style="margin: 0px"><span style="color: #2b91af">&nbsp;&nbsp;&nbsp;&nbsp;3</span>&nbsp;&nbsp;&nbsp; <span style="color: blue">var</span> results = session.GetNamedQuery(<span style="color: #a31515">&quot;dbo.sp_GetLookups&quot;</span>).List();</p>
</div>
<p> &nbsp; </p>
<p>And that is it, the results variable now contains the list of lookups that I can use to populate my list control.</p>
<div><table> <td><iframe src='http://digg.com/api/diggthis.php?w=new&amp;u=http://www.webdevbros.net/2009/11/25/fluentnhibernate-and-stored-procedures/&amp;t=FluentNhibernate+and+Stored+Procedures&amp;s=normal' height='80' width='52' frameborder='0' scrolling='no'></iframe></td> <td><iframe src='http://www.reddit.com/button_content?newwindow=1&amp;url=http://www.webdevbros.net/2009/11/25/fluentnhibernate-and-stored-procedures/&amp;title=FluentNhibernate+and+Stored+Procedures&amp;t=2 ' height='80' width='52' scrolling='no' frameborder='0' ></iframe></td> <td><iframe src='http://widgets.dzone.com/links/widgets/zoneit.html?url=http://www.webdevbros.net/2009/11/25/fluentnhibernate-and-stored-procedures/&amp;title=FluentNhibernate+and+Stored+Procedures&amp;t=1 ' height='80' width='52' scrolling='no' frameborder='0' ></iframe></td> <td><script type="text/javascript"><!--yahooBuzzArticleHeadline=FluentNhibernate+and+Stored+Procedures;//--></script><script type="text/javascript" src="http://d.yimg.com/ds/badge2.js" badgetype=square></script></td> <td><script type="text/javascript">tweetmeme_url='http://www.webdevbros.net/2009/11/25/fluentnhibernate-and-stored-procedures/'; tweetmeme_style = 'normal';; </script><script type="text/javascript" src="http://tweetmeme.com/i/scripts/button.js" ></script></td></table></div><!-- This is a HTML comment, it will not display in any page. Feel free to remove this comment if it cause any inconvenient to you.
	Thanks for using digg digg, please visit http://www.mkyong.com/blog/digg-digg-wordpress-plugin for any comments and ideas, 
	
    Author : Yong Mook Kim
    Website : http://www.mkyong.com
	-->]]></content:encoded>
			<wfw:commentRss>http://www.webdevbros.net/2009/11/25/fluentnhibernate-and-stored-procedures/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Looking for the perfect job? Looking for the best developers?</title>
		<link>http://www.webdevbros.net/2009/10/29/looking-for-the-perfect-job-looking-for-the-best-developers/</link>
		<comments>http://www.webdevbros.net/2009/10/29/looking-for-the-perfect-job-looking-for-the-best-developers/#comments</comments>
		<pubDate>Thu, 29 Oct 2009 06:54:01 +0000</pubDate>
		<dc:creator>Michal</dc:creator>
				<category><![CDATA[general stuff]]></category>

		<guid isPermaLink="false">http://www.webdevbros.net/?p=804</guid>
		<description><![CDATA[As an active user of Stackoverflow I came across their new career service. It&#8217;s brand new and their vision is to find the perfect employer for each developer. Pretty good idea I think. STO has a lot of bright brains, which can be a huge profit for corporations looking for great staff. Amongst other job [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://careers.stackoverflow.com/"><img src="http://www.webdevbros.net/wp-content/uploads/2009/10/careersstackoverflow.png" alt="careersstackoverflow" title="careersstackoverflow" width="363" height="64" class="aligncenter size-full wp-image-805" /></a><br />
As an active user of <a href="http://www.stackoverflow.com">Stackoverflow</a> I came across their new career service. It&#8217;s brand new and their vision is to find the perfect employer for each developer. Pretty good idea I think. STO has a lot of bright brains, which can be a huge profit for corporations looking for great staff.</p>
<p>Amongst other job platforms, it stands out by providing developer specific details such as First computer, Favorite technologies, Likes, Dislikes, etc. Currently they&#8217;re offering a 3 year membership for only USD29.00. Once inside, you sit back, drink tea and wait.</p>
<p>Since their launch Stackoverflow provided me a lot of answers to my questions, which no other site achieved so far. That&#8217;s why it&#8217;s time to give back to them. I decided to subscribe for the 3yr membership.</p>
<p>Want to hire me?<br />
<a href="http://careers.stackoverflow.com/michal">http://careers.stackoverflow.com/michal</a></p>
<div><table> <td><iframe src='http://digg.com/api/diggthis.php?w=new&amp;u=http://www.webdevbros.net/2009/10/29/looking-for-the-perfect-job-looking-for-the-best-developers/&amp;t=Looking+for+the+perfect+job%3F+Looking+for+the+best+developers%3F&amp;s=normal' height='80' width='52' frameborder='0' scrolling='no'></iframe></td> <td><iframe src='http://www.reddit.com/button_content?newwindow=1&amp;url=http://www.webdevbros.net/2009/10/29/looking-for-the-perfect-job-looking-for-the-best-developers/&amp;title=Looking+for+the+perfect+job%3F+Looking+for+the+best+developers%3F&amp;t=2 ' height='80' width='52' scrolling='no' frameborder='0' ></iframe></td> <td><iframe src='http://widgets.dzone.com/links/widgets/zoneit.html?url=http://www.webdevbros.net/2009/10/29/looking-for-the-perfect-job-looking-for-the-best-developers/&amp;title=Looking+for+the+perfect+job%3F+Looking+for+the+best+developers%3F&amp;t=1 ' height='80' width='52' scrolling='no' frameborder='0' ></iframe></td> <td><script type="text/javascript"><!--yahooBuzzArticleHeadline=Looking+for+the+perfect+job%3F+Looking+for+the+best+developers%3F;//--></script><script type="text/javascript" src="http://d.yimg.com/ds/badge2.js" badgetype=square></script></td> <td><script type="text/javascript">tweetmeme_url='http://www.webdevbros.net/2009/10/29/looking-for-the-perfect-job-looking-for-the-best-developers/'; tweetmeme_style = 'normal';; </script><script type="text/javascript" src="http://tweetmeme.com/i/scripts/button.js" ></script></td></table></div><!-- This is a HTML comment, it will not display in any page. Feel free to remove this comment if it cause any inconvenient to you.
	Thanks for using digg digg, please visit http://www.mkyong.com/blog/digg-digg-wordpress-plugin for any comments and ideas, 
	
    Author : Yong Mook Kim
    Website : http://www.mkyong.com
	-->]]></content:encoded>
			<wfw:commentRss>http://www.webdevbros.net/2009/10/29/looking-for-the-perfect-job-looking-for-the-best-developers/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Testing code changes, bugfixes, new features, …</title>
		<link>http://www.webdevbros.net/2009/08/20/testing-a-change-bugfix-implemented-feature-%e2%80%a6/</link>
		<comments>http://www.webdevbros.net/2009/08/20/testing-a-change-bugfix-implemented-feature-%e2%80%a6/#comments</comments>
		<pubDate>Wed, 19 Aug 2009 23:00:52 +0000</pubDate>
		<dc:creator>Michal</dc:creator>
				<category><![CDATA[Testing]]></category>
		<category><![CDATA[general stuff]]></category>
		<category><![CDATA[programming style]]></category>

		<guid isPermaLink="false">http://fabiankoehler.de/wdb/?p=14</guid>
		<description><![CDATA[When you implement a new feature somewhere, when you change just some bits of your code, when you fix a bug, or you just change a common text in an app&#8230; What do you do afterwards? Do you really check the result or do you trust yourself that it works fine 100%. It is an [...]]]></description>
			<content:encoded><![CDATA[<p>When you implement a new feature somewhere, when you change just some bits of your code, when you fix a bug, or you just change a common text in an app&#8230; What do you do afterwards? Do you really check the result or do you trust yourself that it works fine 100%. It is an interesting thing to talk about…<span id="more-14"></span></p>
<p>I have to be honest and admit that I trusted myself a lot of times in the early days and at least 2 of 10 times I was wrong. If you deal with customers then it&#8217;s two times too much. Especially when you have that guy on the phone and you claim that you did change it, but he is browsing the application and does not see any changes. In that case you&#8217;re really pissed because you haven&#8217;t spent one minute to check the result/consequence of your change.</p>
<p>So that&#8217;s why I always suggest to check EVERYTHING that has been changed. You never know what you forget, but when you get sure that you see the change yourself then you&#8217;re on the safe side. Here is a list what you could not have thought about:</p>
<ul>
<li>you have been working in the wrong file. The file you have been working on was just a backup, in the wrong location, wrong server, etc. Such things happen everyday. </li>
<li>you forgot to refresh/restart some service, application, etc. </li>
<li>forgot to publish the file. This is common but i am sure it happens as well. For instance you forgot to upload the file on the server if its a web app. </li>
<li>forgot to compile. for all out there who need to do this. </li>
<li>last but not least programing failures which you haven&#8217;t thought about (especially when you are changing code of others you should 100% check the effect of the change even if it&#8217;s just a typo): you changed the wrong part of the code. Happens usually when there are duplicate pieces of code, which in turn happens because of bad programming style (think of the DRY principle).
</li>
</ul>
<p>Hence it&#8217;s highly recommended to check EVERY change. You save yourself and others a lot of troubles and iterations of changing and testing. Personally I think that this is a programmers quality characteristic and that it&#8217;s not a tall order to expect a check of the change. In most cases it&#8217;s less than a minute. Don&#8217;t get lazy …. For sure everybody does, but be aware of all the points I mentioned above. </p>
<div><table> <td><iframe src='http://digg.com/api/diggthis.php?w=new&amp;u=http://www.webdevbros.net/2009/08/20/testing-a-change-bugfix-implemented-feature-%e2%80%a6/&amp;t=Testing+code+changes%2C+bugfixes%2C+new+features%2C+%E2%80%A6&amp;s=normal' height='80' width='52' frameborder='0' scrolling='no'></iframe></td> <td><iframe src='http://www.reddit.com/button_content?newwindow=1&amp;url=http://www.webdevbros.net/2009/08/20/testing-a-change-bugfix-implemented-feature-%e2%80%a6/&amp;title=Testing+code+changes%2C+bugfixes%2C+new+features%2C+%E2%80%A6&amp;t=2 ' height='80' width='52' scrolling='no' frameborder='0' ></iframe></td> <td><iframe src='http://widgets.dzone.com/links/widgets/zoneit.html?url=http://www.webdevbros.net/2009/08/20/testing-a-change-bugfix-implemented-feature-%e2%80%a6/&amp;title=Testing+code+changes%2C+bugfixes%2C+new+features%2C+%E2%80%A6&amp;t=1 ' height='80' width='52' scrolling='no' frameborder='0' ></iframe></td> <td><script type="text/javascript"><!--yahooBuzzArticleHeadline=Testing+code+changes%2C+bugfixes%2C+new+features%2C+%E2%80%A6;//--></script><script type="text/javascript" src="http://d.yimg.com/ds/badge2.js" badgetype=square></script></td> <td><script type="text/javascript">tweetmeme_url='http://www.webdevbros.net/2009/08/20/testing-a-change-bugfix-implemented-feature-%e2%80%a6/'; tweetmeme_style = 'normal';; </script><script type="text/javascript" src="http://tweetmeme.com/i/scripts/button.js" ></script></td></table></div><!-- This is a HTML comment, it will not display in any page. Feel free to remove this comment if it cause any inconvenient to you.
	Thanks for using digg digg, please visit http://www.mkyong.com/blog/digg-digg-wordpress-plugin for any comments and ideas, 
	
    Author : Yong Mook Kim
    Website : http://www.mkyong.com
	-->]]></content:encoded>
			<wfw:commentRss>http://www.webdevbros.net/2009/08/20/testing-a-change-bugfix-implemented-feature-%e2%80%a6/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Flex Style Introspection</title>
		<link>http://www.webdevbros.net/2009/08/16/flex-style-introspection/</link>
		<comments>http://www.webdevbros.net/2009/08/16/flex-style-introspection/#comments</comments>
		<pubDate>Sun, 16 Aug 2009 15:31:48 +0000</pubDate>
		<dc:creator>julien</dc:creator>
				<category><![CDATA[general stuff]]></category>

		<guid isPermaLink="false">http://www.webdevbros.net/?p=527</guid>
		<description><![CDATA[If you have ever used the Flex introspection method describeType(), you certainly have noticed it doesn't output any style metadata. The only way I found so far was to instantiate the UIComponent type I'm looking at and call the function regenerateStyleCache(false). The entire list of available styles is then accessible via the properties inheritingStyles and [...]]]></description>
			<content:encoded><![CDATA[<p>If you have ever used the Flex introspection method <code>describeType()</code>, you certainly have noticed it doesn't output any style metadata. The only way I found so far was to instantiate the <code>UIComponent</code> type I'm looking at and call the function <code>regenerateStyleCache(false)</code>. The entire list of available styles is then accessible via the properties <code>inheritingStyles</code> and <code>nonInheritingStyles</code>. Generating the style cache is computation-intensive so like most reflection and introspection operations make effective use of it :)</p>
<p>Some code example after the jump... <span id="more-527"></span></p>
<div class="igBar"><span id="lactionscript-2"><a href="#" onclick="javascript:showCodeTxt('actionscript-2'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">Actionscript:</span>
<div id="actionscript-2">
<div class="actionscript">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#767676;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color: #000000; font-weight: bold;">var</span> componentClass:<span style="color: #000000; font-weight: bold;">Class</span> = getDefinitionByName<span style="color: #66cc66;">&#40;</span><span style="color: #ff0000;">"mx.controls.CheckBox"</span><span style="color: #66cc66;">&#41;</span> as <span style="color: #000000; font-weight: bold;">Class</span>;</div>
</li>
<li style="font-weight: bold;color:#767676;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color: #000000; font-weight: bold;">var</span> component:UIComponent = <span style="color: #000000; font-weight: bold;">new</span> componentClass<span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">&#41;</span>;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#767676;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">component.<span style="color: #006600;">regenerateStyleCache</span><span style="color: #66cc66;">&#40;</span><span style="color: #000000; font-weight: bold;">false</span><span style="color: #66cc66;">&#41;</span>;</div>
</li>
<li style="font-weight: bold;color:#767676;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color: #0066CC;">trace</span><span style="color: #66cc66;">&#40;</span>ObjectUtil.<span style="color: #0066CC;">toString</span><span style="color: #66cc66;">&#40;</span>component.<span style="color: #006600;">nonInheritingStyles</span><span style="color: #66cc66;">&#41;</span><span style="color: #66cc66;">&#41;</span>;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#767676;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color: #0066CC;">trace</span><span style="color: #66cc66;">&#40;</span>ObjectUtil.<span style="color: #0066CC;">toString</span><span style="color: #66cc66;">&#40;</span>component.<span style="color: #006600;">inheritingStyles</span><span style="color: #66cc66;">&#41;</span><span style="color: #66cc66;">&#41;</span>; </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>will output...</p>
<p><code><br />
(Object)#0<br />
  backgroundAlpha = 1<br />
  backgroundSize = "auto"<br />
  bevel = true<br />
  borderAlpha = 1<br />
  borderCapColor = 9542041<br />
  borderColor = 12040892<br />
  borderSides = "left top right bottom"<br />
  borderSkin = (mx.skins.halo::HaloBorder)<br />
  borderStyle = "inset"<br />
  borderThickness = 1<br />
  buttonColor = 7305079<br />
  closeDuration = 250<br />
  color = 734012<br />
  cornerRadius = 4<br />
  disabledColor = 11187123<br />
  disabledIcon = (null)<br />
  disabledIconColor = 10066329<br />
  disabledSkin = (null)<br />
  downIcon = (null)<br />
  downSkin = (null)<br />
  dropShadowColor = 0<br />
  dropShadowEnabled = false<br />
  embedFonts = false<br />
  errorColor = 16711680<br />
  fillAlphas = (Array)#1<br />
    [0] 0.6<br />
    [1] 0.4<br />
    [2] 0.75<br />
    [3] 0.65<br />
  fillColor = 16777215<br />
  fillColors = (Array)#2<br />
    [0] 16777215<br />
    [1] 13421772<br />
    [2] 16777215<br />
    [3] 15658734<br />
  filled = true<br />
  focusAlpha = 0.4<br />
  focusBlendMode = "normal"<br />
  focusRoundedCorners = "tl tr bl br"<br />
  focusSkin = (mx.skins.halo::HaloFocusRect)<br />
  focusThickness = 2<br />
  fontAntiAliasType = "advanced"<br />
  fontFamily = "Verdana"<br />
  fontGridFitType = "pixel"<br />
  fontSharpness = 0<br />
  fontSize = 10<br />
  fontStyle = "normal"<br />
  fontThickness = 0<br />
  fontWeight = "normal"<br />
  highlightAlphas = (Array)#3<br />
    [0] 0.3<br />
    [1] 0<br />
  horizontalAlign = "left"<br />
  horizontalGap = 5<br />
  horizontalGridLineColor = 16250871<br />
  horizontalGridLines = false<br />
  icon = (mx.skins.halo::CheckBoxIcon)<br />
  iconColor = 2831164<br />
  indentation = 17<br />
  indicatorGap = 14<br />
  kerning = false<br />
  leading = 2<br />
  letterSpacing = 0<br />
  modalTransparency = 0.5<br />
  modalTransparencyBlur = 3<br />
  modalTransparencyColor = 14540253<br />
  modalTransparencyDuration = 100<br />
  openDuration = 250<br />
  overIcon = (null)<br />
  overSkin = (null)<br />
  paddingBottom = 2<br />
  paddingLeft = 0<br />
  paddingRight = 0<br />
  paddingTop = 2<br />
  repeatDelay = 500<br />
  repeatInterval = 35<br />
  roundedBottomCorners = true<br />
  selectedDisabledIcon = (null)<br />
  selectedDisabledSkin = (null)<br />
  selectedDownIcon = (null)<br />
  selectedDownSkin = (null)<br />
  selectedOverIcon = (null)<br />
  selectedOverSkin = (null)<br />
  selectedUpIcon = (null)<br />
  selectedUpSkin = (null)<br />
  selectionDisabledColor = 14540253<br />
  selectionDuration = 250<br />
  shadowCapColor = 14015965<br />
  shadowColor = 15658734<br />
  shadowDirection = "center"<br />
  shadowDistance = 2<br />
  skin = (null)<br />
  stroked = false<br />
  strokeWidth = 1<br />
  textAlign = "left"<br />
  textDecoration = "none"<br />
  textIndent = 0<br />
  textRollOverColor = 2831164<br />
  textSelectedColor = 2831164<br />
  themeColor = 40447<br />
  upIcon = (null)<br />
  upSkin = (null)<br />
  useRollOver = true<br />
  version = "3.0.0"<br />
  verticalAlign = "top"<br />
  verticalGap = 2<br />
  verticalGridLineColor = 14015965<br />
  verticalGridLines = true<br />
(Object)#0<br />
  backgroundAlpha = 1<br />
  backgroundSize = "auto"<br />
  bevel = true<br />
  borderAlpha = 1<br />
  borderCapColor = 9542041<br />
  borderColor = 12040892<br />
  borderSides = "left top right bottom"<br />
  borderSkin = (mx.skins.halo::HaloBorder)<br />
  borderStyle = "inset"<br />
  borderThickness = 1<br />
  buttonColor = 7305079<br />
  closeDuration = 250<br />
  color = 734012<br />
  cornerRadius = 4<br />
  disabledColor = 11187123<br />
  disabledIcon = (null)<br />
  disabledIconColor = 10066329<br />
  disabledSkin = (null)<br />
  downIcon = (null)<br />
  downSkin = (null)<br />
  dropShadowColor = 0<br />
  dropShadowEnabled = false<br />
  embedFonts = false<br />
  errorColor = 16711680<br />
  fillAlphas = (Array)#1<br />
    [0] 0.6<br />
    [1] 0.4<br />
    [2] 0.75<br />
    [3] 0.65<br />
  fillColor = 16777215<br />
  fillColors = (Array)#2<br />
    [0] 16777215<br />
    [1] 13421772<br />
    [2] 16777215<br />
    [3] 15658734<br />
  filled = true<br />
  focusAlpha = 0.4<br />
  focusBlendMode = "normal"<br />
  focusRoundedCorners = "tl tr bl br"<br />
  focusSkin = (mx.skins.halo::HaloFocusRect)<br />
  focusThickness = 2<br />
  fontAntiAliasType = "advanced"<br />
  fontFamily = "Verdana"<br />
  fontGridFitType = "pixel"<br />
  fontSharpness = 0<br />
  fontSize = 10<br />
  fontStyle = "normal"<br />
  fontThickness = 0<br />
  fontWeight = "normal"<br />
  highlightAlphas = (Array)#3<br />
    [0] 0.3<br />
    [1] 0<br />
  horizontalAlign = "left"<br />
  horizontalGap = 5<br />
  horizontalGridLineColor = 16250871<br />
  horizontalGridLines = false<br />
  icon = (mx.skins.halo::CheckBoxIcon)<br />
  iconColor = 2831164<br />
  indentation = 17<br />
  indicatorGap = 14<br />
  kerning = false<br />
  leading = 2<br />
  letterSpacing = 0<br />
  modalTransparency = 0.5<br />
  modalTransparencyBlur = 3<br />
  modalTransparencyColor = 14540253<br />
  modalTransparencyDuration = 100<br />
  openDuration = 250<br />
  overIcon = (null)<br />
  overSkin = (null)<br />
  paddingBottom = 2<br />
  paddingLeft = 0<br />
  paddingRight = 0<br />
  paddingTop = 2<br />
  repeatDelay = 500<br />
  repeatInterval = 35<br />
  roundedBottomCorners = true<br />
  selectedDisabledIcon = (null)<br />
  selectedDisabledSkin = (null)<br />
  selectedDownIcon = (null)<br />
  selectedDownSkin = (null)<br />
  selectedOverIcon = (null)<br />
  selectedOverSkin = (null)<br />
  selectedUpIcon = (null)<br />
  selectedUpSkin = (null)<br />
  selectionDisabledColor = 14540253<br />
  selectionDuration = 250<br />
  shadowCapColor = 14015965<br />
  shadowColor = 15658734<br />
  shadowDirection = "center"<br />
  shadowDistance = 2<br />
  skin = (null)<br />
  stroked = false<br />
  strokeWidth = 1<br />
  textAlign = "left"<br />
  textDecoration = "none"<br />
  textIndent = 0<br />
  textRollOverColor = 2831164<br />
  textSelectedColor = 2831164<br />
  themeColor = 40447<br />
  upIcon = (null)<br />
  upSkin = (null)<br />
  useRollOver = true<br />
  version = "3.0.0"<br />
  verticalAlign = "top"<br />
  verticalGap = 2<br />
  verticalGridLineColor = 14015965<br />
  verticalGridLines = true<br />
</code></p>
<div><table> <td><iframe src='http://digg.com/api/diggthis.php?w=new&amp;u=http://www.webdevbros.net/2009/08/16/flex-style-introspection/&amp;t=Flex+Style+Introspection&amp;s=normal' height='80' width='52' frameborder='0' scrolling='no'></iframe></td> <td><iframe src='http://www.reddit.com/button_content?newwindow=1&amp;url=http://www.webdevbros.net/2009/08/16/flex-style-introspection/&amp;title=Flex+Style+Introspection&amp;t=2 ' height='80' width='52' scrolling='no' frameborder='0' ></iframe></td> <td><iframe src='http://widgets.dzone.com/links/widgets/zoneit.html?url=http://www.webdevbros.net/2009/08/16/flex-style-introspection/&amp;title=Flex+Style+Introspection&amp;t=1 ' height='80' width='52' scrolling='no' frameborder='0' ></iframe></td> <td><script type="text/javascript"><!--yahooBuzzArticleHeadline=Flex+Style+Introspection;//--></script><script type="text/javascript" src="http://d.yimg.com/ds/badge2.js" badgetype=square></script></td> <td><script type="text/javascript">tweetmeme_url='http://www.webdevbros.net/2009/08/16/flex-style-introspection/'; tweetmeme_style = 'normal';; </script><script type="text/javascript" src="http://tweetmeme.com/i/scripts/button.js" ></script></td></table></div><!-- This is a HTML comment, it will not display in any page. Feel free to remove this comment if it cause any inconvenient to you.
	Thanks for using digg digg, please visit http://www.mkyong.com/blog/digg-digg-wordpress-plugin for any comments and ideas, 
	
    Author : Yong Mook Kim
    Website : http://www.mkyong.com
	-->]]></content:encoded>
			<wfw:commentRss>http://www.webdevbros.net/2009/08/16/flex-style-introspection/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Publishing Flex applications to Google Code SVN repository</title>
		<link>http://www.webdevbros.net/2009/08/16/publishing-flex-applications-to-google-code-svn-repository/</link>
		<comments>http://www.webdevbros.net/2009/08/16/publishing-flex-applications-to-google-code-svn-repository/#comments</comments>
		<pubDate>Sun, 16 Aug 2009 14:32:40 +0000</pubDate>
		<dc:creator>julien</dc:creator>
				<category><![CDATA[general stuff]]></category>

		<guid isPermaLink="false">http://www.webdevbros.net/?p=517</guid>
		<description><![CDATA[I've been struggling with this one a couple of times, so I thought I should share how I solved it. Problem: You are hosting or contributing to an open-source project on code.google.com using SVN as source control. You would like share Flex applications (and View Source) by accessing their public SVN URL. Applications pages (HTML) [...]]]></description>
			<content:encoded><![CDATA[<p>I've been struggling with this one a couple of times, so I thought I should share how I solved it.</p>
<p><strong>Problem:</strong><br />
You are hosting or contributing to an open-source project on code.google.com using SVN as source control.<br />
You would like share Flex applications (and View Source) by accessing their public SVN URL.<br />
Applications pages (HTML) show raw text.</p>
<p><strong>Solution:</strong><br />
Make sure you set the SVN property <em>svn:mime-type</em> for each file:</p>
<ul>
<li><em>*.html</em>: "text/html"</li>
<li>*<em>.css</em>: "text/css"</li>
<li><em>*.zip, *.swf, *.png</em>: "application/octet-stream"</li>
</ul>
<div><table> <td><iframe src='http://digg.com/api/diggthis.php?w=new&amp;u=http://www.webdevbros.net/2009/08/16/publishing-flex-applications-to-google-code-svn-repository/&amp;t=Publishing+Flex+applications+to+Google+Code+SVN+repository&amp;s=normal' height='80' width='52' frameborder='0' scrolling='no'></iframe></td> <td><iframe src='http://www.reddit.com/button_content?newwindow=1&amp;url=http://www.webdevbros.net/2009/08/16/publishing-flex-applications-to-google-code-svn-repository/&amp;title=Publishing+Flex+applications+to+Google+Code+SVN+repository&amp;t=2 ' height='80' width='52' scrolling='no' frameborder='0' ></iframe></td> <td><iframe src='http://widgets.dzone.com/links/widgets/zoneit.html?url=http://www.webdevbros.net/2009/08/16/publishing-flex-applications-to-google-code-svn-repository/&amp;title=Publishing+Flex+applications+to+Google+Code+SVN+repository&amp;t=1 ' height='80' width='52' scrolling='no' frameborder='0' ></iframe></td> <td><script type="text/javascript"><!--yahooBuzzArticleHeadline=Publishing+Flex+applications+to+Google+Code+SVN+repository;//--></script><script type="text/javascript" src="http://d.yimg.com/ds/badge2.js" badgetype=square></script></td> <td><script type="text/javascript">tweetmeme_url='http://www.webdevbros.net/2009/08/16/publishing-flex-applications-to-google-code-svn-repository/'; tweetmeme_style = 'normal';; </script><script type="text/javascript" src="http://tweetmeme.com/i/scripts/button.js" ></script></td></table></div><!-- This is a HTML comment, it will not display in any page. Feel free to remove this comment if it cause any inconvenient to you.
	Thanks for using digg digg, please visit http://www.mkyong.com/blog/digg-digg-wordpress-plugin for any comments and ideas, 
	
    Author : Yong Mook Kim
    Website : http://www.mkyong.com
	-->]]></content:encoded>
			<wfw:commentRss>http://www.webdevbros.net/2009/08/16/publishing-flex-applications-to-google-code-svn-repository/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>bit.ly, tinyurl &amp; co. Does the planet really needs short URLs?</title>
		<link>http://www.webdevbros.net/2009/06/16/bit-ly-tinyurl-co-does-the-planet-really-needs-short-urls/</link>
		<comments>http://www.webdevbros.net/2009/06/16/bit-ly-tinyurl-co-does-the-planet-really-needs-short-urls/#comments</comments>
		<pubDate>Tue, 16 Jun 2009 16:06:40 +0000</pubDate>
		<dc:creator>Michal</dc:creator>
				<category><![CDATA[general stuff]]></category>
		<category><![CDATA[web 2.0]]></category>

		<guid isPermaLink="false">http://www.webdevbros.net/?p=279</guid>
		<description><![CDATA[Over the last couple of years I was wondering almost everyday why the hell someone would want to use a short URL. Although I consider myself as a geek, freak &#038; nerd I've never had the desire to create a short URL. Why? Maybe it's laziness :) Maybe I am not web 2.0 enough... However, [...]]]></description>
			<content:encoded><![CDATA[<p>Over the last couple of years I was wondering almost everyday why the hell someone would want to use a short URL. Although I consider myself as a geek, freak &#038; nerd I've never had the desire to create a short URL. Why? Maybe it's laziness :) Maybe I am not web 2.0 enough...</p>
<p>However, today I've found someone (no one less than Jeff Atwood from <a href="http://www.codinghorror.com">Codinghorror</a>) who seems to share the same thoughts though. He's even calling them the web destroyers and writes about how <a href="http://www.codinghorror.com/blog/archives/001276.html">Twitter made them more popular than ever</a>. Enjoy the read!</p>
<div><table> <td><iframe src='http://digg.com/api/diggthis.php?w=new&amp;u=http://www.webdevbros.net/2009/06/16/bit-ly-tinyurl-co-does-the-planet-really-needs-short-urls/&amp;t=bit.ly%2C+tinyurl+%26+co.+Does+the+planet+really+needs+short+URLs%3F&amp;s=normal' height='80' width='52' frameborder='0' scrolling='no'></iframe></td> <td><iframe src='http://www.reddit.com/button_content?newwindow=1&amp;url=http://www.webdevbros.net/2009/06/16/bit-ly-tinyurl-co-does-the-planet-really-needs-short-urls/&amp;title=bit.ly%2C+tinyurl+%26+co.+Does+the+planet+really+needs+short+URLs%3F&amp;t=2 ' height='80' width='52' scrolling='no' frameborder='0' ></iframe></td> <td><iframe src='http://widgets.dzone.com/links/widgets/zoneit.html?url=http://www.webdevbros.net/2009/06/16/bit-ly-tinyurl-co-does-the-planet-really-needs-short-urls/&amp;title=bit.ly%2C+tinyurl+%26+co.+Does+the+planet+really+needs+short+URLs%3F&amp;t=1 ' height='80' width='52' scrolling='no' frameborder='0' ></iframe></td> <td><script type="text/javascript"><!--yahooBuzzArticleHeadline=bit.ly%2C+tinyurl+%26+co.+Does+the+planet+really+needs+short+URLs%3F;//--></script><script type="text/javascript" src="http://d.yimg.com/ds/badge2.js" badgetype=square></script></td> <td><script type="text/javascript">tweetmeme_url='http://www.webdevbros.net/2009/06/16/bit-ly-tinyurl-co-does-the-planet-really-needs-short-urls/'; tweetmeme_style = 'normal';; </script><script type="text/javascript" src="http://tweetmeme.com/i/scripts/button.js" ></script></td></table></div><!-- This is a HTML comment, it will not display in any page. Feel free to remove this comment if it cause any inconvenient to you.
	Thanks for using digg digg, please visit http://www.mkyong.com/blog/digg-digg-wordpress-plugin for any comments and ideas, 
	
    Author : Yong Mook Kim
    Website : http://www.mkyong.com
	-->]]></content:encoded>
			<wfw:commentRss>http://www.webdevbros.net/2009/06/16/bit-ly-tinyurl-co-does-the-planet-really-needs-short-urls/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Ruby Development Toolkit for Eclipse IDE &#124; RDT</title>
		<link>http://www.webdevbros.net/2009/06/14/ruby-development-toolkit-for-eclipse-ide-rdt/</link>
		<comments>http://www.webdevbros.net/2009/06/14/ruby-development-toolkit-for-eclipse-ide-rdt/#comments</comments>
		<pubDate>Sun, 14 Jun 2009 16:17:25 +0000</pubDate>
		<dc:creator>julien</dc:creator>
				<category><![CDATA[Ruby on Rails]]></category>
		<category><![CDATA[general stuff]]></category>

		<guid isPermaLink="false">http://www.webdevbros.net/?p=256</guid>
		<description><![CDATA[I've been looking into Ruby and Rails recently since I deployed Redmine at my company to support our software development projects. For those who don't know Redmine, this is a great piece of open-source software, offering a complete web collaborative solution for project management including source control, wiki, issues tracking, ldap authentication... Today, I just [...]]]></description>
			<content:encoded><![CDATA[<p>I've been looking into Ruby and Rails recently since I deployed <a href="http://www.redmine.org">Redmine</a> at my company to support our software development projects. For those who don't know Redmine, this is a great piece of open-source software, offering a complete web collaborative solution for project management including source control, wiki, issues tracking, ldap authentication...</p>
<p>Today, I just found out there is a Ruby Development Toolkit (RDT) plugin for my favourite IDE... Eclipse! Sweet! The toolkit is downloadable via Eclipse Software Update, the remote site URL is:</p>
<p>http://updatesite.rubypeople.org/release</p>
<p>Features supported are syntax highlighting, on the fly syntax check, graphical outline, Test::Unit view/runner, Ruby application launching, content assist, source formatter, Ruby debugging, Type Hierarchy view, Ruby specific Search, Refactoring, and much, much more...</p>
<div><table> <td><iframe src='http://digg.com/api/diggthis.php?w=new&amp;u=http://www.webdevbros.net/2009/06/14/ruby-development-toolkit-for-eclipse-ide-rdt/&amp;t=Ruby+Development+Toolkit+for+Eclipse+IDE+%7C+RDT&amp;s=normal' height='80' width='52' frameborder='0' scrolling='no'></iframe></td> <td><iframe src='http://www.reddit.com/button_content?newwindow=1&amp;url=http://www.webdevbros.net/2009/06/14/ruby-development-toolkit-for-eclipse-ide-rdt/&amp;title=Ruby+Development+Toolkit+for+Eclipse+IDE+%7C+RDT&amp;t=2 ' height='80' width='52' scrolling='no' frameborder='0' ></iframe></td> <td><iframe src='http://widgets.dzone.com/links/widgets/zoneit.html?url=http://www.webdevbros.net/2009/06/14/ruby-development-toolkit-for-eclipse-ide-rdt/&amp;title=Ruby+Development+Toolkit+for+Eclipse+IDE+%7C+RDT&amp;t=1 ' height='80' width='52' scrolling='no' frameborder='0' ></iframe></td> <td><script type="text/javascript"><!--yahooBuzzArticleHeadline=Ruby+Development+Toolkit+for+Eclipse+IDE+%7C+RDT;//--></script><script type="text/javascript" src="http://d.yimg.com/ds/badge2.js" badgetype=square></script></td> <td><script type="text/javascript">tweetmeme_url='http://www.webdevbros.net/2009/06/14/ruby-development-toolkit-for-eclipse-ide-rdt/'; tweetmeme_style = 'normal';; </script><script type="text/javascript" src="http://tweetmeme.com/i/scripts/button.js" ></script></td></table></div><!-- This is a HTML comment, it will not display in any page. Feel free to remove this comment if it cause any inconvenient to you.
	Thanks for using digg digg, please visit http://www.mkyong.com/blog/digg-digg-wordpress-plugin for any comments and ideas, 
	
    Author : Yong Mook Kim
    Website : http://www.mkyong.com
	-->]]></content:encoded>
			<wfw:commentRss>http://www.webdevbros.net/2009/06/14/ruby-development-toolkit-for-eclipse-ide-rdt/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Web Dev Bros with WordPress 2.7 now</title>
		<link>http://www.webdevbros.net/2009/05/28/web-dev-bros-with-wordpress27-no/</link>
		<comments>http://www.webdevbros.net/2009/05/28/web-dev-bros-with-wordpress27-no/#comments</comments>
		<pubDate>Thu, 28 May 2009 12:39:41 +0000</pubDate>
		<dc:creator>fab</dc:creator>
				<category><![CDATA[general stuff]]></category>
		<category><![CDATA[genereal]]></category>
		<category><![CDATA[system]]></category>
		<category><![CDATA[upgrade]]></category>

		<guid isPermaLink="false">http://www.webdevbros.net/?p=220</guid>
		<description><![CDATA[We upgraded the blog to the latest version and added some new widgets. The site was down one day because we forgot to upload a missing file ... Sorry for that. We are trying to do add some posts the next days to get this up and running again. I want to welcome Julien and [...]]]></description>
			<content:encoded><![CDATA[<p>We upgraded the blog to the latest version and added some new widgets. The site was down one day because we forgot to upload a missing file ... Sorry for that.</p>
<p>We are trying to do add some posts the next days to get this up and running again. I want to welcome <a href="/about-julien/">Julien</a> and we can't wait to see a post from him :-)</p>
<div><table> <td><iframe src='http://digg.com/api/diggthis.php?w=new&amp;u=http://www.webdevbros.net/2009/05/28/web-dev-bros-with-wordpress27-no/&amp;t=Web+Dev+Bros+with+WordPress+2.7+now&amp;s=normal' height='80' width='52' frameborder='0' scrolling='no'></iframe></td> <td><iframe src='http://www.reddit.com/button_content?newwindow=1&amp;url=http://www.webdevbros.net/2009/05/28/web-dev-bros-with-wordpress27-no/&amp;title=Web+Dev+Bros+with+WordPress+2.7+now&amp;t=2 ' height='80' width='52' scrolling='no' frameborder='0' ></iframe></td> <td><iframe src='http://widgets.dzone.com/links/widgets/zoneit.html?url=http://www.webdevbros.net/2009/05/28/web-dev-bros-with-wordpress27-no/&amp;title=Web+Dev+Bros+with+WordPress+2.7+now&amp;t=1 ' height='80' width='52' scrolling='no' frameborder='0' ></iframe></td> <td><script type="text/javascript"><!--yahooBuzzArticleHeadline=Web+Dev+Bros+with+WordPress+2.7+now;//--></script><script type="text/javascript" src="http://d.yimg.com/ds/badge2.js" badgetype=square></script></td> <td><script type="text/javascript">tweetmeme_url='http://www.webdevbros.net/2009/05/28/web-dev-bros-with-wordpress27-no/'; tweetmeme_style = 'normal';; </script><script type="text/javascript" src="http://tweetmeme.com/i/scripts/button.js" ></script></td></table></div><!-- This is a HTML comment, it will not display in any page. Feel free to remove this comment if it cause any inconvenient to you.
	Thanks for using digg digg, please visit http://www.mkyong.com/blog/digg-digg-wordpress-plugin for any comments and ideas, 
	
    Author : Yong Mook Kim
    Website : http://www.mkyong.com
	-->]]></content:encoded>
			<wfw:commentRss>http://www.webdevbros.net/2009/05/28/web-dev-bros-with-wordpress27-no/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Methods for hiding/obfuscating emails in your website</title>
		<link>http://www.webdevbros.net/2008/08/05/methods-for-hidingobfuscating-emails-in-your-website/</link>
		<comments>http://www.webdevbros.net/2008/08/05/methods-for-hidingobfuscating-emails-in-your-website/#comments</comments>
		<pubDate>Tue, 05 Aug 2008 04:05:40 +0000</pubDate>
		<dc:creator>Michal</dc:creator>
				<category><![CDATA[CSS]]></category>
		<category><![CDATA[general stuff]]></category>

		<guid isPermaLink="false">http://www.webdevbros.net/2008/08/05/methods-for-hidingobfuscating-emails-in-your-website/</guid>
		<description><![CDATA[Hiding your emails on your website can be very tricky and the method should be chosen wisely. Yeah, its our war against email harvesters! Just now i have read the outcome of an interesting study made by Silvan Mühlemann. In his research he used nine different methods to obfuscate the email on his page. He [...]]]></description>
			<content:encoded><![CDATA[<p>Hiding your emails on your website can be very tricky and the method should be chosen wisely. Yeah, its our war against email harvesters! Just now i have read the outcome of an interesting <a href="http://techblog.tilllate.com/2008/07/20/ten-methods-to-obfuscate-e-mail-addresses-compared/">study</a> made by Silvan Mühlemann. In his research he used nine different methods to obfuscate the email on his page. He created an email address for each method and was keeping track of the incoming spam for <strong>1.5!</strong> years. Here is the outcome:</p>
<p align="center"><img height="316" alt="obfuscation methods" src="http://www.webdevbros.net/wp-content/uploads/2008/08/obfuscation-methods.png" width="393" /><br />
<small>(source: <a href="http://techblog.tilllate.com/2008/07/20/ten-methods-to-obfuscate-e-mail-addresses-compared/#comments">Nine ways to obfuscate e-mail addresses compared</a>)</small></p>
<p>Amazing! The simplest methods using CSS had the best results. No Spam at all. There is just one question: How long will it take for the harvesters to adapt their algorithms to this research results?</p>
<p>(If you're interested to see the detailed implementation of those methods just check the original article. I have skipped it.)</p>
<div><table> <td><iframe src='http://digg.com/api/diggthis.php?w=new&amp;u=http://www.webdevbros.net/2008/08/05/methods-for-hidingobfuscating-emails-in-your-website/&amp;t=Methods+for+hiding%2Fobfuscating+emails+in+your+website&amp;s=normal' height='80' width='52' frameborder='0' scrolling='no'></iframe></td> <td><iframe src='http://www.reddit.com/button_content?newwindow=1&amp;url=http://www.webdevbros.net/2008/08/05/methods-for-hidingobfuscating-emails-in-your-website/&amp;title=Methods+for+hiding%2Fobfuscating+emails+in+your+website&amp;t=2 ' height='80' width='52' scrolling='no' frameborder='0' ></iframe></td> <td><iframe src='http://widgets.dzone.com/links/widgets/zoneit.html?url=http://www.webdevbros.net/2008/08/05/methods-for-hidingobfuscating-emails-in-your-website/&amp;title=Methods+for+hiding%2Fobfuscating+emails+in+your+website&amp;t=1 ' height='80' width='52' scrolling='no' frameborder='0' ></iframe></td> <td><script type="text/javascript"><!--yahooBuzzArticleHeadline=Methods+for+hiding%2Fobfuscating+emails+in+your+website;//--></script><script type="text/javascript" src="http://d.yimg.com/ds/badge2.js" badgetype=square></script></td> <td><script type="text/javascript">tweetmeme_url='http://www.webdevbros.net/2008/08/05/methods-for-hidingobfuscating-emails-in-your-website/'; tweetmeme_style = 'normal';; </script><script type="text/javascript" src="http://tweetmeme.com/i/scripts/button.js" ></script></td></table></div><!-- This is a HTML comment, it will not display in any page. Feel free to remove this comment if it cause any inconvenient to you.
	Thanks for using digg digg, please visit http://www.mkyong.com/blog/digg-digg-wordpress-plugin for any comments and ideas, 
	
    Author : Yong Mook Kim
    Website : http://www.mkyong.com
	-->]]></content:encoded>
			<wfw:commentRss>http://www.webdevbros.net/2008/08/05/methods-for-hidingobfuscating-emails-in-your-website/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>

