Posted: May 13, 2008 at 7:27 AM by Ben Nadel
In my last post on object oriented data validation and error message translation , there were some really good conversations about factoring out validation logic such that different scenarios could validate the instance data in different ways. This morning, I tried to apply that methdology by factoring out my Girl.cfc and Clothing.cfc validation ... read more »
Comments (4) | Post Comment | Ask Ben | Live Chat (Beta) | Permalink
Posted: May 12, 2008 at 8:30 AM by Ben Nadel
Over the weekend, someone asked me for advice on ColdFusion hosting, so I thought this would be a great opportunity to really get the word out there - HostMySite.com has the best ColdFusion hosting. I have been hosting ColdFusion sites with them on a Virtual Private Server (VPS) and have had nothing but an awesome experience. As always, their su... read more »
Comments (19) | Post Comment | Ask Ben | Live Chat (Beta) | Permalink
Posted: May 9, 2008 at 2:50 PM by Ben Nadel
Yesterday, I discussed that as I am learning more and more about Object Oriented Programming (OOP) in ColdFusion, one of the biggest mental hurdles seems to be data validation. Well, data validation and the translation of data errors into user-friendly error messages. I talked about how the translation cannot be made in the Model because that wo... read more »
Comments (17) | Post Comment | Ask Ben | Live Chat (Beta) | Permalink
Posted: May 8, 2008 at 9:13 AM by Ben Nadel
I am still trying to wrap my head around things like MVC (model-view-controller) and OOP (object oriented programming) and cf.Objective() has really brought that back into the spotlight. One of the largest road blocks in my journey to understanding it all is the processing of data validation and reporting errors. I gather that a smart bean will ... read more »
Comments (22) | Post Comment | Ask Ben | Live Chat (Beta) | Permalink
Posted: May 7, 2008 at 9:47 AM by Ben Nadel
After I just posted about how the CFDirectory tag can use the single-character wild card , "?", in its filtering, Steve Withington came in and demonstrated that you can also use the pipe character, "|", to use multiple filters in the same CFDirectory tag. After reading this, I went to the ColdFusion 8 docs but didn't see this listed or mentione... read more »
Comments (4) | Post Comment | Ask Ben | Live Chat (Beta) | Permalink
Posted: May 7, 2008 at 9:23 AM by Ben Nadel
As part of the ColdFusion 8.0.1 updater, the CFMailParam tag can now attach files to an email using the Content attribute. When using this, the CFMailParam takes a File attribute and the Content attribute. In this case, the File attribute provides the name of the file as it will appear in the mail attachments list, not the path of the file on the ... read more »
Comments (0) | Post Comment | Ask Ben | Live Chat (Beta) | Permalink
Posted: May 7, 2008 at 8:21 AM by Ben Nadel
Minor tip here, but over the weekend, at cf.Objective() , I was watching a presentation (I think it was Mark Mandel ) when I saw that someone was using a ColdFusion CFDirectory filter that had the "?" wild card. I knew that CFDirectory filtering could use the multi-character "*" wild card, but I am pretty sure I didn't know that it could use the... read more »
Comments (20) | Post Comment | Ask Ben | Live Chat (Beta) | Permalink
Posted: May 6, 2008 at 8:39 AM by Ben Nadel
At cf.Objective() , Mark Mandel held a presentation on the caching mechanisms and algorithms he uses in his Transfer ORM project . In it, he talked about his use of Soft References. A soft reference, as opposed to a hard reference, is a reference to an object that does not get flagged as a "use" of that object. When the JVM cleans up all the g... read more »
Comments (7) | Post Comment | Ask Ben | Live Chat (Beta) | Permalink
Posted: May 5, 2008 at 9:24 AM by Ben Nadel
As a child, I remember laying out on hot summer nights and staring up at the sky. I wasn't in a city then, so the stars, unobstructed, would spread out far beyond my periphery in infinite arrangements. The sky seemed so big to me then - so incomprehensibly vast; its endless expanse always made me feel small, but not in a negative way - not small a... read more »
Comments (28) | Post Comment | Ask Ben | Live Chat (Beta) | Permalink
Posted: May 1, 2008 at 9:30 AM by Ben Nadel
Yesterday, Steve Stout brought it to my attention that my CFHttpSession.cfc ColdFusion component does not use any Referer spoofing. When I read that, I almost couldn't believe my eyes; I have spent a good amount of my time playing around with CFHttp and CFHttpParam and the fact that I forgot to put in referral spoofing blows my mind a little b... read more »
Comments (10) | Post Comment | Ask Ben | Live Chat (Beta) | Permalink
Posted: April 30, 2008 at 8:58 AM by Ben Nadel
For anyone who has built a web page that has uploaded and sent files (such as sending resumes to the Human Resources department of a law firm), you probably know that one of the most frustrating things about sending mail from ColdFusion is that the mail doesn't get sent out immediately; it gets spooled. This means that your mail file sits in a dir... read more »
Comments (8) | Post Comment | Ask Ben | Live Chat (Beta) | Permalink
Posted: April 29, 2008 at 9:59 AM by Ben Nadel
The other day, I was working on a login system that had a "Remember Me" checkbox where, when checked, the user would be automatically logged back into the system upon subsequent visits to the site. I have built systems like this many times before, but for some reasons, I was hitting a mental road block; I was having trouble wrapping my head around... read more »
Comments (10) | Post Comment | Ask Ben | Live Chat (Beta) | Permalink
Posted: April 28, 2008 at 8:08 AM by Ben Nadel
Back when Pete Freitag came to talk at the New York ColdFusion User Group , Peter Bell asked if there was a way to treat the ColdFusion image object as a more traditional object and call methods on it like Image.GetWidth() and Image.GetHeight(). Technically, you can do this, but it is not documented and leverages the underlying Java object. O... read more »
Comments (7) | Post Comment | Ask Ben | Live Chat (Beta) | Permalink
Posted: April 25, 2008 at 4:00 PM by Ben Nadel
The ClearCode Standards Project is the development standard that outlines the way in which I code all of my applications. I have talked about my methodology before and since then, it has continued to evolve and become more refined. In this blog post, I intend to keep the most up-to-date outline of the rules and the styles involved. I have chosen... read more »
Comments (58) | Post Comment | Ask Ben | Live Chat (Beta) | Permalink
Posted: April 24, 2008 at 3:07 PM by Ben Nadel
I was playing around with some ideas when I came across an odd behavior with ColdFusion's Evaluate() method. Now, let me start by saying that I hate the Evaluate() method with a passion and I cringe at the idea of using it; however, I was doing something that involved dynamic execution of built-in ColdFusion methods and Evaluate() is the only way ... read more »
Comments (14) | Post Comment | Ask Ben | Live Chat (Beta) | Permalink