Home  ›  BLOG  ›  2010  ›  3
Debugging the Umbraco Tag Cloud package
Donnerstag, 18. März 2010, Christoph Ertl

tag cloudDebugging the Umbraco Tag Cloud package would be great. But it’s not possible and not necessary.
However, one thing is really helpful when having problems with the counted nodes. Checking which nodes are counted.

Over time I’ve got repeated mails regarding having problems with counting the nodes. The problem often was a wrong or misunderstood result of the xpath expression. The “problem” with the RenderTags method is, that it just returns a result and you have no glue which nodes where counted.

A very easy way to check if your statements counts the nodes you want to count is the following.

After your code for the cloud

<xsl:value-of
 
select="TagCloud.Helper:RenderTags($currentPage/..., 'categories', '', 6)"

 
disable-output-escaping="yes"
/>

you place a for-each with the xpath statement you pass as first parameter to RenderTags.

<xsl:for-each select="$currentPage/...">
  <
xsl:value-of select="current()/@nodeName"/><br
/>
</
xsl:for-each
>

With this code you get a list of nodes which are calculated within the tag cloud calculator. There you should see where the problem is located.

ATTENTION: It is very important that you place this code at the same template where the tag cloud code is placed because the result depends on the node this template is executed on. It’s all about the hierarchy of your nodes!

Keyboard layout - again
Sonntag, 14. März 2010, Christoph Ertl

Fn

It seems that keyboard layouts are my new favorite topic. Well, it’s really annoying when working with notebooks and searching for keys or pressing some weird combinations because of different positions of keys.

A few days ago I had to work with a notebook with another strange keyboard layout. As I realized afterwards it’s not that unusual on notebooks.

The annoying point about the layout was the position of the Fn key. I’m used to open the Windows menu using the shortcut Strg-Esc (Ctrl-Esc).  On the notebook the most left key was the Fn key instead of the expected Ctrl key. Pressing the Fn key is usually not such a problem. But have a look at the Esc key.

Keyboard layout

So guess what. I shutted down the notebook more than once.