Blog Articles
RSS feedGet Node or Node ID by URL
30 Nov 2009
Hi guys
I know I haven't written any articles for a while, this is because I've changed jobs, moved house and been to the land down under for two weeks so I've been pretty busy!
This article; as the title suggests, is a short article demonstrating how to retrieve a node via the URL of a page. This has probably been covered before numerious times, but this is as much a reference for myself.
Moving on, most of you will probably be saying, why not use:
Node.GetCurrent();Well, if you are using lightboxes to display content from a node, and want to use an property from the current node (not the lightbox node) within the lightbox, using Node.GetCurrent() will return the lightbox node.
The first (and most important) part is to get the URL. This can be done by using the Request.UrlReferrer.Segments collection...read more
Umbraco TinyURL Datatype
18 Sep 2009
Once again another short one all. I have developed a custom datatype for use with the Umbraco CMS which generates a shortened version of the page. This datatype send the current page tinyurl.com when the page is saved and saves the returned value as a property.
The value can then be retrieved as in exactly the same was as any other, e.g:
<xsl:value-of select="$currentPage/data[@alias='propertyName']" />So thats it really, download it here or at my projects page at our.umbraco.org....read more
Umbraco problems with displaying Special characters
16 Sep 2009
Just a quick one this. I've been aware of this issue for a while but I've only just acted on it.
Basically with Umbraco v4.0.1 (and possibly others), if you enter a special character such as a degree symbol (°) in the RichTextEditor, the character would be replaced with the dreadful default square character when the page was published.
To get round this, open umbracoSettings.config in the config folder and replace:
<TidyCharEncoding>Raw</TidyCharEncoding>with:
<TidyCharEncoding>UTF8</TidyCharEncoding>
You should now be able to save the special characters...read more
Python Twitter API v1.1 Released
09 Sep 2009
Hi all!
So I've just made a couple of small additions to my Twitter API wrapper recently. Twitter limits the number of requests that a client can request data, as such if my wrapper was used on a high traffic site for example, the limit of requests could be reached very quickly.
I've added caching functionality which saves requested data on a minute by minute basis. E.g. if a request is made where the cached data is older than 1 minute, the data from that request is cached in order for any subsequent requests to use that data rather than many a new request to Twitter. This is beneficial in both allowing your tweets will be shown regardless of the number of requests that are made, and that it also speeds up the process.
The other improvement is the wrapper is now generating hyperlinks around hashtags, user mentions and URLs within each tweet. For an exampl...read more
AutoTags Umbraco DataType
20 Aug 2009
One of my biggest irritations as a web developer is populating web pages with content. Ok, it needs to be done, but it can get a little tedious. One of the more tedious tasks are SEO, and page categorisation. So wouldn't it be good if you could automatically generate keywords that relate to the page content, categories for news articles and tags for blog posts?
With this in mind I have written a Custom DataType for the Umbraco CMS (Version 4) which does exactly this. I've ported Dan Grossman's Open Calais class; written in PHP, to the .Net Framework so it can be used with Umbraco. You can find Dan's PHP class here.
It takes the content from the body of the web page and using the OpenCalais API, generates a list of words which relate to the content. You can then select the words which...read more
Python Twitter API v1
17 Aug 2009
Ok so this is a first on many levels; my first blog post for this site as well as my first project, app, library (call it what you will) that I am releasing into the ether. As the Twitter phenomenon has very quickly gathered speed, more and more people are trying to access its features; whether its pulling in your latest tweets into your webpage or tweeting directly from your desktop! One of the issues which some people are finding is that quite often if their website is hosted by a company, they may not have permission to install libraries, plugins etc for use in their website.
In order to save face, I thought I had better start pulling my Tweets into this site. So I went to download the Python APIs that other developers have written, but they required me to install the packages before I could use them. This is when I t...read more