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.  

Category: ColdFusion

Jun 20 2008

FireFox 3 has Infinet Loop Protection

I had to write a conversion utility to move an old database contained a few hundred thousand records from MySQL to MSSQL, making the structure more normalized and running some calculations, bla bla bla. In my need to bang this out quickly and since it was a one time throw it away app I wrote a quick ColdFusion script to do the transformation for me and save some time.

I decided to run in blocks and do a CFLOCATION at the bottom of the page, essentially creating on the fly pagination of my work.

Well as an FWI for developers, if FireFox redirects too many times you get a nice phat error... Not really a huge deal and nothing we ever have to worry about with a normal application; but this is something I had never run into before having always been an IE guy before FF3 beta...

1 comments - Posted by Russell Brown at 3:16 PM - Categories: ColdFusion | Debugging | Development

Jun 16 2008

Transfer: <property> and <manytoone> don't play well together

Last week I started a new project and I decided to use Transfer-ORM. So far I've been happy with it's offerings aside from one severe headach my limited knowledge on the product has created. In my database I have multiple depths of linking, I would like to leverage the <manytoone> ability of Transfer, howevere I also need to use these same fields in a readByPropertyMap call.

My goal is to be able to use eventId as a property while being able to "getEvent()" and get back a transfer object. The Issue: You can't have the same a column in your config as is the link column in a <manytoone>. Transfer is nice enough to create the supporting methods for your linked tables/objects, but fails to give you a convenient way to "filter" by them. I feel this is an utmost basic use of object based design but I could be wrong.

The "Solution":
<object name="ObjectName" table="tblName">
    <id name="sessionId" type="numeric" generate="false" />
    <property name="eventIdLink" column="eventId" type="numeric" ignore-insert="true" />

    <manytoone name="Event">
        <link to="events.Event" column="eventId"/>
    </manytoone>
</object>

  1. I appended "Link" to my property name. This is how it needs to be referenced in the readByPropertyMap()
  2. Added ignore-insert="true" to my properties
  3. renamed my nodes to the Object of what is returned.

I really think that if I should be ably to have a <property> named eventId and a <manytoone> named event on column eventId and have the app just know not to try and build 2 setEventId methods. Hopefully this will save someone else a few minutes time in their playing with Transfer...

 

2 comments - Posted by Russell Brown at 11:31 PM - Categories: ColdFusion | Development | Transfer

May 13 2008

Wow, sorry for the feed dump!

Due to server and software changes my blog paths were no longer the same and I stopped getting aggregated by Adobe Feed/MXNA. I ignored this aside from an email that didn't get me anywhere; until this afternoon. With the new feeds software the feeds list actualy worked and I found out what URL Adobe was looking for my feed at. A quick 301 error inside a cfif tag fixed my problems...

Unfortunetly the result was ALL of my posts showing up in Adobe feeds at the top all at once. For this I apologize, I had figuered it would go off my modified or posted date, not when it read it for the first time...

<cfif url.event EQ "showBlogRss">
    <cfheader statuscode="301" statustext="Moved Permanently">

    <cfheader
          name="Location"
          value="http://www.EmpireGPServices.com/blog/feeds/rss.cfm"
    />
    <cfabort>
</cfif>

1 comments - Posted by Russell Brown at 4:27 PM - Categories: ColdFusion | Debugging | Development | General News

May 13 2008

Sitemap awareness from Robots.txt

In writig a plugin for Mango Blog, I found out that the big leaguers for search engines have gotten together and decided that sitemap awareness from robots.txt was a good idea. This was news to me despite that this has been out there for more than a year now.

To add your sitemaps to your robots.txt simply add this line:
Sitemap: http://www.YourWebsite.com/sitemap.xml

In my case i used:
Sitemap: http://www.empiregpservices.com/blog/sitemap.xml

Further information:
http://www.sitemaps.org
http://en.wikipedia.org/wiki/Robots.txt
http://www.ysearchblog.com/archives/000437.html

0 comments - Posted by Russell Brown at 2:03 PM - Categories: ColdFusion | Mango Blog

May 13 2008

Site Map Generator: Mango Blog Plugin

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.

More info after the jump or
Download the ZIP file or view my SVN repository

Read more...

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

May 12 2008

New Mango Blog Plugin: Sphere.com Module Plugin

This weekend I stumbled upon a link on CNN for "Sphere: Related Content". Intrigued I clicked the link to check it out and found the results interesting. After some investigation I found that the service was free and not too hard to impliment. To help keep me from working on things I should be, I wrote it as a plugin for Mango Blog. A blurb from their marketing information:

  • Enhance your readers' experience by offering related content and connecting on-line conversations
  • Enhance site interaction by establishing your site as an information hub for readers
  • Acquire new readers by adding your content to the Sphere network of content

Screen shots after the jump
Download the ZIP file or view my SVN repository

Read more...

1 comments - Posted by Russell Brown at 9:36 AM - Categories: ColdFusion | Mango Blog

May 9 2008

ColdFusion 9 Feature Request: Drop Ajax/JS libraries

Yes, I said it. Going forward I do not think that Adobe should waste time on implementing JS Code libraries. Ext, YUI and others exist so you can easily integrate them into your code already. In the last few months alone I believe there have been 2 or 3 version upgrades alone of the Yahoo YUI tool and a 1 major version upgrade for Ext.

If you want to have an AJAX driven drop down, write it yourself or download a custom tag, or better yet; write the custom tag yourself and distribute it freely. I would much rather see the time spent by engineers working on ColdFusion spent working on the server side portion of ColdFusion vs. doing these seemingly 'cool' integrations. Don't custom tags exist for this purpose alone? Why build it into a server side product?

I'm tired of seeing posts and emails and requests to implement further feature sets, upgrade versions or change libraries all together. ColdFusion does not need to be my meeting ground of technology. If you had spent 2 more minutes writing your code you could have implemented the Ext library yourself, probably done a better job and you won't be beholden to a server side technology for your client side code...

Flame on

 

18 comments - Posted by Russell Brown at 11:35 AM - Categories: ColdFusion | Development | YUI | JavaScript

Categories

Monthly Archives

Tech Blogs I Read

Motorcycle Links