« Archives in February, 2011

The inverse Sitecore tree

Oh yes, that’s right. I’ve made an inverse Sitecore tree. Despite that it almost certainly will never be of any use to anyone, I’ve made it.

Why? Well, I just thought it would be fun to do. The items that have no children are displayed in a long list, grouped by their common parents. You can expand them to traverse their ancestors. Here’s a screenshot:

Inverse Sitecore tree

Here’s the code (just copy it to a file named InverseContentTreeViewer.aspx):

Inline images from the media library

I’m not sure if this has been done before, but I thought it would be fun to code a ASP.NET control based on the sc:Image from Sitecore. I wanted to create an inline image (based on the Data URI scheme). This could be useful for improving performance in some cases.

I’m not really certain that it is even a useful control in its current form. But it should be easy enough to convert this control so that it can be used in a dynamic CSS file. If you seriously want to use this, check out this page.

Here’s the code:

And if you want to use it in your page, register the control:

And you’ll be able to use it like any Sitecore image (including the MaxWidth and MaxHeight properties):

Hell yeah!

Venn diagram of items in languages

Ever wanted to get a quick insight into how the language versions of your content are used? No? Me neither. But here’s some code to get it anyway.

Just copy and paste the following code to an aspx file in your Sitecore installation and you’re good to go. To make more languages available, just edit the code. The Venn diagram is rendered by the Google Chart Tools.

UA-4216957-1