The miscellaneous ramblings and thoughts of Dan G. Switzer, II

The future is here: Web 2.1

There's a new Web in town—Web v2.1! A new article over at Something Awful gives a humorous, yet insightful, look at the buzz phrase "Web 2.0".

Web 2.1 is the new standard for web sites and applications in the blogosphere collective information age. It is scaleable and easy to use, as well as being user friendly and designed with the end user in mind. In order to be Web 2.1 compliant, you must follow these guidelines:

  • If it comes to a rest on the floor for less than five seconds, you can eat it
  • No means no
  • Don't expose it to bright lights, get it wet, or feed it after midnight
  • Data is the next Intel Inside
  • If the kick returner signals for a fair catch but drops the ball, the other team can attempt to recover it

Jenn's Birthday was Saturday

Jenn had her birthday on Saturday. I took her to the Cirque du Soleil show Delirium. The show was fantastic. We were in the 3rd row on the flow dead center of the stage. While it was great getting to see everything up close and personal, there are a lot of visuals that are projected on a sheer screen in front of the stage. Being so close to the stage, you couldn't really follow what was going on with the screens. Idealistically you probably want to be 50ft from the stage in order to order to see how the performers interact with the visuals on the screen. The best way I can quickly describe the show would be to call it a "modern day Opera."

After the show, Jenn & I went to Champps for dinner. Apparently there's a potato famine that I'm unaware of because I order both Potato Soup and Mash Potatoes with my meal and both times the server came up to me later and told me it would be a 15-20 minute wait, but I could get a substitute. Ended up getting a salad—which certainly is the healthier choice—and then got a free piece of cake for Jenn—which we split, ok I ate most of it—in place of my Mash Potatoes.

We then got back to the house and watched Hotel Rowanda—which was a very good movie, but started off a little slow.


Yahoo! releases new User Interface Library JavaScript APIs

Yahoo has released a pretty impressive collection of JavaScript libraries on their Developer Network. The new libraries are collection they're calling Yahoo! User Interface Library. The new UI library consists of about everything you need to build modern web applications—AJAX (Connection Manager), animation effects, drag-n-drop effects, event handlers and basic DOM umbrella for miscellaneous DHTML handling.

They've even released a few nifty UI controls (widgets) that seem pretty feature rich. These include a Calendar, Slider and a TreeView control. The slider control seems very solid and I like the "task" mode of the TreeView control (it allows you to place checkmarks next to the tree items—which would be useful in removing nodes from a tree.)

I'd also recommend checking out the new Yahoo! User Interface Blog, which is designed to talk about changes and additions to the UI Library. They've also published a Design Pattern Library which talks about common design problems and provides some solutions. They Design Pattern Library has an interesting entry on "Auto Complete", but they have not yet posted any actual code.


SeeFusion Trace Tag

I was needing to do some debugging on a live server today. I had some code that was not performing the way it should have been, so I want to use SeeFusion's trace() method to dump out some information to the debug log so I could find out exactly what line was causing the problem.

Anyway, instead of invoking a reference to the SeeFusion Java object, and manually putting in trace() methods, I thought I'd write up a little CF tag that would manage the creation of the object in the Request scope and dump out the trace methods for me, as I felt this would speed up being able to quickly insert a SeeFusion trace.

There's nothing fancy going on here, but I thought I'd just share the tag in case it saves anyone some time. I'd recommend saving this file as "seefusion.cfm" in your default ColdFusion Custom Tag directory. That will make it available to any template without having to worry about any mappings.


A new first, filed my taxes today...

For possibly the first time in my life, I actually filed my taxes before April! I'm usually so last minute about filing, but decided I'd try to get a jump on it and get them done this weekend. So, I've officially filed my taxes. I'm just waiting on electronic confirmation.

Process Explorer saves me from IBM DLA hell

I've been having a lot of weird performance issues lately. For some reason today my CPU was just getting maxed out within minutes of booting. My first thought was a virus or spyware, but after some digging around with the excellent application Process Explorer, I was able to find a thread in the system process that was eating all my CPU cycles. It was a DLL named "ssrtln.sys".

Troubleshooting this was a real pain. This DLL was eating so many CPU cycles, that it was actually preventing many applications from even loading (including Internet Explorer, the Control Panel and Windows Explorer.) Turns out this DLL belongs to the Sonic Solutions, which was part of the IBM DLA drivers which were loaded on my IBM ThinkPad R50p.

Since the driver is not loaded in Safe Mode, I tried booting to Safe Mode to remove the driver. Turns out, you can't uninstall this particular piece of software in Safe Mode.


Disabling Windows' native Zip folder support

Tonight I finally got sick of Windows XP's native support for Zip files in Windows Explorer. It really slows down Explorer and I really have never even liked the fact that it treats Zip files as folders. I want compressed archives to be what they are—files. If I want to view the contents of compressed archives, I'll use an archive applications like WinRAR.

To prevent Windows XP from treating compressed Zip files as a folder, go to "Start > Run" and type the following:

regsvr32 /u zipfldr

If you wish to restore native Zip support in Windows, just go back to "Start > Run" and type the following:

regsvr32 zipfldr

Raymond Camden's "Variable Scopes in CFCs"

Raymond Camden has posted a really excellent article covering variables in CFCs. It does a very good job of simplifying how the different ColdFusion scopes work in a CFC. If you're new to CFCs or just not sure if you're using CFCs correctly, it's definitely worth a read.

Viewing active "sessions" in ColdFusion

Ever need a snippet to read in the active sessions running on your server? This code was recently posted to the CF-Talk list and I thought it was worth blogging for future reference. (Thanks to Raymond Camden and Dave Carabetta for the information.)

function getSessions(appName) {
    var tracker = createObject("java", "coldfusion.runtime.SessionTracker");
    return tracker.getSessionCollection(appName);

variables.numSessions = 0;
variables.sessions = getSessions(application.applicationName);
variables.numSessions = structCount(variables.sessions);

<cfoutput>Total Number of Sessions: #variables.numSessions#</cfoutput>
This code relies on using internal undocumented ColdFusion factories. This means the code could potentially stop working if Adobe ever changes the internal factories.


Retrieving the wdith/height of a SWF file from ColdFusion

Doug Hughes has been kind enough to share the code he wrote to get the dimensions of a Flash (swf) file using ColdFusion. This could prove to be very handy to anyone running a CF-based CMS or if you're serving up random Flash files.

A "safe" way to compress your JavaScript code...

If you ever do any heavy JavaScript development, you know how large cross browser libraries. The file sizes of these libraries get very large, very quickly. Usually JavaScript files contain a lot of whitespacing and (hopefully) commenting, which can drastically increase the file size—which means for longer download times.

There are many solutions to this problem, but most involve the basic idea of stripping out commenting and taking out the unneccesary whitespacing. While these simple steps can reduce you files nicely, there are better ways.

Alex Russell, the project lead for the Dojo JavaScript Toolkit, has written an open source compression tool called SourceSafe. SourceSafe is based on Rhino, the JavaScript engine used in the Mozilla projects.


The Pittsburgh Steelers are Superbowl Champions!

Wow. I'm really stunned. I'm still in a bit of a haze. I can't believe the Steelers finally won another Superbowl. We've been so close so many times under Cowher, and I'm just a little numb right now from exhaustion. Yes, exhaustion. I haven't been able to sleep all week and have been on pins and needle since the AFC Championship game.

As far as the game goes, I was just sad to see the refs have such an affect on the game. There were a lot of questionable calls on both sides of the ball. I can certainly understand how Seahawks fans might feel cheated, but trust me, I've seen too many of those calls against the Steelers this year. The Steelers have had that "Chopblock" penaltly called twice on us this year after we throw an INT. It's a lame rule that needs to be reviewed.

Anyway, I'm so ecstatic about the win. Thanks to all the well wishers who called the house after the game. I appreciated it!