<?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>Prolific Notion &#187; Umbraco</title>
	<atom:link href="http://www.prolificnotion.co.uk/category/development/umbraco/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.prolificnotion.co.uk</link>
	<description>Welcome to the miscellaneous mutterings of Simon Dingley, Certified Umbraco Developer</description>
	<lastBuildDate>Sun, 15 Jan 2012 08:06:04 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>DataType Support in uSiteBuilder for Umbraco</title>
		<link>http://www.prolificnotion.co.uk/datatype-support-in-usitebuilder-for-umbraco/</link>
		<comments>http://www.prolificnotion.co.uk/datatype-support-in-usitebuilder-for-umbraco/#comments</comments>
		<pubDate>Thu, 22 Dec 2011 15:41:16 +0000</pubDate>
		<dc:creator>Simon Dingley</dc:creator>
				<category><![CDATA[.Net]]></category>
		<category><![CDATA[Development]]></category>
		<category><![CDATA[Feature]]></category>
		<category><![CDATA[Umbraco]]></category>

		<guid isPermaLink="false">http://www.prolificnotion.co.uk/?p=695</guid>
		<description><![CDATA[Adding DataType Support in uSiteBuilder for Umbraco. My initial contribution to the project and how to add my custom build to your own projects.<h3>Related Posts</h3>
<ol>
		<li><a href="http://www.prolificnotion.co.uk/umbraco-locate-nearest-node-with-specific-property/" rel="bookmark">Umbraco : Locate nearest node with specific property</a><!-- (6.1)--></li>
	</ol>


Related posts brought to you by <a href='http://yarpp.org'>Yet Another Related Posts Plugin</a>.]]></description>
			<content:encoded><![CDATA[<div class="tweetmeme_button" style="float: right; margin-left: 10px;">
			<a href="http://api.tweetmeme.com/share?url=http%3A%2F%2Fwww.prolificnotion.co.uk%2Fdatatype-support-in-usitebuilder-for-umbraco%2F"><br />
				<img src="http://api.tweetmeme.com/imagebutton.gif?url=http%3A%2F%2Fwww.prolificnotion.co.uk%2Fdatatype-support-in-usitebuilder-for-umbraco%2F&amp;style=normal&amp;service=bit.ly&amp;service_api=R_e35365ff035ed93fc3e67e6f868b7be3&amp;b=2" height="61" width="50" /><br />
			</a>
		</div>
<p>When I first discovered <a title="uSiteBuilder for Umbraco" href="http://our.umbraco.org/projects/developer-tools/usitebuilder" target="_blank"><strong>uSiteBuilder</strong> for <strong>Umbraco</strong></a> I knew right away that it was a game changer in the world of <strong><a title="Umbraco - The open source ASP.NET CMS " href="http://umbraco.com/" target="_blank">Umbraco</a></strong> development (for me at least!). I always felt a little uncomfortable about having to leave the relative safety of my IDE (Visual Studio 2010) and source control (Mercurial) to work in the browser when creating document types, wiring up templates and datatypes. uSiteBuilder is great because it allows you to take a code-first approach to your development allowing you to develop all of your document types, document type properties and templates with strongly typed code and take advantage of the benefits of any source/version control system you work within.</p>
<p>I guess I have been working with <strong>uSiteBuilder</strong> since earlier this year, shortly after it was released and it is the first dependency I now add to any new <strong><a title="Umbraco - The open source ASP.NET CMS " href="http://umbraco.com/" target="_blank">Umbraco</a> </strong>project. The only show stopper I&#8217;ve encountered rears it&#8217;s ugly head when working on a project with multiple developers and occurs when <strong>uSiteBuilder</strong> runs its synchronisation process and then throws an exception when it encounters a datatype on one of your document types that doesn&#8217;t exist in the target environment. The only real way around this is to <a href="http://our.umbraco.org/projects/developer-tools/usitebuilder/usitebuilder-support/26058-Multi-Developer-problem#comment96970" target="_blank">comment out</a> the offending document type property as recommended by <a title="Barry Fogarty - Umbraco Profile" href="http://our.umbraco.org/member/9909" target="_blank">Barry Fogarty</a>, rebuild and deploy your solution, create the missing datatype and then uncomment, rebuild and deploy again which is a pain and slows down development.</p>
<p>Those kind people over at <a title="Vega IT Sourcing is a software development outsourcing company from Novi Sad, Serbia" href="http://www.vegaitsourcing.rs/" target="_blank">Vega IT Sourcing</a> have released the <a title="uSiteBuilder is a framework made for .NET developers to simplify, speedup and take Umbraco development to next level" href="http://usitebuilder.codeplex.com/" target="_blank">source code for uSiteBuilder</a> which is great for people like me who like to have a go at plugging the gaps myself. So I pulled down the source code and made a custom build in an attempt to support at least the default datatypes for <strong>Umbraco</strong>. I have tried to follow the same logic as the rest of the project so you don&#8217;t really need to think too much about it and can quickly familiarise yourself with  the process for creating your datatypes in code. Here is an example of a custom datatype based on the TinyMCE Richtexteditor datatype in Umbraco:</p>
<pre class="brush: csharp; title: ; notranslate">
// --------------------------------------------------------------------------------------------------------------------
// &lt;copyright file=&quot;StandardContentEditor.cs&quot; company=&quot;Prolific Notion&quot;&gt;
//   (c) Copyright 2011 Prolific Notion, http://prolificnotion.co.uk
// &lt;/copyright&gt;
// &lt;summary&gt;
//   Defines the StandardContentEditor type.
// &lt;/summary&gt;
// --------------------------------------------------------------------------------------------------------------------

namespace MyUmbracoProject.Web.DataTypes
{
    using umbraco.cms.businesslogic.datatype;

    using Vega.USiteBuilder;

    /// &lt;summary&gt;
    /// Defines the Standard Content Editor Datatype
    /// &lt;/summary&gt;
    [DataType(
        UniqueId = &quot;{8AB81EFB-35F5-4EF0-9300-04A3AC8A2D21}&quot;,
        Name = &quot;Standard Content Editor&quot;,
        DatabaseDataType = DBTypes.Ntext,
        RenderControlGuid = &quot;5e9b75ae-face-41c8-b47e-5f4b0fd82f83&quot;)]
    public class StandardContentEditor : DataTypeBase
    {
    }
}
}</pre>
<p>Most of the attributes used here should be self explanatory however&#8230;</p>
<ol>
<li>UniqueId &#8211; A <em>unique</em> Guid for your datatype</li>
<li>Name &#8211; The name of your datatype. This is displayed in the Umbraco UI.</li>
<li>DatabaseDataType &#8211; This maps to the umbraco.cms.businesslogic.datatype.DBTypes Enum and defines the type of field to store data in the database.</li>
<li>RenderControlGuid &#8211; Defines the Guid of the control you would like to render for this datatype. In the example above &#8217;5e9b75ae-face-41c8-b47e-5f4b0fd82f83&#8242; is the Guid for the TinyMCE control.</li>
</ol>
<p>There is one other attribute not in the example above called &#8216;<em>RenderControlName</em>&#8216; which I am in two minds whether to keep or not. Essentially its purpose would be to try and find the control by name and therefore grab it&#8217;s Guid if the Guid attribute was not provided, any thoughts or comments on this appreciated however I think it may be subject to clashes or getting the wrong control because names do not have to be unique.</p>
<p>The only other thing you need to remember is to inherit from DataTypeBase.</p>
<p>I am very happy to have been accepted as a contributor on the uSiteBuilder project this week and hope that I can contribute some of my work into the next release. For now, if you are interested in trying out the build for my initial proof of concept you can <a href="http://usitebuilder.codeplex.com/SourceControl/list/changesets" target="_blank">grab it on CodePlex</a>, changset 84163. I welcome any feedback and comments.</p>
<h2>Where do we go from here?</h2>
<p>At this stage it&#8217;s really just a means of overcoming the exceptions I was previously encountering however I would ideally like to extend this to allow you to also configure your datatype settings in code so watch this space&#8230;!</p>
<h3>Related Posts</h3>
<ol>
		<li><a href="http://www.prolificnotion.co.uk/umbraco-locate-nearest-node-with-specific-property/" rel="bookmark">Umbraco : Locate nearest node with specific property</a><!-- (6.1)--></li>
	</ol>

<p>Related posts brought to you by <a href='http://yarpp.org'>Yet Another Related Posts Plugin</a>.</p>]]></content:encoded>
			<wfw:commentRss>http://www.prolificnotion.co.uk/datatype-support-in-usitebuilder-for-umbraco/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>UCommerce for Umbraco Extension Method &#8211; ISO 3166 Numeric Country Codes</title>
		<link>http://www.prolificnotion.co.uk/ucommerce-for-umbraco-extension-method-iso-3166-numeric-country-codes/</link>
		<comments>http://www.prolificnotion.co.uk/ucommerce-for-umbraco-extension-method-iso-3166-numeric-country-codes/#comments</comments>
		<pubDate>Wed, 28 Sep 2011 09:54:59 +0000</pubDate>
		<dc:creator>Simon Dingley</dc:creator>
				<category><![CDATA[Development]]></category>
		<category><![CDATA[Feature]]></category>
		<category><![CDATA[UCommerce]]></category>
		<category><![CDATA[Umbraco]]></category>

		<guid isPermaLink="false">http://www.prolificnotion.co.uk/?p=680</guid>
		<description><![CDATA[
			
				
			
		
Once again my recent work has brought me back around to messing around with Globalisation issues again. This time it is with regards to writing a customer payment provider for UCommerce implementing the HSBC XML API. Certain fraud rules were being flagged on all transactions during testing due to an incorrect or missing country code, [...]<h3>Related Posts</h3>
<ol>
		<li><a href="http://www.prolificnotion.co.uk/c-utility-method-to-populate-list-controls-with-all-countries-as-given-in-iso-3166-1/" rel="bookmark">C# Utility method to populate list controls with all countries as given in ISO 3166-1</a><!-- (16.2)--></li>
		<li><a href="http://www.prolificnotion.co.uk/c-utility-method-to-populate-list-controls-with-world-currencies/" rel="bookmark">C# Utility method to populate list controls with world currencies</a><!-- (11.5)--></li>
	</ol>


Related posts brought to you by <a href='http://yarpp.org'>Yet Another Related Posts Plugin</a>.]]></description>
			<content:encoded><![CDATA[<div class="tweetmeme_button" style="float: right; margin-left: 10px;">
			<a href="http://api.tweetmeme.com/share?url=http%3A%2F%2Fwww.prolificnotion.co.uk%2Fucommerce-for-umbraco-extension-method-iso-3166-numeric-country-codes%2F"><br />
				<img src="http://api.tweetmeme.com/imagebutton.gif?url=http%3A%2F%2Fwww.prolificnotion.co.uk%2Fucommerce-for-umbraco-extension-method-iso-3166-numeric-country-codes%2F&amp;style=normal&amp;service=bit.ly&amp;service_api=R_e35365ff035ed93fc3e67e6f868b7be3&amp;b=2" height="61" width="50" /><br />
			</a>
		</div>
<p>Once again my recent work has brought me back around to messing around with Globalisation issues again. This time it is with regards to writing a customer payment provider for UCommerce implementing the HSBC XML API. Certain fraud rules were being flagged on all transactions during testing due to an incorrect or missing country code, checking the documentation again it reads &#8220;The 3 digit ISO country code for the customer’s country&#8221;, this is in fact not the alpha but numeric country representation as defined by <a title="ISO 3166 Maintenance agency  (ISO 3166/MA) ISO's focal point for country codes" href="http://www.iso.org/iso/country_codes.htm" target="_blank">ISO 3166 Country Codes</a>. Unfortunately this cannot be obtained through the .Net Framework alone as I have done with similar issues previously so I needed to write an extension method as advised by <a href="http://our.umbraco.org/member/4948" target="_blank">Søren Spelling Lund</a> in this <a title="ISO 3166-1 numeric codes forum post on our.umbraco" href="http://our.umbraco.org/projects/website-utilities/ucommerce/ucommerce-support/24358-ISO-3166-1-numeric-codes#comment90548" target="_blank">forum post</a>.</p>
<p>In case this is of use to anyone else I am posting up my extension method as this will also have uses outside of <a title="E-commerce platform available for Umbraco" href="http://www.ucommerce.dk/" target="_blank">UCommerce</a> for <a title="The open source ASP.NET CMS " href="http://umbraco.com/" target="_blank">Umbraco</a>.</p>
<pre class="brush: csharp; title: ; notranslate">        /// &lt;summary&gt;
        /// Gets the ISO3166 Numeric Country Code
        /// &lt;/summary&gt;
        /// &lt;param name=&quot;country&quot;&gt;The country.&lt;/param&gt;
        /// &lt;returns&gt;The ISO3166 NUmeric Country Code&lt;/returns&gt;
        public static int GetIsoNumericCode(this EntitiesV2.Country country)
        {
            var countryCodesInEu = new Dictionary&lt;string, int&gt;
                                       {
                                           { &quot;AND&quot;, 20 },
                                           { &quot;ARE&quot;, 784 },
                                           { &quot;AFG&quot;, 4 },
                                           { &quot;ATG&quot;, 28 },
                                           { &quot;AIA&quot;, 660 },
                                           { &quot;ALB&quot;, 8 },
                                           { &quot;ARM&quot;, 51 },
                                           { &quot;ANT&quot;, 530 },
                                           { &quot;AGO&quot;, 24 },
                                           { &quot;ATA&quot;, 10 },
                                           { &quot;ARG&quot;, 32 },
                                           { &quot;ASM&quot;, 16 },
                                           { &quot;AUT&quot;, 40 },
                                           { &quot;AUS&quot;, 36 },
                                           { &quot;ABW&quot;, 533 },
                                           { &quot;ALA&quot;, 248 },
                                           { &quot;AZE&quot;, 31 },
                                           { &quot;BIH&quot;, 70 },
                                           { &quot;BRB&quot;, 52 },
                                           { &quot;BGD&quot;, 50 },
                                           { &quot;BEL&quot;, 56 },
                                           { &quot;BFA&quot;, 854 },
                                           { &quot;BGR&quot;, 100 },
                                           { &quot;BHR&quot;, 48 },
                                           { &quot;BDI&quot;, 108 },
                                           { &quot;BEN&quot;, 204 },
                                           { &quot;BMU&quot;, 60 },
                                           { &quot;BRN&quot;, 96 },
                                           { &quot;BOL&quot;, 68 },
                                           { &quot;BRA&quot;, 76 },
                                           { &quot;BHS&quot;, 44 },
                                           { &quot;BTN&quot;, 64 },
                                           { &quot;BVT&quot;, 74 },
                                           { &quot;BWA&quot;, 72 },
                                           { &quot;BLR&quot;, 112 },
                                           { &quot;BLZ&quot;, 84 },
                                           { &quot;CAN&quot;, 124 },
                                           { &quot;CCK&quot;, 166 },
                                           { &quot;COD&quot;, 180 },
                                           { &quot;CAF&quot;, 140 },
                                           { &quot;COG&quot;, 178 },
                                           { &quot;CHE&quot;, 756 },
                                           { &quot;CIV&quot;, 384 },
                                           { &quot;COK&quot;, 184 },
                                           { &quot;CHL&quot;, 152 },
                                           { &quot;CMR&quot;, 120 },
                                           { &quot;CHN&quot;, 156 },
                                           { &quot;COL&quot;, 170 },
                                           { &quot;CRI&quot;, 188 },
                                           { &quot;SCG&quot;, 891 },
                                           { &quot;CUB&quot;, 192 },
                                           { &quot;CPV&quot;, 132 },
                                           { &quot;CXR&quot;, 162 },
                                           { &quot;CYP&quot;, 196 },
                                           { &quot;CZE&quot;, 203 },
                                           { &quot;DEU&quot;, 276 },
                                           { &quot;DJI&quot;, 262 },
                                           { &quot;DNK&quot;, 208 },
                                           { &quot;DMA&quot;, 212 },
                                           { &quot;DOM&quot;, 214 },
                                           { &quot;DZA&quot;, 12 },
                                           { &quot;ECU&quot;, 218 },
                                           { &quot;EST&quot;, 233 },
                                           { &quot;EGY&quot;, 818 },
                                           { &quot;ESH&quot;, 732 },
                                           { &quot;ERI&quot;, 232 },
                                           { &quot;ESP&quot;, 724 },
                                           { &quot;ETH&quot;, 231 },
                                           { &quot;FIN&quot;, 246 },
                                           { &quot;FJI&quot;, 242 },
                                           { &quot;FLK&quot;, 238 },
                                           { &quot;FSM&quot;, 583 },
                                           { &quot;FRO&quot;, 234 },
                                           { &quot;FRA&quot;, 250 },
                                           { &quot;GAB&quot;, 266 },
                                           { &quot;GBR&quot;, 826 },
                                           { &quot;GRD&quot;, 308 },
                                           { &quot;GEO&quot;, 268 },
                                           { &quot;GUF&quot;, 254 },
                                           { &quot;GHA&quot;, 288 },
                                           { &quot;GIB&quot;, 292 },
                                           { &quot;GRL&quot;, 304 },
                                           { &quot;GMB&quot;, 270 },
                                           { &quot;GIN&quot;, 324 },
                                           { &quot;GLP&quot;, 312 },
                                           { &quot;GNQ&quot;, 226 },
                                           { &quot;GRC&quot;, 300 },
                                           { &quot;SGS&quot;, 239 },
                                           { &quot;GTM&quot;, 320 },
                                           { &quot;GUM&quot;, 316 },
                                           { &quot;GNB&quot;, 624 },
                                           { &quot;GUY&quot;, 328 },
                                           { &quot;HKG&quot;, 344 },
                                           { &quot;HMD&quot;, 334 },
                                           { &quot;HND&quot;, 340 },
                                           { &quot;HRV&quot;, 191 },
                                           { &quot;HTI&quot;, 332 },
                                           { &quot;HUN&quot;, 348 },
                                           { &quot;IDN&quot;, 360 },
                                           { &quot;IRL&quot;, 372 },
                                           { &quot;ISR&quot;, 376 },
                                           { &quot;IND&quot;, 356 },
                                           { &quot;IOT&quot;, 86 },
                                           { &quot;IRQ&quot;, 368 },
                                           { &quot;IRN&quot;, 364 },
                                           { &quot;ISL&quot;, 352 },
                                           { &quot;ITA&quot;, 380 },
                                           { &quot;JAM&quot;, 388 },
                                           { &quot;JOR&quot;, 400 },
                                           { &quot;JPN&quot;, 392 },
                                           { &quot;KEN&quot;, 404 },
                                           { &quot;KGZ&quot;, 417 },
                                           { &quot;KHM&quot;, 116 },
                                           { &quot;KIR&quot;, 296 },
                                           { &quot;COM&quot;, 174 },
                                           { &quot;KNA&quot;, 659 },
                                           { &quot;PRK&quot;, 408 },
                                           { &quot;KOR&quot;, 410 },
                                           { &quot;KWT&quot;, 414 },
                                           { &quot;CYM&quot;, 136 },
                                           { &quot;KAZ&quot;, 398 },
                                           { &quot;LAO&quot;, 418 },
                                           { &quot;LBN&quot;, 422 },
                                           { &quot;LCA&quot;, 662 },
                                           { &quot;LIE&quot;, 438 },
                                           { &quot;LKA&quot;, 144 },
                                           { &quot;LBR&quot;, 430 },
                                           { &quot;LSO&quot;, 426 },
                                           { &quot;LTU&quot;, 440 },
                                           { &quot;LUX&quot;, 442 },
                                           { &quot;LVA&quot;, 428 },
                                           { &quot;LBY&quot;, 434 },
                                           { &quot;MAR&quot;, 504 },
                                           { &quot;MCO&quot;, 492 },
                                           { &quot;MDA&quot;, 498 },
                                           { &quot;MDG&quot;, 450 },
                                           { &quot;MHL&quot;, 584 },
                                           { &quot;MKD&quot;, 807 },
                                           { &quot;MLI&quot;, 466 },
                                           { &quot;MMR&quot;, 104 },
                                           { &quot;MNG&quot;, 496 },
                                           { &quot;MAC&quot;, 446 },
                                           { &quot;MNP&quot;, 580 },
                                           { &quot;MTQ&quot;, 474 },
                                           { &quot;MRT&quot;, 478 },
                                           { &quot;MSR&quot;, 500 },
                                           { &quot;MLT&quot;, 470 },
                                           { &quot;MUS&quot;, 480 },
                                           { &quot;MDV&quot;, 462 },
                                           { &quot;MWI&quot;, 454 },
                                           { &quot;MEX&quot;, 484 },
                                           { &quot;MYS&quot;, 458 },
                                           { &quot;MOZ&quot;, 508 },
                                           { &quot;NAM&quot;, 516 },
                                           { &quot;NCL&quot;, 540 },
                                           { &quot;NER&quot;, 562 },
                                           { &quot;NFK&quot;, 574 },
                                           { &quot;NGA&quot;, 566 },
                                           { &quot;NIC&quot;, 558 },
                                           { &quot;NLD&quot;, 528 },
                                           { &quot;NOR&quot;, 578 },
                                           { &quot;NPL&quot;, 524 },
                                           { &quot;NRU&quot;, 520 },
                                           { &quot;NIU&quot;, 570 },
                                           { &quot;NZL&quot;, 554 },
                                           { &quot;OMN&quot;, 512 },
                                           { &quot;PAN&quot;, 591 },
                                           { &quot;PER&quot;, 604 },
                                           { &quot;PYF&quot;, 258 },
                                           { &quot;PNG&quot;, 598 },
                                           { &quot;PHL&quot;, 608 },
                                           { &quot;PAK&quot;, 586 },
                                           { &quot;POL&quot;, 616 },
                                           { &quot;SPM&quot;, 666 },
                                           { &quot;PCN&quot;, 612 },
                                           { &quot;PRI&quot;, 630 },
                                           { &quot;PSE&quot;, 275 },
                                           { &quot;PRT&quot;, 620 },
                                           { &quot;PLW&quot;, 585 },
                                           { &quot;PRY&quot;, 600 },
                                           { &quot;QAT&quot;, 634 },
                                           { &quot;REU&quot;, 638 },
                                           { &quot;ROU&quot;, 642 },
                                           { &quot;RUS&quot;, 643 },
                                           { &quot;RWA&quot;, 646 },
                                           { &quot;SAU&quot;, 682 },
                                           { &quot;SLB&quot;, 90 },
                                           { &quot;SYC&quot;, 690 },
                                           { &quot;SDN&quot;, 736 },
                                           { &quot;SWE&quot;, 752 },
                                           { &quot;SGP&quot;, 702 },
                                           { &quot;SHN&quot;, 654 },
                                           { &quot;SVN&quot;, 705 },
                                           { &quot;SJM&quot;, 744 },
                                           { &quot;SVK&quot;, 703 },
                                           { &quot;SLE&quot;, 694 },
                                           { &quot;SMR&quot;, 674 },
                                           { &quot;SEN&quot;, 686 },
                                           { &quot;SOM&quot;, 706 },
                                           { &quot;SUR&quot;, 740 },
                                           { &quot;STP&quot;, 678 },
                                           { &quot;SLV&quot;, 222 },
                                           { &quot;SYR&quot;, 760 },
                                           { &quot;SWZ&quot;, 748 },
                                           { &quot;TCA&quot;, 796 },
                                           { &quot;TCD&quot;, 148 },
                                           { &quot;ATF&quot;, 260 },
                                           { &quot;TGO&quot;, 768 },
                                           { &quot;THA&quot;, 764 },
                                           { &quot;TJK&quot;, 762 },
                                           { &quot;TKL&quot;, 772 },
                                           { &quot;TLS&quot;, 626 },
                                           { &quot;TKM&quot;, 795 },
                                           { &quot;TUN&quot;, 788 },
                                           { &quot;TON&quot;, 776 },
                                           { &quot;TUR&quot;, 792 },
                                           { &quot;TTO&quot;, 780 },
                                           { &quot;TUV&quot;, 798 },
                                           { &quot;TWN&quot;, 158 },
                                           { &quot;TZA&quot;, 834 },
                                           { &quot;UKR&quot;, 804 },
                                           { &quot;UGA&quot;, 800 },
                                           { &quot;UMI&quot;, 581 },
                                           { &quot;USA&quot;, 840 },
                                           { &quot;URY&quot;, 858 },
                                           { &quot;UZB&quot;, 860 },
                                           { &quot;VAT&quot;, 336 },
                                           { &quot;VCT&quot;, 670 },
                                           { &quot;VEN&quot;, 862 },
                                           { &quot;VGB&quot;, 92 },
                                           { &quot;VIR&quot;, 850 },
                                           { &quot;VNM&quot;, 704 },
                                           { &quot;VUT&quot;, 548 },
                                           { &quot;WLF&quot;, 876 },
                                           { &quot;WSM&quot;, 882 },
                                           { &quot;YEM&quot;, 887 },
                                           { &quot;MYT&quot;, 175 },
                                           { &quot;ZAF&quot;, 710 },
                                           { &quot;ZMB&quot;, 894 },
                                           { &quot;ZWE&quot;, 716 },
                                       };

            var regionInfo = new RegionInfo(country.Culture);

            if (countryCodesInEu.Keys.Contains(regionInfo.ThreeLetterISORegionName))
                return countryCodesInEu[country.Name];

            return -1;
        }</pre>
<h3>Related Posts</h3>
<ol>
		<li><a href="http://www.prolificnotion.co.uk/c-utility-method-to-populate-list-controls-with-all-countries-as-given-in-iso-3166-1/" rel="bookmark">C# Utility method to populate list controls with all countries as given in ISO 3166-1</a><!-- (16.2)--></li>
		<li><a href="http://www.prolificnotion.co.uk/c-utility-method-to-populate-list-controls-with-world-currencies/" rel="bookmark">C# Utility method to populate list controls with world currencies</a><!-- (11.5)--></li>
	</ol>

<p>Related posts brought to you by <a href='http://yarpp.org'>Yet Another Related Posts Plugin</a>.</p>]]></content:encoded>
			<wfw:commentRss>http://www.prolificnotion.co.uk/ucommerce-for-umbraco-extension-method-iso-3166-numeric-country-codes/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>The create dialog for &#8220;Media&#8221; does not match anything defined in the &#8220;~/umbraco/config/create/UI.xml&#8221;.</title>
		<link>http://www.prolificnotion.co.uk/the-create-dialog-for-media-does-not-match-anything-defined-in-the-umbracoconfigcreateui-xml/</link>
		<comments>http://www.prolificnotion.co.uk/the-create-dialog-for-media-does-not-match-anything-defined-in-the-umbracoconfigcreateui-xml/#comments</comments>
		<pubDate>Mon, 22 Aug 2011 19:51:59 +0000</pubDate>
		<dc:creator>Simon Dingley</dc:creator>
				<category><![CDATA[Development]]></category>
		<category><![CDATA[Umbraco]]></category>

		<guid isPermaLink="false">http://www.prolificnotion.co.uk/?p=667</guid>
		<description><![CDATA[How to fix the exception 'The create dialog for "Media" does not match anything defined in the "~/umbraco/config/create/UI.xml". This could mean an incorrectly installed package or a corrupt UI file' when upgrading Umbraco sites from earlier versions to v4.7.0.<h3>Related Posts</h3>
<ol>
		<li><a href="http://www.prolificnotion.co.uk/error-creating-control-for-nodetype-media/" rel="bookmark">ERROR CREATING CONTROL FOR NODETYPE: Media</a><!-- (13.1)--></li>
		<li><a href="http://www.prolificnotion.co.uk/media-sorter-for-umbraco/" rel="bookmark">Media Sorter for Umbraco</a><!-- (7.9)--></li>
		<li><a href="http://www.prolificnotion.co.uk/use-appcmd-to-migrate-web-config-from-iis6-to-iis7/" rel="bookmark">Use AppCmd to Migrate web.config from IIS6 to IIS7</a><!-- (5.8)--></li>
	</ol>


Related posts brought to you by <a href='http://yarpp.org'>Yet Another Related Posts Plugin</a>.]]></description>
			<content:encoded><![CDATA[<div class="tweetmeme_button" style="float: right; margin-left: 10px;">
			<a href="http://api.tweetmeme.com/share?url=http%3A%2F%2Fwww.prolificnotion.co.uk%2Fthe-create-dialog-for-media-does-not-match-anything-defined-in-the-umbracoconfigcreateui-xml%2F"><br />
				<img src="http://api.tweetmeme.com/imagebutton.gif?url=http%3A%2F%2Fwww.prolificnotion.co.uk%2Fthe-create-dialog-for-media-does-not-match-anything-defined-in-the-umbracoconfigcreateui-xml%2F&amp;style=normal&amp;service=bit.ly&amp;service_api=R_e35365ff035ed93fc3e67e6f868b7be3&amp;b=2" height="61" width="50" /><br />
			</a>
		</div>
<p>When upgrading sites from an earlier version of Umbraco prior to v4.7.0 you may encounter the following exception when trying to create new media items:</p>
<p><em>The create dialog for &#8220;Media&#8221; does not match anything defined in the &#8220;~/umbraco/config/create/UI.xml&#8221;. This could mean an incorrectly installed package or a corrupt UI file</em></p>
<p><em></em>There is an easy fix for this and sadly is due simply to the incorrect casing of the &#8216;Media&#8217; nodeType defined in the <em>UI.xml</em> configuration file. To fix simply open the <em>~/umbraco/config/create/UI.xml </em>file in your preferred text editor and locate the following line:</p>
<pre class="brush: xml; title: ; notranslate">&lt;nodeType alias=&quot;media&quot;&gt;</pre>
<p>Simply change the word media to have an uppercase &#8216;<em>m&#8217;</em> and save the file and your problems will go away!</p>
<pre class="brush: xml; title: ; notranslate">&lt;nodeType alias=&quot;Media&quot;&gt;</pre>
<p><em><strong>Update: As per the comment by Petr Snobelt, for future compatibility it is possibly best to change the case in the database rather than the UI.xml file</strong></em></p>
<h3>Related Posts</h3>
<ol>
		<li><a href="http://www.prolificnotion.co.uk/error-creating-control-for-nodetype-media/" rel="bookmark">ERROR CREATING CONTROL FOR NODETYPE: Media</a><!-- (13.1)--></li>
		<li><a href="http://www.prolificnotion.co.uk/media-sorter-for-umbraco/" rel="bookmark">Media Sorter for Umbraco</a><!-- (7.9)--></li>
		<li><a href="http://www.prolificnotion.co.uk/use-appcmd-to-migrate-web-config-from-iis6-to-iis7/" rel="bookmark">Use AppCmd to Migrate web.config from IIS6 to IIS7</a><!-- (5.8)--></li>
	</ol>

<p>Related posts brought to you by <a href='http://yarpp.org'>Yet Another Related Posts Plugin</a>.</p>]]></content:encoded>
			<wfw:commentRss>http://www.prolificnotion.co.uk/the-create-dialog-for-media-does-not-match-anything-defined-in-the-umbracoconfigcreateui-xml/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Using Umbraco and Razor Syntax to add attributes to body tag for CSS targetting</title>
		<link>http://www.prolificnotion.co.uk/using-umbraco-and-razor-syntax-to-add-attributes-to-body-tag-for-css-targetting/</link>
		<comments>http://www.prolificnotion.co.uk/using-umbraco-and-razor-syntax-to-add-attributes-to-body-tag-for-css-targetting/#comments</comments>
		<pubDate>Tue, 22 Feb 2011 17:33:35 +0000</pubDate>
		<dc:creator>Simon Dingley</dc:creator>
				<category><![CDATA[Umbraco]]></category>

		<guid isPermaLink="false">http://www.prolificnotion.co.uk/?p=608</guid>
		<description><![CDATA[
			
				
			
		
I never found a solution that I was happy with for adding unique id&#8217;s to a page body tag that didn&#8217;t feel like a hack. I often need to do it for very specific CSS targeting so I introduce to you my current solution using the new Razor syntax inside of a master template in [...]<h3>Related Posts</h3>
<ol>
		<li><a href="http://www.prolificnotion.co.uk/remember-to-use-validationgroup-in-umbraco-dashboard-user-controls/" rel="bookmark">Remember to use ValidationGroup in Umbraco Dashboard User Controls</a><!-- (5.5)--></li>
		<li><a href="http://www.prolificnotion.co.uk/level-2-certified-umbraco-developer-status/" rel="bookmark">Level 2 Certified Umbraco Developer Status</a><!-- (5.5)--></li>
	</ol>


Related posts brought to you by <a href='http://yarpp.org'>Yet Another Related Posts Plugin</a>.]]></description>
			<content:encoded><![CDATA[<div class="tweetmeme_button" style="float: right; margin-left: 10px;">
			<a href="http://api.tweetmeme.com/share?url=http%3A%2F%2Fwww.prolificnotion.co.uk%2Fusing-umbraco-and-razor-syntax-to-add-attributes-to-body-tag-for-css-targetting%2F"><br />
				<img src="http://api.tweetmeme.com/imagebutton.gif?url=http%3A%2F%2Fwww.prolificnotion.co.uk%2Fusing-umbraco-and-razor-syntax-to-add-attributes-to-body-tag-for-css-targetting%2F&amp;style=normal&amp;service=bit.ly&amp;service_api=R_e35365ff035ed93fc3e67e6f868b7be3&amp;b=2" height="61" width="50" /><br />
			</a>
		</div>
<p>I never found a solution that I was happy with for adding unique id&#8217;s to a page body tag that didn&#8217;t feel like a hack. I often need to do it for very specific CSS targeting so I introduce to you my current solution using the new Razor syntax inside of a master template in Umbraco.</p>
<pre class="brush: csharp; title: ; notranslate">&lt;umbraco:macro runat=&quot;server&quot; language=&quot;razor&quot;&gt;

&lt;body id=&quot;@Model.Id&quot;&gt;

&lt;/umbraco:macro&gt;</pre>
<p><strong> UPDATED</strong>: The example above has now been updated to simplify it and require just a single piece of code inside of the inline-macro &#8220;<span style="font-family: Consolas, Monaco, 'Courier New', Courier, monospace; font-size: 12px; line-height: 18px; white-space: pre;">@Model.Id&#8221; to output the current page id.</span></p>
<p>Essentially all this is doing is appending the current node id to a string (in my case just the letter &#8216;p&#8217;) and adding it to the id attribute of the html body tag.</p>
<p>I tend to also need to take this one step further and include the id of a parent page in case styling is applied to a section of the content tree, I do this by adding a class to the body tag which contains the section id. The solution for this that I have used successfully on a current project is as follows:</p>
<pre class="brush: csharp; title: ; notranslate">&lt;umbraco:macro runat=&quot;server&quot; language=&quot;razor&quot;&gt;

@{
	var node = Model;
	var sid = &quot;s&quot; + Model.Id;
	var level = 2;

	while(node.Level &gt; 1)
	{
		if (node.Level == level)
		{
		  // Add any logic in here then create your class
		  sid = &quot;s&quot; + node.Id;
		}
		node = node.Parent;
	}
}

&lt;body id=&quot;@Model.Id&quot; class=&quot;@sid&quot;&gt;

&lt;/umbraco:macro&gt;</pre>
<p>As in the previous example I am appending the current page id to a string and adding it to the id attribute of the body tag. I am also using a while loop to walk up the content tree to a specific level in the content tree, which in this case is level 2 and I am getting the id of the page at the specified level and appending it to a string(which in this case is &#8216;s&#8217;) and adding it to the class attribute of the body tag.</p>
<p>So what have I gained by doing this? I can now apply specifically targeted CSS styling to individual pages or to an entire section of the content tree.</p>
<p>I would welcome any comments from those more familiar with Razor in Umbraco on the performance overhead of doing this on each page load since I am including this in my master page.</p>
<p>* Credit goes to <a title="Jonas Eriksson Twitter page" href="http://twitter.com/#!/joeriks">Jonas Eriksson</a> for his tip on the Razor syntax for accessing parent nodes and to <a title="Aaron Powell Twitter page" href="http://twitter.com/#!/slace">Aaron Powell</a> for his introduction to &#8220;<a title="Using Razor in Umbraco 4" href="http://www.aaron-powell.com/umbraco-4-and-razor">Using Razor in Umbraco 4</a>&#8221; blog post.</p>
<h3>Related Posts</h3>
<ol>
		<li><a href="http://www.prolificnotion.co.uk/remember-to-use-validationgroup-in-umbraco-dashboard-user-controls/" rel="bookmark">Remember to use ValidationGroup in Umbraco Dashboard User Controls</a><!-- (5.5)--></li>
		<li><a href="http://www.prolificnotion.co.uk/level-2-certified-umbraco-developer-status/" rel="bookmark">Level 2 Certified Umbraco Developer Status</a><!-- (5.5)--></li>
	</ol>

<p>Related posts brought to you by <a href='http://yarpp.org'>Yet Another Related Posts Plugin</a>.</p>]]></content:encoded>
			<wfw:commentRss>http://www.prolificnotion.co.uk/using-umbraco-and-razor-syntax-to-add-attributes-to-body-tag-for-css-targetting/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>Level 2 Certified Umbraco Developer Status</title>
		<link>http://www.prolificnotion.co.uk/level-2-certified-umbraco-developer-status/</link>
		<comments>http://www.prolificnotion.co.uk/level-2-certified-umbraco-developer-status/#comments</comments>
		<pubDate>Mon, 06 Dec 2010 21:27:53 +0000</pubDate>
		<dc:creator>Simon Dingley</dc:creator>
				<category><![CDATA[Umbraco]]></category>

		<guid isPermaLink="false">http://www.prolificnotion.co.uk/?p=572</guid>
		<description><![CDATA[
			
				
			
		
I am proud to announce that I gained Level 2 Certified Umbraco Developer Status at the start of the month!
After investing the last 4 years or so into developing solutions with the Umbraco Content Management System I was given the opportunity to take level 2 certification in London at the start of December. I decided [...]<h3>Related Posts</h3>

No related posts.


Related posts brought to you by <a href='http://yarpp.org'>Yet Another Related Posts Plugin</a>.]]></description>
			<content:encoded><![CDATA[<div class="tweetmeme_button" style="float: right; margin-left: 10px;">
			<a href="http://api.tweetmeme.com/share?url=http%3A%2F%2Fwww.prolificnotion.co.uk%2Flevel-2-certified-umbraco-developer-status%2F"><br />
				<img src="http://api.tweetmeme.com/imagebutton.gif?url=http%3A%2F%2Fwww.prolificnotion.co.uk%2Flevel-2-certified-umbraco-developer-status%2F&amp;style=normal&amp;service=bit.ly&amp;service_api=R_e35365ff035ed93fc3e67e6f868b7be3&amp;b=2" height="61" width="50" /><br />
			</a>
		</div>
<p>I am proud to announce that I gained Level 2 <strong>Certified Umbraco Developer</strong> Status at the start of the month!</p>
<p>After investing the last 4 years or so into developing solutions with the Umbraco Content Management System I was given the opportunity to take level 2 certification in London at the start of December. I decided that the time was right to now get certified in order to qualify the skills I have learnt throughout my journey and to hopefully attract more Umbraco related work my way.</p>
<p>Umbraco has grown dramatically over the last few years both in terms of it&#8217;s popularity but at the same time it has matured into a very user-friendly and flexible content management solution that is now being adopted by some very large companies including Microsoft who are now really getting behind Umbraco and even think highly enough of it to use it on sites of their own such as <a href="http://www.asp.net/">ASP.Net</a>. Umbraco has the most helpful and friendly community I have experienced on-line in my 13 or so years of web development and also running communities of my own.</p>
<h3>Related Posts</h3>
<p>No related posts.</p>

<p>Related posts brought to you by <a href='http://yarpp.org'>Yet Another Related Posts Plugin</a>.</p>]]></content:encoded>
			<wfw:commentRss>http://www.prolificnotion.co.uk/level-2-certified-umbraco-developer-status/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Remember to use ValidationGroup in Umbraco Dashboard User Controls</title>
		<link>http://www.prolificnotion.co.uk/remember-to-use-validationgroup-in-umbraco-dashboard-user-controls/</link>
		<comments>http://www.prolificnotion.co.uk/remember-to-use-validationgroup-in-umbraco-dashboard-user-controls/#comments</comments>
		<pubDate>Mon, 22 Mar 2010 09:25:55 +0000</pubDate>
		<dc:creator>Simon Dingley</dc:creator>
				<category><![CDATA[Umbraco]]></category>

		<guid isPermaLink="false">http://www.prolificnotion.co.uk/?p=244</guid>
		<description><![CDATA[Based on a recent experience and a lot of wasted time, this post details why you really should set the validation group on validation controls that you add to your custom Umbraco user controls.<h3>Related Posts</h3>
<ol>
		<li><a href="http://www.prolificnotion.co.uk/umbraco-datepicker-unknown-server-tag/" rel="bookmark">Umbraco DatePicker &#8211; Unknown server tag</a><!-- (5)--></li>
	</ol>


Related posts brought to you by <a href='http://yarpp.org'>Yet Another Related Posts Plugin</a>.]]></description>
			<content:encoded><![CDATA[<div class="tweetmeme_button" style="float: right; margin-left: 10px;">
			<a href="http://api.tweetmeme.com/share?url=http%3A%2F%2Fwww.prolificnotion.co.uk%2Fremember-to-use-validationgroup-in-umbraco-dashboard-user-controls%2F"><br />
				<img src="http://api.tweetmeme.com/imagebutton.gif?url=http%3A%2F%2Fwww.prolificnotion.co.uk%2Fremember-to-use-validationgroup-in-umbraco-dashboard-user-controls%2F&amp;style=normal&amp;service=bit.ly&amp;service_api=R_e35365ff035ed93fc3e67e6f868b7be3&amp;b=2" height="61" width="50" /><br />
			</a>
		</div>
<p>This post is more of a note to myself but may save someone else a lot of wasted time trying to track down why they can no longer save selected nodes in <a title="Umbraco - The Friendly CMS" href="http://umbraco.org">Umbraco</a>. In a recent project I created a number of custom user controls for the Umbraco Dashboard, these user controls contained validations controls but I had overlooked adding the <em>validationgroup</em> property on the validation controls so when attempts were made to save or publish a node containing one of these user controls that didn&#8217;t validate, the changes would not save as the page could not be posted back to the server. The problem is not always immediately obvious if the user control that is not valid is on a different tab to the one you are on when attempting to save or publish.</p>
<p>I guess an alternative or complimentary method would be to display a Javascript alert notifying the user that there are still controls that don&#8217;t validate.</p>
<h3>Related Posts</h3>
<ol>
		<li><a href="http://www.prolificnotion.co.uk/umbraco-datepicker-unknown-server-tag/" rel="bookmark">Umbraco DatePicker &#8211; Unknown server tag</a><!-- (5)--></li>
	</ol>

<p>Related posts brought to you by <a href='http://yarpp.org'>Yet Another Related Posts Plugin</a>.</p>]]></content:encoded>
			<wfw:commentRss>http://www.prolificnotion.co.uk/remember-to-use-validationgroup-in-umbraco-dashboard-user-controls/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Umbraco DatePicker &#8211; Unknown server tag</title>
		<link>http://www.prolificnotion.co.uk/umbraco-datepicker-unknown-server-tag/</link>
		<comments>http://www.prolificnotion.co.uk/umbraco-datepicker-unknown-server-tag/#comments</comments>
		<pubDate>Tue, 02 Mar 2010 11:33:42 +0000</pubDate>
		<dc:creator>Simon Dingley</dc:creator>
				<category><![CDATA[Umbraco]]></category>

		<guid isPermaLink="false">http://www.prolificnotion.co.uk/?p=380</guid>
		<description><![CDATA[
			
				
			
		
I have recently needed to use the Umbraco datePicker control in a usercontrol I was creating however I kept getting presented with an &#8220;Unknown server tag &#8216;umbraco:datePicker&#8221; exception. After some digging around in the Umbraco Source it is confusingly not in the assembly I would have expected but it was in fact located in the [...]<h3>Related Posts</h3>

No related posts.


Related posts brought to you by <a href='http://yarpp.org'>Yet Another Related Posts Plugin</a>.]]></description>
			<content:encoded><![CDATA[<div class="tweetmeme_button" style="float: right; margin-left: 10px;">
			<a href="http://api.tweetmeme.com/share?url=http%3A%2F%2Fwww.prolificnotion.co.uk%2Fumbraco-datepicker-unknown-server-tag%2F"><br />
				<img src="http://api.tweetmeme.com/imagebutton.gif?url=http%3A%2F%2Fwww.prolificnotion.co.uk%2Fumbraco-datepicker-unknown-server-tag%2F&amp;style=normal&amp;service=bit.ly&amp;service_api=R_e35365ff035ed93fc3e67e6f868b7be3&amp;b=2" height="61" width="50" /><br />
			</a>
		</div>
<p>I have recently needed to use the Umbraco datePicker control in a usercontrol I was creating however I kept getting presented with an &#8220;Unknown server tag &#8216;umbraco:datePicker&#8221; exception. After some digging around in the <a title="Browse the Umbraco source code on CodePlex" href="http://umbraco.codeplex.com/SourceControl/list/changesets">Umbraco Source</a> it is confusingly not in the assembly I would have expected but it was in fact located in the cms.dll and not controls.dll. As a couple of other Umbracians posted this query a day or so after I found the solution I thought I would post it up for the benefit of others.</p>
<p>Simply include the following in your usercontrol:</p>
<pre>&lt;%@ Register TagPrefix="umbraco" Namespace="umbraco.controls" Assembly="cms" %&gt;</pre>
<p>and then use it as follows:</p>
<pre class="brush: csharp; title: ; notranslate">&lt;umbraco:datePicker ID=&quot;datePicker1&quot; runat=&quot;server&quot; ShowTime=&quot;true&quot;&gt;&lt;/umbraco:datePicker&gt;</pre>
<p>I hope this is of help to others and can be refactored asap to avoid any further confusion.</p>
<h3>Related Posts</h3>
<p>No related posts.</p>

<p>Related posts brought to you by <a href='http://yarpp.org'>Yet Another Related Posts Plugin</a>.</p>]]></content:encoded>
			<wfw:commentRss>http://www.prolificnotion.co.uk/umbraco-datepicker-unknown-server-tag/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Empower yourself and your team by implementing a Content Management System (CMS)</title>
		<link>http://www.prolificnotion.co.uk/take-control-of-your-website-use-a-content-management-system-cms/</link>
		<comments>http://www.prolificnotion.co.uk/take-control-of-your-website-use-a-content-management-system-cms/#comments</comments>
		<pubDate>Fri, 29 Jan 2010 20:52:26 +0000</pubDate>
		<dc:creator>Simon Dingley</dc:creator>
				<category><![CDATA[Feature]]></category>
		<category><![CDATA[Umbraco]]></category>

		<guid isPermaLink="false">http://www.prolificnotion.co.uk/?p=343</guid>
		<description><![CDATA[
			
				
			
		
There was a time not so long ago, when website developers were treated with almost as much reverence as pilots and surgeons. After all, without a website, your business was just not a player, non-existent, invisible to the world. No one had any idea as to what they did, or how they did it, just [...]<h3>Related Posts</h3>

No related posts.


Related posts brought to you by <a href='http://yarpp.org'>Yet Another Related Posts Plugin</a>.]]></description>
			<content:encoded><![CDATA[<div class="tweetmeme_button" style="float: right; margin-left: 10px;">
			<a href="http://api.tweetmeme.com/share?url=http%3A%2F%2Fwww.prolificnotion.co.uk%2Ftake-control-of-your-website-use-a-content-management-system-cms%2F"><br />
				<img src="http://api.tweetmeme.com/imagebutton.gif?url=http%3A%2F%2Fwww.prolificnotion.co.uk%2Ftake-control-of-your-website-use-a-content-management-system-cms%2F&amp;style=normal&amp;service=bit.ly&amp;service_api=R_e35365ff035ed93fc3e67e6f868b7be3&amp;b=2" height="61" width="50" /><br />
			</a>
		</div>
<p>There was a time not so long ago, when website developers were treated with almost as much reverence as pilots and surgeons. After all, without a website, your business was just not a player, non-existent, invisible to the world. No one had any idea as to what they did, or how they did it, just that they were able, as if by magic, to put our business into cyberspace in full view of a global audience.</p>
<p>There were pictures and there were words too. It was marvellous. Who will ever forget the day our website went live. But, as is life, we wanted more. A new product range, a change in pricing perhaps, or maybe even some customer feedback comments. Suddenly things got a little tricky. We were told that there was no development time available for at least two weeks, or the site would have to be rewritten as expansion was not part of the initial brief, blah blah. Bottom line? It cost money. Every change or tweak became an uphill struggle and a nightmare scenario.</p>
<p>Luckily all this is now a thing of the past. The reason? Content Management Systems, or CMS for short. These little beauties have given us the power now. No longer beholden to our developers, we proudly add, tweak and change to our hearts content and glory and revel in our new found freedom. And best of all, there&#8217;s no extra costs. involved.</p>
<p>From humble beginnings as a simple textual template editor tool, CMS has now really come of age and is simply an essential ingredient in any website design. Today&#8217;s systems are dynamic tools that give you the power to produce high quality web content without any programming knowledge. In the main, used via a simple menu system, CMS will allow you to add new pages of content and images, format your page design, add titles and navigation, edit existing pages, put in SEO meta data, allow for multiple users and let you roll back to previous versions if you make a mistake.</p>
<p>There are however, some rules to this heavenly scenario that should be observed at all costs.</p>
<ol>
<li>Now that you have free reign, your web content should be written to be informative to your visitors of course, but it also must be search spider friendly. This is crucial to getting your website successfully indexed and ranked high by Google.</li>
<li>CMS systems can be widely varying in cost which will be determined by the power and flexibility you are looking for. The cheapest option might sound appealing but could prove to be a serious mistake when you realise that you really need much more flexibility and there is no doubt you will, so try to future proof if possible by picking a system that will not restrict your progress.</li>
<li>Is the system secure. You will need, if you are allowing multiple user access, to ensure you have sufficient overall control.</li>
<li>Does it work across all platforms? These days websites need to be seen on different browsers and mobile technology too.</li>
<li>Is there comprehensive support for you, because one thing is sure, you will need it at the most unlikeliest of times.</li>
</ol>
<p>With all these possibilities factored in, you will find that the freedom, speed and cost savings you experience through installing a versatile CMS on your site will more than justify the price tag.</p>
<p>Keep an eye out for part two of this series on the topic of Content Management Systems.</p>
<h3>Related Posts</h3>
<p>No related posts.</p>

<p>Related posts brought to you by <a href='http://yarpp.org'>Yet Another Related Posts Plugin</a>.</p>]]></content:encoded>
			<wfw:commentRss>http://www.prolificnotion.co.uk/take-control-of-your-website-use-a-content-management-system-cms/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Convert HTML to Plain Text in C# using Markdown</title>
		<link>http://www.prolificnotion.co.uk/convert-html-to-plain-text-in-c-using-markdown/</link>
		<comments>http://www.prolificnotion.co.uk/convert-html-to-plain-text-in-c-using-markdown/#comments</comments>
		<pubDate>Wed, 04 Nov 2009 13:41:12 +0000</pubDate>
		<dc:creator>Simon Dingley</dc:creator>
				<category><![CDATA[.Net]]></category>
		<category><![CDATA[Umbraco]]></category>
		<category><![CDATA[ASP.NET]]></category>

		<guid isPermaLink="false">http://www.prolificnotion.co.uk/?p=262</guid>
		<description><![CDATA[Creating a plain-text version of HTML that is suitable to be sent out as the text part of a multi-part email. Using C# and XSLT I have developed a working solution to the problem with help from a third party markdown XSLT file.<h3>Related Posts</h3>

No related posts.


Related posts brought to you by <a href='http://yarpp.org'>Yet Another Related Posts Plugin</a>.]]></description>
			<content:encoded><![CDATA[<div class="tweetmeme_button" style="float: right; margin-left: 10px;">
			<a href="http://api.tweetmeme.com/share?url=http%3A%2F%2Fwww.prolificnotion.co.uk%2Fconvert-html-to-plain-text-in-c-using-markdown%2F"><br />
				<img src="http://api.tweetmeme.com/imagebutton.gif?url=http%3A%2F%2Fwww.prolificnotion.co.uk%2Fconvert-html-to-plain-text-in-c-using-markdown%2F&amp;style=normal&amp;service=bit.ly&amp;service_api=R_e35365ff035ed93fc3e67e6f868b7be3&amp;b=2" height="61" width="50" /><br />
			</a>
		</div>
<p>While working on my customisations to <a style="outline-style: none; outline-width: initial; outline-color: initial; color: #33707e; text-decoration: underline; padding: 0px; margin: 0px; border: 0px initial initial;" href="http://www.nibble.be/">Tim Geyssens</a> <a style="outline-style: none; outline-width: initial; outline-color: initial; color: #33707e; text-decoration: underline; padding: 0px; margin: 0px; border: 0px initial initial;" href="http://www.nibble.be/?p=63">MailEngine</a> I was looking for an accurate method of automatically creating a plain-text version of the HTML emails that were being sent out by the site. Further reading brought my attention to something called <a title="Read more about Markdown here" href="http://en.wikipedia.org/wiki/Markdown">Markdown</a>. After some hunting around with a little help from my friend Google I managed to find a markdown XSLT file. Using the XSLT I could transform my HTML email to plain-text with relative ease and accuracy. Of course in order to do this I would need a valid XML document and as my pages were already valid XHTML I had no problems there.</p>
<p>Here is my method for doing the conversion, all it requires is that you pass it the HTML you want to convert which must be valid XML:</p>
<pre class="brush: csharp; title: ; notranslate">/// &lt;summary&gt;
/// Converts to HTML to plain-text.
/// &lt;/summary&gt;
/// &lt;param name=&quot;HTML&quot;&gt;The HTML.&lt;/param&gt;
/// &lt;returns&gt;The plain text representation of the HTML&lt;/returns&gt;
private static string ConvertToText(string HTML)
{
    string text = string.Empty;

    XmlDocument xmlDoc = new XmlDocument();
    XmlDocument xsl = new XmlDocument();
    xmlDoc.LoadXml(HTML);
    xsl.CreateEntityReference(&quot;nbsp&quot;);
    xsl.Load(System.Web.HttpContext.Current.Server.MapPath(&quot;/xslt/Markdown.xslt&quot;));

    //creating xslt
    XslTransform xslt = new XslTransform();
    xslt.Load(xsl, null, null);

    //creating stringwriter
    StringWriter writer = new System.IO.StringWriter();

    //Transform the xml.
    xslt.Transform(xmlDoc, null, writer, null);

    //return string
    text = writer.ToString();
    writer.Close();

    return text;
}</pre>
<p>Download the XSLT file I used from here:</p>
<p><a href="http://symphony-cms.com/downloads/xslt/file/20573/">http://symphony-cms.com/downloads/xslt/file/20573/</a></p>
<p>I would love to hear from anyone that does this differently or if you can find any problems with the method I have chosen to implement for this solution.</p>
<h3>Related Posts</h3>
<p>No related posts.</p>

<p>Related posts brought to you by <a href='http://yarpp.org'>Yet Another Related Posts Plugin</a>.</p>]]></content:encoded>
			<wfw:commentRss>http://www.prolificnotion.co.uk/convert-html-to-plain-text-in-c-using-markdown/feed/</wfw:commentRss>
		<slash:comments>20</slash:comments>
		</item>
		<item>
		<title>SmtpClient does not gracefully close the underlying TCP/IP connection</title>
		<link>http://www.prolificnotion.co.uk/smtpclient-does-not-gracefully-close-the-underlying-tcpip-connection/</link>
		<comments>http://www.prolificnotion.co.uk/smtpclient-does-not-gracefully-close-the-underlying-tcpip-connection/#comments</comments>
		<pubDate>Mon, 02 Nov 2009 10:43:17 +0000</pubDate>
		<dc:creator>Simon Dingley</dc:creator>
				<category><![CDATA[Umbraco]]></category>
		<category><![CDATA[ASP.NET]]></category>
		<category><![CDATA[Tips]]></category>

		<guid isPermaLink="false">http://www.prolificnotion.co.uk/?p=246</guid>
		<description><![CDATA[
			
				
			
		
Some months back Tim Geyssens was kind enough to send me the source for his MailEngine addition to Umbraco before he released it on his blog. I made some customisations to the source to allow users to select templates and changed the filtering options slightly but other than that it worked jut fine for what [...]<h3>Related Posts</h3>

No related posts.


Related posts brought to you by <a href='http://yarpp.org'>Yet Another Related Posts Plugin</a>.]]></description>
			<content:encoded><![CDATA[<div class="tweetmeme_button" style="float: right; margin-left: 10px;">
			<a href="http://api.tweetmeme.com/share?url=http%3A%2F%2Fwww.prolificnotion.co.uk%2Fsmtpclient-does-not-gracefully-close-the-underlying-tcpip-connection%2F"><br />
				<img src="http://api.tweetmeme.com/imagebutton.gif?url=http%3A%2F%2Fwww.prolificnotion.co.uk%2Fsmtpclient-does-not-gracefully-close-the-underlying-tcpip-connection%2F&amp;style=normal&amp;service=bit.ly&amp;service_api=R_e35365ff035ed93fc3e67e6f868b7be3&amp;b=2" height="61" width="50" /><br />
			</a>
		</div>
<p>Some months back <a href="http://www.nibble.be/">Tim Geyssens</a> was kind enough to send me the source for his <a href="http://www.nibble.be/?p=63">MailEngine</a> addition to Umbraco before he released it on his blog. I made some customisations to the source to allow users to select templates and changed the filtering options slightly but other than that it worked jut fine for what I needed.</p>
<p>There was however one problem that became apparent when this was used in production. Sometimes, and apparently randomly the sending of mail would freeze when going to more than say 150 recipients. After a long time trying to track down the reason I stumbled across a post linking to the &#8216;<a href="https://connect.microsoft.com/VisualStudio/feedback/ViewFeedback.aspx?FeedbackID=146711&amp;wa=wsignin1.0">SmtpClient does not gracefully close the underlying TCP/IP connection</a>&#8216; issue on the Microsoft Connect website. I guessed it couldn&#8217;t do any harm to set the MaxTimeout property of the SmtpClient to 1 so I tried it and it seemed to work &#8211; so far so good however you should note the recent comment from someone with regards to using this method on IIS7.</p>
<h3>Related Posts</h3>
<p>No related posts.</p>

<p>Related posts brought to you by <a href='http://yarpp.org'>Yet Another Related Posts Plugin</a>.</p>]]></content:encoded>
			<wfw:commentRss>http://www.prolificnotion.co.uk/smtpclient-does-not-gracefully-close-the-underlying-tcpip-connection/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

