Paul Sterling's Blog

Decisions: 3rd-Party Web Authentication Options

Tuesday, January 06, 2009 by Paul Sterling

A few months back (September 2008) when we set out to create a reference implementation of our content platform based on Umbraco we specified use of a 3rd-party authentication system.  At that time the most viable option, in my opinion, was Microsoft’s Live ID Web Authentication offering.  And that is what we used for our beta releases.  It was ready, it worked, and it was straightforward to implement.  You can see it in action on our planetmold.com site – super simple.

Since then Facebook Connect, Google Friend Connect, Google’s Federated Login, and Microsoft’s Live ID Delegated Authentication have all launched.  In addition OpenID has gained even more momentum with both Google and Microsoft committing to being OpenID Providers – and AOL and Yahoo! were already providers.  Finally, JanRain launched their RPX service that simplifies the offerings of multiple authentication providers into a single ‘login’ form.  I expect there are others who offer, or will soon offer, a similar service. 

The decision now is really which provider to use? 

It seems to me that RPX is a clear choice, except for the fact that it introduces a potential point of failure.  On the plus side, once Microsoft turns on their OpenID Provider Service it should “just work” with the RPX service.  Essentially, then, RPX will offer virtually all 3rd-party web authentication options – that’s 100s-of-millions of accounts.

Other than RPX, Facebook Connect and Google Federated Login seem to have the most traction (based on the number of accounts).  We’ve created a proof of concept using Facebook Connect and can attest to the fact that this implementation is quite straightforward.  Google Federated Login subscribes to the OpenID 2.0 Directed Identity protocol, so we expect implementation to be straightforward for this as well.

At the time of this post we’re moving to RPX for our platform’s web authentication.  I will create a post detailing the implementation process for RPX once that’s complete.

Assuming you’ve read this far – which would you choose?

-Paul

LG Washer Dryer Drama – DIY Fix

Monday, January 05, 2009 by Paul Sterling

NB:  this post is a departure from my usual focus on technology as I delve into DIY appliance repair.  If you’re looking for just the How To Fix Your LG Washer Dryer without the background, see below.

In April 2007 we purchased an LG Washer – Dryer combo appliance (WM3431HW) after looking for a solution to our laundry space constraints.  The year before we had moved into a downsized home and were looking to downsize our appliances as well.  From the very beginning we were thrilled – as much as you can be when it comes to laundry at least.  It was short-lived. 

Even before the one-year warranty had expired the unit stopped drying clothes properly and a few days later the auto-dry setting stopped working altogether.  We called LG and they referred us to a local appliance repair service.  A few days later the service technician arrived (his appearance didn’t inspire a great deal of confidence) and proceeded to give me a lecture on how to clean the lint from the unit – something we’d been doing all along.  After cleaning the lint he could, he declared it fixed and left.  It wasn’t fixed.

After several more visits from the same service technician (at least he stuck with it) and replacing a pump, a sensor, and the main control board (twice) the unit began working as expected again.  This took a full-month and four visits and resulted in numerous scratches to the unit and to the (new) laundry room floor; not to mention a month without a functioning dryer.  We live in Bellingham, Washington where hanging clothes out to dry in May is not a viable option due to the rain.

In November of 2008, scarcely 6-months after the prior repairs had been completed, the unit began exhibiting the same behavior as before with the auto-dry setting not working.  This time I immediately called LG where they informed me that they would be unable to fix the unit as the warranty had expired.  They had a record of the prior issue and resolution but refused to acknowledge that this was the very same issue and the unit had not been repaired properly.  They were very kind and apologetic but utterly useless.  As we had purchased an extended warranty when we purchased the unit I called the extended warranty provider and left a message as requested (thrice), I have not yet heard back from this provider – four-weeks and counting. 

After four-weeks of damp clothing I became frustrated enough to try and determine the cause myself – along with some strong encouragement from my wife.  I had seen the service technician access the inside of the unit and knew that it was quite simple to open the unit.

The short-version is that the design of the unit is such that lint build-up inside an internal component obstructs the dryer’s airflow to the extent that the drying function is reduced and the unit’s logic board incorrectly reports the clothes as being dry, even when they are not. 

 

How to Fix Your LG Washer – Dryer Combo When The Dry Function is Not Working

I am not an appliance service technician, referenced no official guides, and used no special tools to accomplish this repair.  That said, you are on your own here if something goes wrong – good luck! 

  1. Turn off the water and unplug the unit
  2. Remove the top cover – 2 screws at rear
  3. Remove the interior cover – screws around perimeter
  4. You should see this:
    1. IMG_2333
  5. Locate the air return/lint drain
    1. Vertically oriented plastic component below the blower housing
  6. Unclamp the water supply hose – see below
  7. Remove the heat sensor from air return – see below
  8. Unscrew the blower unit
    1. You may want to clean the blower fan of lint while you’re at it – it’s under the white cover
    2. The seal between the blower unit and the washer drum had disintegrated on my unit, I ordered a replacement from here.
    3. overview
  9. Lift off the blower unit and carefully set aside
  10. From the rear of the unit unscrew the air return
    1. There is one screw which is accessed from the shipping lock hole – it is awkward but keep at it and you’ll get it
  11. Clean and/or rinse the air return to remove any lint – I found about a softball sized clump
  12. Re-assemble in the reverse order, plug it in, turn on the water
  13. Wash and DRY your clothes again

Let me know if this worked or didn’t work for you and let LG know too!

-Paul

Do Web Developers Need SQL

Friday, January 02, 2009 by Paul Sterling

In 2002, when I first interviewed at Microsoft one of the questions I was asked was “how would you delete duplicate rows from a [sql] database table?”   I don’t actually recall what my answer was and I don’t suppose it much matters as I was hired by Microsoft soon after the interview – though I am no longer employed by Microsoft.  For seven years, give or take, I haven’t had occasion to consider this question a second time, until today.  Naturally, I almost immediately performed a web search and located at least five different methods for deleting duplicate records…I’m sure there are many more than five.  A Microsoft KB article suggested what seems a robust but rather involved solution, and most others are a variant on this.  In the end, as before, Pinal Dave came through with a straightforward solution that accomplished exactly what I wanted – shown here:

DELETE
    FROM   someTable
    WHERE    Id NOT IN
    (
    SELECT    MAX(Id)
        FROM        someTable
        GROUP BY    someDupColumn, anotherDupColumn)

If you follow my blog or Twitter feed you no doubt know that I go to some lengths to avoid writing SQL – namely by using the SubSonic ORM.  To be fair, I still use SQL databases (MSSQL and MySQL) and have not jumped to an alternative such as Amazon’s SimpleDB or Microsoft’s Azure Data Storage.  While I prefer SubSonic, even Microsoft has gotten into the ORM space with LINQ and there are many other solutions here as well.  Disclaimer:  I was once a Certified Oracle Developer and have created more than a few apps where the business logic was contained almost completely in stored procedures – those days are over, thankfully.

In my opinion, as a web developer, I do not need to rely on a deep SQL knowledge any longer.  With the above mentioned technologies, highly-usable database administration UI’s, and a basic grasp of good data design I believe web developers can be freed from ‘having’ to use SQL.  What a relief!

For a recent app that’s fairly data intensive, though quite simple, I used no SQL and only SubSonic to interact with the MySQL backend.  The most complex ‘query’ in the app is as follows:

ListingDetailCollection listings = new Select().From("ListingDetail")
.Where("target").In(new Select("code")
    .From("ListingZip").WhereExpression("Latitude")
    .IsLessThanOrEqualTo(HighLatitude)
    .And("Latitude").IsGreaterThanOrEqualTo(LowLatitude)
    .And("Longitude").IsGreaterThanOrEqualTo(LowLongitude)
    .And("Longitude").IsLessThanOrEqualTo(HighLongitude))
.ExecuteAsCollection();

And that’s it – reduced to a few lines, in-line with the business logic, and using the same conventions as C# in general – makes it easy to create, debug, and annotate.  I hope I can encourage others I work with this year to move away from SQL to SubSonic (or LINQ, etc…)  as well.  It has the potential to increase productivity, quality, and sophistication.

Let me know what you think.

-Paul

Umbraco XSLT Extension for SEO

Thursday, December 11, 2008 by Paul Sterling

Of late, I'm a fan of XSLT Extensions in Umbraco.  They are an extremely useful feature of Umbraco that span the .NET and XSLT gap I've seen often.  To give credit where it's due - Per Ploug Hansen is really the one who showed my the light in terms of XSLT Extensions at Codegarden US 2008.  Thanks!  In fact, one of my ongoing efforts is refactoring the Commerce for Umbraco UI layer to use XSLT Extensions rather than ASP.NET User Controls - I think this will allow a much slimmer implementation of this commerce project for Umbraco users.

I've had need to create unique HTML meta tags (title, description, keywords) for nodes generated from non-Umbraco data several times recently and have come up with the following approach - using XSLT Extensions, SubSonic, and a simple C# class.  In one case the generated nodes are listings (http://www.planetmold.com/professional-listings/Los%20Angeles-Long%20Beach-CA.aspx) where the data key is a unique string [Los Angeles-Long Beach-CA].  Using Url Rewriting I create a unique Url -the first step in my SEO routine here.  Also, using the data key I retrieve our data records and generate the unique HTML meta content. 

How does this work?  Simple, but there are a few parts to keep aligned.  The code below is shown front to back (in Umbraco terms).

1 - In the Umbraco template set the macro parameter guid to use the querystring parameter p using the shorthand notation [@] to retrieve the querystring:

<?UMBRACO_MACRO macroAlias="ProductMeta" guid="[@p]"></?UMBRACO_MACRO>
 

2 - Create the macro parameter guid in the macro ProductMeta

macro-parameter

 

3 - Make an entry in your xsltExtensions.config file to register the extension

<?xml version="1.0" encoding="utf-8"?>
<XsltExtensions>
...
  <ext assembly="/bin/xsltextensions" type="commercexslt.productmeta" alias="meta" />
...
</XsltExtensions>

 

4 - Create the corresponding macro XSLT (simplified here)

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE xsl:stylesheet [ <!ENTITY nbsp "&#x00A0;"> ]>
<xsl:stylesheet 
    version="1.0" 
    xmlns:xsl="http://www.w3.org/1999/XSL/Transform" 
    xmlns:msxml="urn:schemas-microsoft-com:xslt"
    xmlns:umbraco.library="urn:umbraco.library"
  xmlns:meta="urn:meta"
    exclude-result-prefixes="msxml umbraco.library meta">

<xsl:output method="html" omit-xml-declaration="yes"/>

<xsl:param name="currentPage"/>
<xsl:variable name="productGuid" select="//macro/guid"/>
<xsl:variable name="description" select="meta:MetaDescription($productGuid)"/>
<xsl:variable name="keywords" select="meta:MetaKeywords($productGuid)"/>

<xsl:template match="/">

  <title><xsl:value-of select="meta:MetaTitle($productGuid)"/></title>
  <meta name='description' content='{$description}'></meta>
  <meta name='keywords' content='{$keywords}'></meta>

</xsl:template>
</xsl:stylesheet>

 

5 - Create the C# class to get the data (yep, simplified again)

using System;
using System.Collections.Generic;
using System.Text;
using SubSonic;

namespace commercexslt
{
    public class productmeta
    {
        public static string MetaTitle(string ProductGUID)
        {
            Guid _productGUID = new Guid(ProductGUID);

            // returns an ActiveRecord class which wraps the ProductMeta table
            c4uXslt.ProductMetum title = new c4uXslt.ProductMetum("productGUID", _productGUID);

            if (title.HtmlTitle.Length != 0)
                return title.HtmlTitle;
            else
                return "the default title";
        }

        ...

Note that I'm using SubSonic to access my data source - you may choose that method or any other that works for you.  The important items to note are:

1 - I return a string type

2 - The method is marked public static

6 - Just for completeness, the underlying content table looks like this

product-meta-table

That's it! 

Now, when the node renders based on the querystring parameter we generate not only the correct data but also unique HTML meta content.  And, since this data is SQL-based and managed separately from Umbraco we don't need to worry about keeping nodes in sync with external data.  Also, since we're dealing with 15,000 unique records and related content this approach ensures we have unique content for each data item - an important SEO consideration.

-Paul

Umbraco Content Search and Replace in Table cmsContentXml - MSSQL2005

Tuesday, December 02, 2008 by Paul Sterling

Have you ever needed to do a large scale search and replace for Umbraco content?  Yeah, me either - until today.  Typically with SQL I'd use a Replace() statement to update the content.  However, Replace() won't work with the NTEXT data type - which just happens to be the data type of the xml column where Umbraco content is stored.  I created the below script to accomplish the search and replace and ran it against content for http://www.planetmold.com and voila!

Grab the SQL script here:

As always, no warranties are implied - you're on your own.  Please let me know if you have improvements.

-Paul

Umbraco in the Age of VC Funded DNN

Saturday, November 29, 2008 by Paul Sterling

Earlier this week DNN announced they had closed a round of VC funding from Silicon Valley VC's.  My first response, and that of many others, was 'why?'  To me, at least, capital funding for an open-source project that is in the CMS space (which has many legitimate competitors) targeted at 'increase DotNetNuke adoption' doesn't makes sense.  It's no secret that the DNN project is saddled with legacy code and not on par with other open-source CMS projects - from an architecture and standards perspective.  However, DNN does have a relatively large community (~600k) and a large (have) installed base.  [NB:  anecdotes suggest many users 'have' used DNN but no longer do.  I am in the 'have' used group myself.] 

I do, however, share a similar view with DNN on the value of an open-source project's community.  This is really the essence of monetizing open-source.  So while the DNN project itself may never be a commercial product (well, in some ways it will,  there will be a 'professional' license available) the community of DNN users will need all manner of 'additional' products - support, services, modules, etc....  And this DOES have real commercial value.  In fact, there is already a booming market for 3rd-party DNN products - something the DNN Corp is working on capturing a larger share of with their DNN Marketplace.  [NB:  snowcovered.com seems to be the main player here.]

So DNN is not forging any new ground here and, in fact, this may be precisely what led to the funding justification.  This same road has been traveled successfully by other open-source projects before - Drupal, Joomla, Wordpress, etc....  But can DNN do it - 'it' being generate a significant return on the capital infused - with this model given the Microsoft Platform alignment?  Maybe, I hope so for DNN's sake and for the larger open-source on Microsoft community.

For the record, let me be clear that I wish DNN success with this endeavor but I do not think this is the best path to take if your goal is to monetize an open-source project.  There is simply too much overhead to be accommodated which detracts from the core task of creating great software that is easy to use and solves at least one fundamental problem.  I hope that Umbraco never goes this way and I never intend to take either of my companies this way.  [NB:  yes, I know it's easy to say when I'm in the position I am.]

What does this mean for Umbraco?  Not much really.  Umbraco will continue to do what it does best - create great software that is easy to use and solves some fundamental problems.  And we, the Umbraco community will continue to grow in number and dedication.  We already have some traction on the fundamentals: an organized, enthusiastic, and involved community; a nascent marketplace for 3rd-party products; a sustainable revenue model for core development; and a growing number of high-profile, large-enterprise successes. 

-Paul

PDC 2008 Wrap Up

Friday, October 31, 2008 by Paul Sterling

I'm headed home and am in a tired sort of jelly-like state after 4-days at PDC 2008.  I went in with high expectations and came away with those expectations mostly met - for the first time in my relatively long career of attending conferences.  Umbraco Codegarden is the notable exception - these rock!

All in all I'm impressed and thrilled with the direction of the Azure Services Platform and believe this has enormous potential.  If you've read my blog posts over the last year you've no doubt noticed that I'm an enthusiastic booster of cloud computing in general.  To me, the offerings from Microsoft evolve the platform to a more approachable level and open the door to additional opportunities.  I don't know if Microsoft's platform will be the "best" platform in the end, but at this point it is the most real platform.  Obviously, if you're looking for simple cloud computing virtual machines you have many viable choices - Amazon AWS and GoGrid to name a few.  Interestingly, there was only passing reference to this type of virtual machine resource from the Azure Services team.  I'm still not clear if this is part of the offering.

I had many terrific conversations with fellow attendees and Microsoft attendees/speakers.  I don't think I'll be at PDC 2009, but who knows.  The breadth of technology covered at PDC is tremendous...I think a year to digest, process and implement the most compelling items after evaluating how they fit into/disrupt the current technology stack is barely enough time.  I expect PDC 2009 will be focused on Windows 7/Server 2008 R2 - certainly important technologies.  I am, however, planning on attending MIX 2009.

Following is my take on the best and worst of PDC 2008, it's one person's experience:

Best Sessions

  • Asp.Net MVC Framework (PC21) video
  • Making your app more Social (BB20) video
  • A Lap Around Live Services and Live Mesh (BB04) video
  • The Future of C# (TL16) video

You can see all of the sessions and videos here.

Highlights

  • The 'aha!' moment with regard to the elements of the Live Framework/Live Mesh/Azure (formerly known as Strata).
  • Sketching a conceptual design for a distributed Umbraco cache with the project Velocity team
  • Making my first Mesh App and actually seeing it run in Live Mesh and on my laptop
  • Learning that Live ID will be a provider for OpenID authentication
  • Getting a better understanding of Microformats and the available tools

Lowlights

  • Keynotes - I find it hard it to believe that the keynotes are for the developers in attendance and not for broader media/investor appeal.  While the keynotes do help set the context for the rest of the conference, they are (in my opinion) hugely disappointing.
  • I saw no public presence of any of the very cool open source support initiatives from Microsoft (CodePlex, Web Application Installer, etc...).  It's possible that I just missed these given that scale of the PDC, but I was disappointed at the lack of visibility.

See you at MIX 2009 and/or Umbraco Codegarden 2009.

Umbraco on Amazon Web Services

Thursday, October 23, 2008 by Paul Sterling

Today Amazon launched the public beta allowing Windows Server 2003 instances on the Elastic Computing Cloud - something they announced a while back and that we've been asking for.

Amazon is applying their simple 'pay as you go' model with the default instance being $0.125 per hour ($3.00 per day).  The default instance is specified as 1.7 GB of memory, 1 EC2 Compute Unit,160 GB of instance storage, 32-bit platform.  This runs an IIS server nicely.  There are also larger instances available, including 64-bit and SQL Server.

If you saw my talk at Umbraco Codegarden US you saw a demo of Umbraco running on an IIS server at GoGrid with a MySql server running at Amazon.  Now one can create Linux and Windows instances at both Amazon and GoGrid - like apples.

GoGrid has a clear advantage in terms of a friendly management interface.  Amazon provides a command line interface, though third-party tools such as ElasticFox do help a bit.

Not being one with much patience I have already started a Windows instance at Amazon and have installed Umbraco with SQL Express.  The process took 15 minutes or so - not bad for a first go.  As soon as Umbraco v4 Beta 2 is available I will create a public AMI with Umbraco installed and ready.  All you'll need to do is start the instance, navigate to the public DNS name, and Umbraco will be available.  Instant gratification - which I favor.  I'll post the AMI link here and you'll also be able to find it in the public AMI list from Amazon.

With Microsoft's PDC coming up next week in LA it'll be interesting to see what they unveil in terms of offerings similar to Amazon and GoGrid.  I'll be at PDC and will post here as soon as I know.

Codegarden US Wrap Up

Wednesday, October 08, 2008 by Paul Sterling

The feedback is that the first US Codegarden was a huge success.  With about 30 participants it was two days packed full of learning, sharing, and fun.  Umbraco v4 highlighted by Niels and Per in the opening keynote set the tone with Umbraco firmly established as a robust CMS up to any task.  We had sessions on topics ranging from using Flash with Umbraco, to running Umbraco on cloud-based computing platforms, and lots of great demos, discussions, and coding sessions.

Our Open Space sessions were well attended and the participation from all attendees was fantastic.  We've created a book to hold the session output here.

A tradition at Codegarden is the package coding contest.  We had entries ranging from an XSLT-extension for Commerce for Umbraco (the package also known as XSLT-Error) to complete site packages aimed at getting an Umbraco site running in just a few minutes.  John took home the XBox prize for his node-based form generator.

A huge thanks from me, and all the Codegarden organizers, to everyone who came and participated.

See you at Codegarden in 2009!

-Paul

Business Advice for Geeks - from Mark Hedlund

Monday, September 22, 2008 by Paul Sterling

A month ago I attended the Start Conference where, among others, Mark Hedlund talked about his view on start-ups and gave some (sage) advice.  Mark has a real knack for brevity and focus in his message - this was no exception.  So, according to Mark, there are five essential guidelines to always keep in mind:

 

  1. Do the idea that won't leave you alone (what keeps you up night)
  2. Only work with people you like and respect
  3. A cool idea is not a business - a great need is
  4. The best way to get investment is not to need it
  5. 'No' means maybe:  'Yes' means maybe

 

I believe I have, for the most part, kept these guidelines in mind as I've been building Motus Connect during the last year.  And I believe the result has been a more robust and more sustainable company than it would have been otherwise.

-Paul

Bellingham Summer - Rambling in the North Cascades

Monday, September 15, 2008 by Paul Sterling

As summer winds down here in Northwest Washington state (aka, Republic of Cascadia) we have been making forays into the mountains to the East - the North Cascades.  These hills (sic.) are home to the relatively famous Mounts Baker and Shuksan, among countless others.  Two weeks ago we were at Artist Point and this Saturday we hiked up Welcome Pass to Excelsior Ridge.

Of all the things that make Bellingham the place I want to be, these hikes into the hills and the accompanying vistas are the reason that I can't consider leaving here.  Below are my favorite shots from the last two weeks - now back to work!

09132008 056

(above)  Mount Shuksan and Mirror Lake

09132008 085

(above)  Mount Baker from Excelsior Ridge (High Divide)

Codegarden US Videos

Tuesday, September 02, 2008 by Paul Sterling

Bob Baty-Barr, Doug Robar, and me have created some brief video snippets explaining why we're excited about Codegarden US this year.  It's rumored that Casey Neehouse and Niels Hartvig also have videos coming up.

You can watch the videos here.

And, the Codegarden US organizers have graciously extended the Early-Registration Discount to 4 September - so head over and get registered if you're not already.

-Paul

Why I'm So Excited about Codegarden US

Friday, August 29, 2008 by Paul Sterling

We were talking earlier this week about some of the new Umbraco v4 features and the progress the Core Team is making implementing very cool stuff like live editing!  Got me thinking about how excited I am about Codegarden US in Chicago - coming right up on October 6-7.  Here's a 90-second snippet that explains.

We have a good number of attendees already confirmed but there's definitely room for more.  Head over to the Umbraco Codegarden US mini-site and get signed up.  The "early-bird" discount ends on Monday September 1.

-Paul

Show Off at Codegarden US

Tuesday, August 19, 2008 by Paul Sterling

At Codegarden US this year we're pleased to host a Show Off!  If you have something cool to show, such as:

  • Umbraco Package
  • Umbraco Nitro
  • Umbraco Site
  • Umbraco cool tip or skill
  • Umbraco popcorn maker
  • A cool gadget you made
  • Some Umbraco related art
  • A poem about Umbraco
  • ...anything else you want really...

 

Create a video, a slide desk, a document, an image, etc... that illustrates your Show Off (no more than 3-minutes) and send it our way.  You get full credit and retain all rights.  You'll have the same 3-minutes at Codegarden to Show Off - using your video or 'live!'

 

The idea is that anyone who wants to can show what they're proudest of and the rest of us (the community) will get to cheer you on.  There will be prizes, of course!

 

If you have something you're proud of that you want to show off, here are a few things you need to do:

  • send us an email with the following information
    • Your name and any other names of people who get credit
    • Your company - if you have one
    • A brief description of your Show Off item
    • Info on how we can get to your video/doc/image
      • FTP, Share, etc...
    • Can we use your Show Off before Codegarden?
    • send to:  cg-showoff@live.com

 

Looking forward to seeing you in Chicago!

-Paul

Codegarden08 US Set for October 6-7, 2008

Monday, August 11, 2008 by Paul Sterling

Time to get excited!  If you thought Codegarden08 in Copenhagen was good, wait until you experience Codegarden08 US.  The US version of Codegarden is scheduled to include the same astounding presenters - Niels Hartvig, Per Ploug Hansen, and others.  We have secured a terrific venue at The Illinois Institute of Technology in central Chicago, IL.  The venue is literally just minutes from Midway airport and has it's own train stop for both the Red and Green lines. 

 

The registration site is up, go get registered:  http://umbraco.us/

 

Discount hotels are available here (mention you're requesting the IIT rate).

 

By the way, Codegarden08 US is not limited only to US attendees.  We welcome attendees from around the world.  As a bonus for non-US attendees, the US dollar has rarely been weaker and you may find that traveling to Chicago, IL is a terrific bargain.  It's like getting a Codegarden08 US discount!

 

If you're interested in presenting at Codegarden08 US, please let Douglas Robar know via the contact form on his website.  We're open to all suggestions and presenters get free admission.

 

Looking forward to seeing you all in Chicago.

-Paul

Beautiful Word Tag Clouds

Monday, August 04, 2008 by Paul Sterling

Wordle is a toy, but it creates beautiful images if word clouds.  Here's my blog according to Wordle:


And here is the Umbraco Blog:

 

Perhaps beauty is in the eye of the beholder.

-Paul

Multiple Instances of a Macro in a Single Umbraco Template

Thursday, June 26, 2008 by Paul Sterling

I assume it's not an uncommon requirement to include multiple instances of a macro in a single template, but I hadn't encountered it until this week.  In this case, a new site design dictated including multiple category listings on a single page.  The problem was that our category listing controls were designed to render a single category listing determined by a query string parameter - though it doesn't look this way due to a Url Rewriting Rule. 

I borrowed a solution put forward by David Conlisk in this forum post termed "Resource Nodes."   In essence what I've done is to create non-visible content nodes to contain the data used by the visible node.  I simply added the properties I needed to the underlying Document Type.  Again, I'm certain this is not an uncommon approach to Umbraco configuration and has the added benefit of providing a consistent model to our site editors.

Following is a snippet from the Template underlying the visible Content node where the Macro parameter resourceNode is of the MediaPicker Data Type and the parameter ResourceNode is of the ContentPicker Data Type.  When adding the Macros to the Template the creator simply selects the relevant Media node (for the Random Image Macro) and Content node (for the Category Listing Macro).

 

<div class="prodImage">
    <?UMBRACO_MACRO macroAlias="GetRandomImage" resourceNode="2211">
    </?UMBRACO_MACRO>
</div>

    <?UMBRACO_MACRO macroAlias="categoryList" ResourceNode="2545">
    </?UMBRACO_MACRO>

<div class="prodImage">
    <?UMBRACO_MACRO macroAlias="GetRandomImage" resourceNode="1813">
    </?UMBRACO_MACRO>
</div>

    <?UMBRACO_MACRO macroAlias="categoryList" ResourceNode="2543">
    </?UMBRACO_MACRO>

 

For a straightforward example of a Random Image Macro have a look at this forum post.  Mine is implemented as a .NET User Control, but I think the XSLT solution is a bit more elegant.

From here each Macro (.NET User Controls) retrieves the relevant configuration information from the specified ResourceNode and renders accordingly.  Following is a snippet of the public property definition and usage from the User Control.

 

...(we create a public property to hold the NodeId)...
 
       private int resourceNode = -1;

        public int ResourceNode
        {
            get { return resourceNode; }
            set { resourceNode = value; }
        }
 
...(and then we get the value(s) from the related Node)...
 
            Node pageNode = new Node(resourceNode);
            categoryID = int.Parse(pageNode.GetProperty
                ("categoryID").Value.ToString());

 

In this manner I can add any number of instances of the same Macro to a Template and allow site editors to have control over the order and content of each Macro. 

As always, input on a better approach is welcome.

CodeGarden08 Wrap Up

Thursday, June 05, 2008 by Paul Sterling

Whew!  The last 5 days have been extremely full and extraordinarily productive.  My head is full of new ideas and items to consider.  The energy and intensity of the Umbraco Core/MVP group is almost overwhelming and the passion for Umbraco and all the possibilities it affords are apparent in the community.

The community response to the newly introduced commercial aspects of Umbraco were surprisingly well received.  The new Umbraco Store is bound to see a stream of product listings in the next several months.  Also, the general response to the current state of the Commerce for Umbraco project was quite positive and we added 3 contributors to the project this week.  That's the best possible outcome I could've hoped for!

Here are a few links to other CodeGarden08 sites:

http://umbraco0008.web05.fab-it.dk/

http://flickr.com/photos/tags/codegarden08/

http://umbraco.org/documentation/books/codegarden-2008

It was an incredible event and I can't wait until next year!

Commerce for Umbraco - Beta1 Released

Friday, May 23, 2008 by Paul Sterling

We've wrapped up the Beta1 version of Commerce for Umbraco.  It's ready for your evaluation and/or usage.  Feel free to give it a go!  I paid particular attention to the installer routine since this was one of the most-often cited issues from the preview releases.  While it's far from a one-click install I think you'll find that it's not difficult.  To that end I recorded a 7-minute long screencast of the install process.  You can get it from here (no audio, sorry):

I've also placed it on YouTube but the quality is quite poor.

You can download the latest Commerce for Umbraco release here.

The project's home page remains here.

As always, please let me know directly or create issue at the CodePlex site.

-Paul

Umbraco is CodePlex Top 10 - And 3.1 isn't even out yet!

Thursday, May 22, 2008 by Paul Sterling

The momentum around Umbraco continues to build.  This morning I noticed that Umbraco was number nine in terms of downloads on CodePlex.  Can't wait until the 3.1 release is out!

-Paul

Commerce for Umbraco as a Marketplace

Monday, April 28, 2008 by Paul Sterling

I haven’t written much about my motivation for creating the Commerce for Umbraco project but I think it’s time to highlight one of the core goals for this project. Aside from enabling commerce from with an Umbraco installation, the Commerce for Umbraco project allows the creation of Marketplaces. By Marketplace I mean allowing any number of sellers to offer any number of products via a common interface. (Think Amazon.com marketplace.)

This differs significantly from the single seller model and is (we believe) an area lacking in the open-source space (well, in the commercial space as well). In fact, if you look at the licensing models for most commercial web commerce products you’ll notice that a license typically corresponds to a single domain. If you have five-brands (and five-domains) you’ll need five-licenses.

Commerce for Umbraco is running in the Marketplace scenario at both Homax (googone.com, blackflag.com, gonzocorp.com, etc…) and at the Motus Connect Store (and soon at the Umbraco Store). Obviously the above is two different approaches, but the code base is identical.

We are doing our best to stick to the Beta release of Commerce for Umbraco at Codegarden’08.

-Paul

Commerce for Umbraco - Preview 1 Build 4 Complete

Wednesday, April 23, 2008 by Paul Sterling

The latest build (Preview 1, Build 4) of Commerce for Umbraco is nearly ready for (gasp!) Beta.  We've included all the defect corrections (about 250!) we've come across while putting together the Motus Connect Store and also a preview site for Jonas Bohlin of Jobolito

Also, we've accomplished a much improved PayPal integration which supports all of the PayPal currencies via either Direct Pay or Express Checkout.  (BTW - I completed my PayPal certification and am now a PayPal Certified Developer!)  Finally, we've further streamlined and further enhanced the checkout routine to catch and recover from more of the most common errors. 

We hope to have Beta 1 ready before Umbraco CodeGarden08 - which gives us just about 5-weeks.  The Beta release will (must) include an Umbraco package to get potential users up and running quickly without having to mess with copying files, running SQL scripts and the like.

As in the past please send us your feedback and/or create an issue on the Code Plex site.

Motus Connect Store for Umbraco Products - Launched!

Sunday, April 20, 2008 by Paul Sterling

We quietly launched the Motus Connect Store last Friday night (may have actually been Saturday morning unless you're in Hawaii) and then spent the weekend making refinements and working through a quirk with cross-currency payment handling with PayPal.  (Thanks to Graham Rupe from PayPal for help).  As it stands now the store is fully-functional with all the planned security in place and ready for business.    Until we resolve the PayPal cross-currency issue we've opted to offer listed prices only in USD, I fully expect to support our full-list prior to the end of the week.

Over the last two-weeks we've had several vendors sign-up but no actual products listed for sale yet.  So, if you have an Umbraco package, extension, of documentation please create a vendor account and list your products so the Umbraco community can start benefiting.  As I've said previously, having an eco-system of products, vendors, and solution providers is vital to broadening the adoption and further legitimizing Umbraco in the Enterprise.  If you have any questions please send us an email at any of the listed contact addresses and we'll get right back to you - thanks.

Here's the store home page.

Here's a sample product listing.

-Paul

Motus Connect Store for Umbraco products - open for vendors!

Thursday, April 03, 2008 by Paul Sterling

We've completed Phase 1 of the Motus Connect Store for Umbraco and it is now available to anyone in the community who has Umbraco related packages, extensions, components, documents, books, or other digital assets that relate to Umbraco they wish to offer for sale. 

http://store.motusconnect.com/

We've been working over the last four months to refine the concept and approach for the Motus Connect Store and feel we have met our primary objective in keeping it simple.  While we have the purchaser features of the store complete we wanted to hold off just a bit and allow vendors some time to register, investigate the site, and answer any questions that may arise.

The Motus Connect Store will act as a precursor to the 'official' Umbraco Store to be launched at a later date - see the site FAQ for more on this. 

As I've written and mentioned previously, every sale from the Motus Connect Store will include a 10% contribution to the Umbraco Core Team to help support the best open source project on Microsoft .NET.  More than anything, we want to see Umbraco and the Umbraco community succeed in a big way.

Phase 2, which includes the release of the browse, purchase, download feature set is due on or before 18 April 2008 - so stay tuned.

Please send your feedback our way at info@motusconnect.com.

I'd like to offer our sincere gratitude to the Umbraco Core Team for their excellent work on a platform that allows us build out a site like this.  In addition I'd like to thank Chris Cyvas, of dashCommerce, for all his work in keeping dashCommerce going and providing a great starting place for robust web commerce.

-Paul

Syntax Highlighting in the Umbraco Admin Back end - XSLT, CSS, HTML

Monday, March 10, 2008 by Paul Sterling

Now that I have more than a single "webmaster" interacting with the Umbraco Administration UI I've found that the plain-text display of the source in the XSLT, CSS, and Template editors has been a source of some frustration.  Relative to other webmaster tools, such as Visual Web Developer Express, the lack of formatting and highlighting tends to slow-down these folks.  In the course of looking for solutions I came across an older post from Per Ploug Hansen on just this topic.  His solution (originally suggested by Ismail Mayat) is to apply the EditArea editor from Christophe Dolivet to the editXslt.aspx page. 

This has been so well received by my folks that I thought I'd create this simple how-to:

 

  • Download the EditArea archive here
  • Extract the archive to your Umbraco install
  • ...<your umbraco root>/umbraco/js/editarea/...
  • Edit the the Umbraco files by adding a reference to the required script as follows in the <head> section
  • For the XSLT editor:
  • ...<your umbraco root>/umbraco/developer/editXslt.aspx
  • <script language="javascript" type="text/javascript" src="../js/editarea/edit_area/edit_area_full.js"></script>
  • For the Stylesheet editor:
  • ...<your umbraco root>/umbraco/settings/stylesheet/editstylesheet.aspx
  • <script language="javascript" type="text/javascript" src="../../js/editarea/edit_area/edit_area_full.js"></script>
  • For the Template editor:
  • ...<your umbraco root>/umbraco/settings/editTemplate.aspx
  • <script language="javascript" type="text/javascript" src="../js/editarea/edit_area/edit_area_full.js"></script>
  • Then, in the <head> of each file add this script:
  • <script language="Javascript" type="text/javascript">
    // initialisation
    editAreaLoader.init({
      id: "editorSource" // id of the textarea to transform
      ,start_highlight: true
      ,font_size: "8"
      ,allow_resize: "no"
      ,allow_toogle: false
      ,language: "en"
      ,syntax: "html"  //change to CSS for stylesheets
      ,toolbar: "search, go_to_line, |, undo, redo, |, change_smooth_selection, highlight"
    });
    </script>
  • Save the files, and you're done

 

Here's what it looks like in the Template editor...note the nice color-coding, line-numbers, and current line indicator.

 editarea

 

That's it.  I notice a small delay when the pages first load but in this environment, Administration, a bit of a delay is insignificant.

-Paul