I'm an RIA Developer who owns a motorcycle custom paint shop, who loves to race anything with wheels. I also enjoy woodworking, cooking, fine wines, liqueurs and dark beers. So if nothing else my blog should be eclectic.  
May 13 2008

Site Map Generator: Mango Blog Plugin

Posted by Russell Brown at 1:37 PM
13 comments
- Categories: ColdFusion | Mango Blog | My Projects

I've created yet another plugin for the ColdFusion Mango Blog package. Last night I was suppose to be doing one thing and my ADD kicked in and I did this for some reason.

This new Site Map Generator Plugin will create a sitemap.xml document in your blog's root directory. Sitemaps are supported by search engines such as Google, Yahoo!, Microsoft, Ask.com and Moreover.com and a few more I'm sure at least.

Sitemaps are an easy way for webmasters to inform search engines about pages on their sites that are available for crawling. In its simplest form, a Sitemap is an XML file that lists URLs for a site along with additional metadata about each URL (when it was last updated, how often it usually changes, and how important it is, relative to other URLs in the site) so that search engines can more intelligently crawl the site. -SiteMaps.org

With this plugin, your sitemap.xml will be updated on post and page creation and  update events. All of the work is done in a low priority cfthread just in case you have thousands of posts and hundreds of pages. A settings page is included with this plugin, but is nothing more than a pretty CFDump of your XML file for your verification.

For the next version if requested I may add some more options to the settings page to give you customization on priority per item type and the likes. However I'm pretty sure everyone will be happy with my default prioritization. Right now I map out the index, rss feed, atom feed, each page and each post. I decided to leave out the category viewes as it seemed redundant and I don't think adding them will give you any search engine placement boosts...

Download the ZIP file or view my SVN repository

Update (5/16/08)
I have fixed the ColdFusion 7 issues with both this plugin in the Feed Generator. My apologies for not having it right the frsit time.
Update (6/10/08)
Removed illegal node "created" from sitemap.

 

Comments

Laura

Laura wrote on 05/13/08 2:25 PM

This is something many people have asked for.
Thanks Russell!
Eric Jones

Eric Jones wrote on 05/13/08 2:50 PM

Sweet!!! You use CFThread though so is it restricted to CF8?
Russell Brown

Russell Brown wrote on 05/13/08 2:53 PM

Doh, what was I thinking... I'll fix that tonight and make it work on both.
Russell Brown

Russell Brown wrote on 05/15/08 8:52 AM

I've created a CF7 version of the plugin.

I've also updated the settings page to output a pretty table instead of doing a lazy CFDUMP...
Eric Jones

Eric Jones wrote on 05/15/08 9:37 AM

just tried to install it and i've copied the files to my components -- plugins -- users folder. login to my admin and see it but when i click activate it says it can't activate the plug-in. thoughts.

I'm getting this for the sitemap and feedping plugin.
Russell Brown

Russell Brown wrote on 05/15/08 9:53 AM

@everyone:
I spoke with Eric and it looks like I have an issue with CF7. I will do testing with it tonight and see if I can resolve the issue.
Laura

Laura wrote on 05/15/08 3:00 PM

Hi Russell,
It could be unrelated to the problem with CF 7, but I did notice that somewhere you had the path "blog.components" hardcoded. That will not work whenever people does not have the blog installed in a /blog/ folder. Eric, for example, runs his blog in the root of his site. Most of the time you can get away by using relative locations.
Eric Jones

Eric Jones wrote on 05/15/08 3:35 PM

yep. i changed that in the Generator.cfc and it allowed the plug-in to be activated.

However the feed pinger plugin still won't work and i don't see what's wrong with that code :)
Laura

Laura wrote on 05/15/08 6:26 PM

Eric,
I think Russell is using the new syntax {} to create structures, so that might be the problem if you are running CF 7.
Russell Brown

Russell Brown wrote on 05/16/08 8:12 AM

I've updated the plug-ins so they should all now work for everyone. My apologies for not not QAing in enough environments...
Eric Jones

Eric Jones wrote on 05/16/08 10:34 AM

No worries man! The fact that you created the plug-in is awesome enough! Someday i hope to be creating plug-ins and not just pointing out their flaws...
Russell Brown

Russell Brown wrote on 06/10/08 8:57 AM

I've updated the plugin to to fix the problem with the illegal node. This fix is in 1.0.5 and newer.

Write your comment




(it will not be displayed)








Categories

Monthly Archives

Tech Blogs I Read

Motorcycle Links