Ben Nadel
On User Experience (UX) Design, JavaScript, ColdFusion, Node.js, Life, and Love.
I am the chief technical officer at InVision App, Inc - a prototyping and collaboration platform for designers, built by designers. I also rock out in JavaScript and ColdFusion 24x7.
Meanwhile on Twitter
Loading latest tweet...
Ben Nadel at cf.Objective() 2010 (Minneapolis, MN) with:

Alex

Member since May 18, 2009

Recent Blog Comments By Alex

  • Ask Ben: Uploading Multiple Files Using ColdFusion

    Posted on Dec 22, 2009 at 9:48 AM

    @Ben > mime type Sorry. I should've clarified. You can't get mime type for multiple file uploads with the same field name. Which is my whole gripe. All your left with is a bunch of binary temp files on the server. You can get the file names from getHttpRequestData(). Why support _some_ of HT... read more »

  • Ask Ben: Uploading Multiple Files Using ColdFusion

    Posted on Dec 18, 2009 at 7:13 PM

    The only other issue with cffile is that you cannot retrieve the original mime type. This becomes a problem when you go to serve the uploaded files. Especially out of a database. Serving a file requires a mime type, e.g., image/jpeg. You need to add a file extension to mime type lookup. E.g., file... read more »

  • Ask Ben: Uploading Multiple Files Using ColdFusion

    Posted on Dec 15, 2009 at 12:38 PM

    @Barry > crud images MySQL blob data type < http://dev.mysql.com/doc/refman/5.0/en/blob.html > ColdFusion MySQL data source, enable BLOB < http://livedocs.adobe.com/coldfusion/8/htmldocs/help.html?content=functions_h-im_10.html> > crop images ColdFusion ImageCrop function <... read more »

  • Exploring Mixins And ColdFusion Components

    Posted on Oct 3, 2009 at 1:27 AM

    @ben Dango! Just now saw your post about swapping CFC methods at runtime. I have to keep up with your blog more.... read more »

  • Exploring Mixins And ColdFusion Components

    Posted on Oct 3, 2009 at 1:19 AM

    @ben Seems like there should be a better way to make modules (OOP, not cfmodule) and mixins. I mean, in a rubyesque way. Psuedocode is easier. comp Math ...func pi ...func sin ...func cos comp Debug ...func print ...func dump ...func inspect Use Math as a ruby module. Similar to ruby's require... read more »

  • Cannot Invoke Method On An Object Of Type coldfusion.runtime.VariableScope With Named Arguments

    Posted on Oct 3, 2009 at 12:41 AM

    @ben The variables scope of a component is part of the class definition, not an object instance definition. You can use it for class methods, class constants, et al. The this scope of a component is part of an object instance definition. You can use it for instance methods, instance properties, et... read more »

  • Turning On Multiple Statements In ColdFusion 8 MySQL 4/5 Datasource

    Posted on Oct 1, 2009 at 10:22 AM

    @ben > stored procedures The example I've shown using prepared statements is just directly using the same method ColdFusion/Java uses to do parameterized queries. This isn't really using stored procedures. This is just a way to do multiple statements/resultsets in a single database call. Usual... read more »

  • Ask Ben: Uploading Multiple Files Using ColdFusion

    Posted on Oct 1, 2009 at 10:07 AM

    @Ben > where are you grabbing the form data from? You're right, ColdFusion/Java intercepts the file data. For multiple file uploads with the same form field name, you gotta do an end run around. The form scope will give you the filename of the last uploaded file. <cfsavecontent variable="... read more »

  • Ask Ben: Uploading Multiple Files Using ColdFusion

    Posted on Sep 29, 2009 at 10:56 AM

    > concatenated into a list Yes. That is why the form and url scopes are stupid. Granted, the good thing about the form and url scopes are their ease of retrieving values. Assuming you only want the first value or there are no commas. Which is probably 99% of the time. But they break even the s... read more »

  • Ask Ben: Uploading Multiple Files Using ColdFusion

    Posted on Sep 29, 2009 at 10:28 AM

    @Ben > naming files the same thing This is my usual strategy for JavaScript add/delete/rearrange. <fieldset class="item"> <input name="title" type="text"/> <input name="description" type="text"/> <input name="file" type="text"/> </fieldset> That way, you don't ha... read more »

  • Ask Ben: Uploading Multiple Files Using ColdFusion

    Posted on Sep 29, 2009 at 10:14 AM

    I discovered a problem with the CF file upload thing: file parameters with the same parameter name. They all upload to CF, you just can't retrieve them as easily. <input type="file" name="file0"/> <input type="file" name="file1"/> This works fine. <input type="file" name="file"/>... read more »

  • Turning On Multiple Statements In ColdFusion 8 MySQL 4/5 Datasource

    Posted on Sep 29, 2009 at 10:02 AM

    This trick doesn't return multiple resultsets. ........................................ <cfset query={}/> <cfquery name="query.resultSet" result="query.details" datasource="dev"> select 0; select 1; </cfquery> <div>query: <cfdump var="#query#"/></div> ........ read more »

  • ColdFusion Application.cfc OnRequest() Creates A Component Mixin

    Posted on Sep 25, 2009 at 2:53 PM

    You can also is Ben's technique to do page-specific mixins. Separate your business logic from display logic! This is similar to code behind files in ASP.NET. (Although ASP.NET provides late bind and other stuff.) Keep in mind this is simplified to demonstrate. This just does pre-processing. Theor... read more »

  • ColdFusion GetPageContext() Massive Exploration

    Posted on Sep 25, 2009 at 1:01 PM

    @don, > why are you setting temp.new to temp.original? Just to demonstrate the replacement. You're right. Leaving the original string is not a good idea for performance. > why you are putting all this in the Application.cfc in the first place To do some fancy post-processing on the body c... read more »

  • ColdFusion GetPageContext() Massive Exploration

    Posted on Sep 25, 2009 at 11:40 AM

    @ben Great work! Provides another option to intercepting the message body. (In addition to cfsavecontent.) page.cfm <div>foo</div> application.cfc (cfsavecontent) <cfcomponent> <cffunction name="onRequest">< cfset var temp={}/>< cfsilent> ... read more »

  • Assigning Variables Within A CFLoop Condition In ColdFusion

    Posted on Sep 24, 2009 at 2:13 PM

    @Ben, > (x=0) > not valid syntax I understand. Then expression syntax is different for assignment expressions than it is for comparison expressions. Because these work fine: assignment: <cfloop condition="x = 0"></cfloop> comparison: <cfloop condition="(x eq 0)"></cfl... read more »

  • Assigning Variables Within A CFLoop Condition In ColdFusion

    Posted on Sep 24, 2009 at 1:26 PM

    Shoot. Forgot to label Type 5. Type 6 is incorrectly labelled Type 5.... read more »

  • Assigning Variables Within A CFLoop Condition In ColdFusion

    Posted on Sep 24, 2009 at 1:24 PM

    Did some other tests. Type 0 <cfloop condition="(x = 0)"></cfloop> This doesn't work. Error: "Invalid CFML construct found on line 1 at column 5. ColdFusion was looking at the following text: =" This seems different than normal expressions which use parentheses as precedence. Type 1... read more »

  • ColdFusion Application.cfc OnRequest() Creates A Component Mixin

    Posted on Sep 21, 2009 at 10:43 AM

    Also cool is the ability to use CFM pages as modules, instead of includes. <cfinclude template="#arguments.targetPage#"/> <cfmodule template="#arguments.targetPage#"/> You can then do some fancy stuff, like pass attributes. <!--- <cfset uri="/blog/805-ColdFusion-Application-cfc... read more »

  • ColdFusion Basics : Nesting Custom Tags

    Posted on Sep 21, 2009 at 9:17 AM

    @ben > which parent I'd say there's only one. There are other levels, grandparents, great grandparents. But shouldn't you let your parent talk to your grandparent? I'm thinking error handling, event handling, et al. These things need to bubble up the chain. How about this scenario. ............ read more »