Entries Tagged as 'ColdFusion'

What I Learned Today - I blame Ben Nadel for this post...

What I Learned Today , ColdFusion 6 Comments »

Okay, the title is meant to be facetious, and attention grabbing. Just so we're all on the same page. But it's not untrue.

Through Ben Nadel's fantastic blog, I learned the practice of creating and scoping a LOCAL struct in a CF function (CFMX7 and CF8), and assigning any other local variable created in the function into that struct. That way I did not need to manage multiple variables, trying to make sure they were all locally scoped. It seemed more efficient.

Well, with the migration of my VPS to CF9 (and the impending upgrade of my work's servers to CF9), I found blog posts talking about how others that had used this practice were finding oddities with their code upon upgrading. It seems that this practice was somehow colliding with the new protected "local" scope within functions in CF9. The new scope allows coders to do exactly what I was doing, only without having to scope that local struct first.

In trying to figure out what changes I needed to make, I went asking around trying to find out if this meant that we no longer had to scope local variables anymore inside of functions, if unscoped variables would automatically get put in the new local scope. To hear and read the documentation, you certainly could come to that conclusion.

Thanks to Ray Camden, I have been straightened out. It turns out this is not the case, and I am not the first to ask him this. He was kind enough to make this topic an entry in his just as fantastic blog.

Bottom line, you don't have to scope things put in the local scope, but you must explicity call the variable in the local scope (local.myVariable). And all other variables must still be scoped for protection.

Google Chrome and missing form fields

Chrome , ColdFusion , Web Development 8 Comments »

On a legacy application that I maintain, I have seen a rash of errors recently that are new. They are all in regards to form fields missing on a form action page. The things that make this one different is that:

  1. The fields in question are empty text fields, not unchecked radio buttons or checkboxes.
  2. The browser type of all these errors in Google Chrome

Now, while the fix is the same for all of these issues (CFPARAM the form fields), I was wondering if others have been seeing this with Chrome at all, and if there's any insights as to why Chrome seems to not want to pass along empty text fields, like every other browser out there does. I have not played with Chrome at all, and our applications do not officially support that browser at this time, so I can't spend much time at all investigating these errors in light of that. So I am hoping that some of y'all might have some information you would be willing to share?

What I Learned Today - Flex Training Follow-up

Flex , What I Learned Today , ColdFusion 2 Comments »

I wanted to pass along my experiences from my Flex Training for ColdFusion Developers that I took yesterday in Chicago.
 
This was a course from Adobe that was along the lines of an "intro to..." kind of course regarding Flex. Flex is the bridge that connects Flash to a backend (in this case CF9 but it can connect to any backend). It was aimed at people with my skill sets, but it was clear within the first hour that if you had some Flash and Actionscript background you were going to get a lot more out of it. I had neither, but I was able to follow along well enough.
 
Our trainer was Jeff Tapper, a senior Flex developer who has worked on some high profile projects, most recently working with Major League Baseball on their MLB.tv video feeds (I hope I got that right). He took a good amount of time in trying to make sure that we did not fall behind much.
 
On the Flex/Flash end they laid out some interesting (albeit very basic) usages. A lot of using Flash as a front end for basic forms and having it call CF9 to do some processing and returning data to the front end without a page reload. They did show that Flex can do form validation natively, and since it is not tied to a feature that can be disabled like JavaScript, it lessens the need for writing both front end and back end code for data input validation to a nice-to-have instead of a must-have. With a standard HTML front-end, if a user disabled JavaScript they could still submit the form and therefore having server side backend validation is an absolute must. Here, they either have Flash enabled and get it all, or they don't and don't see the form. There is no in-between.
 
Using Flash Builder you could set the Flash compiler to make the flash application accessible with a single checkbox in the options. I would be curious to see what our 508 team would think after taking a look at some of the demos we did, to determine if it truly is 508-compatible or not.
 
I did like the Flash Builder tool a lot, it has a nice GUI interface for creating the Flash front-ends and allowed you to manage some of the actions for the form objects as well. If I was going to build a Flex application, I would choose to use Flash Builder (which is built on the Eclipse IDE). But it costs at least $250 for the standard copy, and can get up to $700 for the Premium (which includes network monitoring to test the efficiency of your Flex application).
 
What I would need though is a lot more training on the Flex language itself. This I can self-teach given time I believe, but there's a lot still to be learned on that front.
 
What I ended up walking away most impressed with though was the new CF9 server and the ColdFusion Builder application. CF Builder is currently in Beta 2 phase, and is also an Eclipse-based IDE. It did have a couple of bugs but nothing major, and I really liked how it could be integrated with your CF server, either a local one or a remote one, to give you some control over the server, and through RDS get a lot of quick access to the database.
 
As far as CF9, the single biggest thing I walked away from this was the introduction I got to CF9's ORM (Object Relational Mapping) feature. After a first introduction to it, and watching a couple of other presentations on it since, this could be a tool that changes how we interact with databases. It enables you to write fairly generic code, and use functions instead of queries for accessing the database (and supports all parts of a CRUD interaction). Because of this, you could write CF code that would work the same with a database no matter what server it's on - be it MSSQL, MySQL, or Oracle (to name the three most common ones). It also takes a lot less code to interact with the database, which will save us time in coding. ColdFusion Builder has extensions that can speed this up even more, by connecting to your database via RDS, reading the configuration of a table, and auto-generating the components needed for you. CF9 also natively handles a lot of this communication as well. If you couldn't tell, I'm pretty excited about trying this out.

Headed to Chicago for Flex training

Flex , ColdFusion No Comments »

Thanks to Ray Camden's blog post that told me about this offering, I am going to be taking a full day of Flex training from Adobe in Chicago on November 19th. The last time I took Adobe-sponsored training was from the folks at Figleaf a few years back, and it was a great experience. I am really looking forward to doing this. Oh and a night in the Hyatt Regency Chicago should be pretty sweet too.

Those following the PHP vs. CF drama may wonder why I am doing this - or more specifically, why this would be covered under my company's training budget - is that the fight for CF is not close to being lost it seems. Turns out that due to contractual stuff, we should be able soon to upgrade from CFMX7 to CF9. That's good news for me as well!

Better Late than Never: CF8 Certification

ColdFusion No Comments »

In keeping with a time-honored tradition of mine, I finally got around to getting my certification for ColdFusion 8 just as ColdFusion 9 comes out. I did this for CF5 and CFMX7 as well. Mainly this is for me to check that box off my to-do list, but it's also a resume padder for my employer to use on proposals.

I admittedly did very little studying for this exam relative to what I've done in the past, and as a result I did not hit the 80% score needed to get Advanced Developer status. I got a 79%, which I guess means I'm the best of the rest or something like that. But this exam, unlike the other ones I've taken, spent a lot more time into some real niche areas of CF that I personally haven't used too much.

That being said, for those that do want certifications in CF, I highly recommend using CentraSoft's CF Exam Buster software. I've used it as my sole training tool in addition to my years of experience, and I think it's the best. Just next time, I'll use it for more than 2 days in advance of the the CF9 exam...

Powered by Mango Blog. Design and Icons by N.Design Studio
RSS Feeds