Very good point, and one I've been caught on before. No, CF tag and function syntax is not case sensitive, so <cfquery name="qry" and <CFQUERY NAME="qry" are the same, as is createobject( and CreateObject(.
That being said, and as mentioned before, anything related to the file system will be. If you have a cfc at Com/myCo/Class, and have a component call as createobject("component","com.myco.class"), it will break on *nix. I once had a small app I wrote on Windows, which had to be run on Linux, and had to spend four hours fixing all of my object calls. Lessons learned. An older version of mySQL also required case sensitivity of table and column names, so SQL had to be carefully reviewed for case. It makes sense to be 'case sensitive' when writing your code. You never know when business requirements might change, and a system is migrated to a different OS, a different DB, or what-have-you. I use lower case for all CF tags and attributes because that's the standard for XHTML, and writing my CF that way keeps me on track when writing display. I even close single tags when I can (<cfset />) while leaving those alone that I can't (<cfelse>). I use camel case when writing function calls, or cfscript blocks, because that's the ECMA standard, and keeps me focused when writing JavaScript or ActionScript. Conventions help you stay consistent. Guidelines keep everyone in a group writing consistent code. This assists in maintaining an application, as you might not be the one making changes to code you originally wrote. Steve "Cutter" Blades Adobe Certified Professional Advanced Macromedia ColdFusion MX 7 Developer _____________________________ http://blog.cutterscrossing.com Dale Fraser wrote: > Beware, > > ColdFusion is becoming more case sensitive, so you should be careful. > > These new ColdFusion features (which are javascript) are case Sensitive. > > ColdFusion.Grid.refresh('gridName'); > > For example. Im not sure but I think (due to file system stuff) > > <cfset me = createObject("component", "com.company.Class") /> > > Might be case sensitive on *nix as the com.company.Class bits are file > references. > > Regards > Dale Fraser > > http://learncf.com > > > -----Original Message----- > From: J.J. Merrick [mailto:[EMAIL PROTECTED] > Sent: Thursday, 4 October 2007 8:53 PM > To: CF-Talk > Subject: Re: Case Sensitivity > > From what I have encountered most things are case insensitive. The > only thing I would say is if you are working with *nix disk access is > that directories and filenames are case-sensitive or if you are > calling anything in Java that that is case-sensitive. The only reason > to check case would be for readability and to be that anal about it is > a tad overboard. As long as you aren't typing them in all-caps > (::cough:: ::cough:: Ray ::cough::) You should be ok in my book :-) > > > J.J. > > On 10/4/07, Tim Ashworth <[EMAIL PROTECTED]> wrote: >> Hi All, >> >> This is just a quickie, and really not too important. However it will > clear >> up an argument that I'm having with my rather conservative colleague. >> >> I was under the impression that coldfusion was entirely case insensitive >> regardless of if it is on a windows or linux OS. So I'm quite happily >> writing everything in lower case and camel case, but my colleague is >> convinced that this is wrong. Whilst I appreciate that it's a good idea > to >> stick to a convention and not be too sloppy I have to confess I'm getting > a >> bit fed up checking case when I'm sure it's not an issue. I have done > some >> tests and it all *seems* case insensitive, but I'd appreciate some back-up >> from a more experienced CF developer. >> >> Cheers >> >> Tim >> >> *hopes that he's right or he'll have to check the last app he wrote* >> >> >> > > > > ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Get the answers you are looking for on the ColdFusion Labs Forum direct from active programmers and developers. http://www.adobe.com/cfusion/webforums/forum/categories.cfm?forumid-72&catid=648 Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:290170 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4