By barneyb on October 11, 2007
On the Fusebox 5 mailing list this evening, Brian Kotek mentioned the inability to CFDUMP the myFusebox object because CFDUMP can't handle the cyclic nature of the object's internal data structures. While dumping myFusebox (which is a CFC instance) is probably a "silly" thing to do (Sean Corfield from the same thread: "Mind you, [...]
Posted in coldfusion, development, tools
By barneyb on September 28, 2007
And here's the extra credit solution:
<cfif NOT isDefined("attributes")>
<cfset attributes = structNew() />
<cfset structAppend(attributes, form, false) />
<cfset structAppend(attributes, url, false) />
</cfif>
<cfparam name="attributes.width" default="100″ />
<cfparam name="attributes.height" default="100″ />
<cfparam name="attributes.backgroundColor" default="f7f7f7″ />
<cfparam name="attributes.borderColor" default="cccccc" />
<cfparam name="attributes.textColor" default="990000″ />
<cfparam name="attributes.text" default="Hello!" />
<cfparam name="attributes.textSize" default="16″ />
<cfparam name="attributes.textStyle" default="bolditalic" />
<cfparam name="attributes.textFont" default="courier new" />
<cfset fontArgs [...]
Posted in coldfusion, development
By barneyb on September 27, 2007
Since I had a whopping zero takers for my contest, I'm thinking it won't be a repeat event. Here's my solution for the first portion of the challenge:
<cfif NOT isDefined("attributes")>
<cfset attributes = structNew() />
<cfset structAppend(attributes, form, false) />
<cfset structAppend(attributes, url, false) />
</cfif>
<cfparam name="attributes.width" default="100″ />
<cfparam name="attributes.height" default="100″ />
<cfparam [...]
Posted in coldfusion, development
By barneyb on September 26, 2007
For those of you who missed it, I posted a little contest this morning and have gotten a whopping zero submissions! There is still time to submit a solution, but be quick, as my solution (just the base, not extra credit) will be published tomorrow morning. I'll be posting a full solution (with the extra [...]
Posted in coldfusion, development
By barneyb on September 26, 2007
Today's contest uses the new image manipulation routines in ColdFusion 8. The objective is to take the custom tag/template skeleton below and add to it so that it'll generate the following image:
The tag/template can be invoked as a custom tag, or directly on the URL with URL and/or form parameters to set it's values. [...]
Posted in coldfusion, development
By barneyb on August 13, 2007
Working on gpsracr.com this evening, and whipped open my favorite chunk of JS: Prototype. It just gets better all the time. They've added support for automatically executing text that is returned from an Ajax.Request with an appropriate MIME type (like text/javascript), which means you don't even need result handlers. Just dispatch to [...]
Posted in ajax, development, gpsracr, javascript
By barneyb on July 26, 2007
I needed to read in some gzipped text files from disk, so I wrote a little UDF to do it for me, and thought I'd share. It uses Java to do the heavy lifting under the hood:
<cffunction name="readGZippedText" output="false" returntype="string">
<cfargument name="filename" type="string" required="true" />
<cfset var data = "" />
<cfset [...]
Posted in development, tools
By barneyb on June 23, 2007
Another little gotcha to watch out for with Flex. If you have an ArrayCollection of Objects that are backing a DataGrid, you can add/remove objects from the ArrayCollection and the DataGrid will update. However, updating properties on the objects doesn't seem to update the DataGrid until you force a redraw via some other means (e.g. [...]
Posted in development, flex
By barneyb on June 22, 2007
All the listy components in Flex (List, Datagrid, Tree, etc.) have a protected method called drawRowBackground which is in charge of drawing the background for a given row. You typically use it to color a given row based on some facet of the data the row represents (e.g. red background for rows with a [...]
Posted in development, flex
By barneyb on June 20, 2007
News came back last night, my schema management tool won the Wii and CFUNITED ticket in the Open Source CF contest. After holding my wii in for the past few weeks, it'll be nice to finally let it out.
Posted in development, personal