I've been running my different versions of Firefox under different profiles, that way I can keep each instance unique. This works great, but I still couldn't figure out how to open both Firefox 2 & 3 at the same time. Turns out I was missing the -no-remote command line parameter in my Firefox 3 shortcut.
Here's a great write up on how to run Firefox 2 and Firefox 3 simultaneously—which provides you with full instructions on setting your shortcuts up so you can run Firefox 2 & 3 at the same time.
Back in April, I posted a preview of a multicolumn dropdown plug-in I was developing for a project at work. Well today we finally officially released the mcDropdown plug-in. I was hoping to release the plug-in sooner, but other projects took precedence and releasing it just got delayed.
I'm really proud of the plug-in and think it provides a really unique form control.
Here's a list of the features:
You can view a live example over at the plug-in page.
If you like what you see, make sure to digg it.
Now that Firefox 3 has been released, I really wanted a couple of icons that I could easily identify as either v2 or v3 for my Windows Quick Launch bar. Since I couldn't find any icons out there, I threw together 2 icons which just add the version as an overlay to the original Firefox icon.
I'm not a designer or artist, so I'm sure I could have selected better colors of green, but the contrast works well for what I needed. I can now clearly see which version of Firefox I'm getting ready to load up.
Hopefully someone else will find the icons useful.
It looks like Firefox 3 is officially released. The servers are a bit overwhelmed at the moment, so you need to use a little perseverance to get the download pages to come up. I think there may be some delays in propagation of the actual Firefox 3 download page as well.
Massimiliano Balestrieri posted a neat little script today in honor of Firefox 3 Download Day 2008. The concept is simple, change the appearance of the page in IE6 slightly by making it show up in black and white. So if you really want to protest IE6, this is a comical way to do it on your blog. I just find the effect hysterical.
/* * * Black'n'White plugin 1.0 * $Date: 2008-06-17 15:38:15 +0200 (mar, 17 giu 2008) $ * $Rev: 177 $ * @requires jQuery v1.2.6 * * Copyright (c) 2008 Massimiliano Balestrieri * Examples and docs at: http://maxb.net/blog/ * Licensed GPL licenses: * http://www.gnu.org/licenses/gpl.html * */ if(!window.BlacknWhite) var BlacknWhite = {}; BlacknWhite = { init : function(options) { options = jQuery.extend({minor : 7}, options); if(jQuery.browser.msie && jQuery.browser.version < options.minor) jQuery("html").css("filter","gray"); } }; jQuery(document).ready(function(){ BlacknWhite.init(); //BlacknWhite.init({minor : 8}); });
You'll need jQuery on your page to use this script (at least as-is) but it would be simple to adapt to either plain JS or another JS framework. The only thing really going on is it's setting a filter on the <html/> tag to show the whole page in gray.
I've added this script to this blog entry so you can easily view the effect.
Paginating data is one of those commonly required tasks. In previous version of MS SQL Server it's been tricky to handle, but made easy via the use of stored procedures that handle the pagination logic for you. However, if you're using SQL Server 2005 there's a much easier way to handle pagination and that's to use a Common Expression Table (CTE.)
Microsoft created the CTE syntax to make solving complicated tasks easier (such as returning a query of hierarchical tree data.) When you create a CTE, you're essentially creating a virtual table you can query against. CTEs generally perform very well and can often replace the need for creating temp tables.
Let's look at an example of query out records 11-20 from a Employee database:
-- create the Common Table Expression, which is a table called "pagination" with pagination as ( -- your normal query goes here, but you put your ORDER BY clause in the rowNo declaration select row_number() over (order by department, employee) as rowNo, -- a list of the column you want to retrieve employeeId, employee, department from Employee where disabled = 0 ) -- we now query the CTE table select -- add an additional column which contains the total number of records in the query *, (select count(*) from pagination) as totalResults from pagination where RowNo between 11 and 20 order by rowNo
The first part of the query creates the table expression we'll actually query against when we grab the actual results from the database. In the CTE you're going to write the SQL you'd normally write to grab all the records with one exception—you use the row_number() function to generate a virtual column that orders your result rows for you. The actual "order by" clause you want to use will actually go in the row_number() declaration—this makes SQL Server assign the correct row number for each record.
It's important to remember that a CTE can be as complex as you need it to be. You can do joins, pivots, etc—whatever you need.
The next step is to actually query against the CTE you created. This query will virtually be the same for all pagination queries you write. You are simply grabbing all of the columns and then limiting the returned data to just the rows you want to display (in this case rows 11 - 20.)
In this example, I added an additional column that contains the total results that were returned from the CTE. This is not needed, but it's handy if you need to do something like "Results 11 - 20 of 4,567 records." There are many ways you could generate the total records, this is just one method.
If you've upgraded to SQL Server 2005 and haven't started using CTEs yet, you really need to start getting familiar with them as they really simplify many tasks in SQL Server that previously were very difficult to solve.
This idea is pretty clever, but is probably best done with a 2 liter (since I think anyone would get suspicious of an smaller 20oz bottle that was already open.)
I saw this a week or so ago and thought it was worth watching again. Even if your not a fan of the game, I recommend watching the video just so see what an incredible job the guys at Rockstar did creating a realistic environment.
The video contains no violence and just shows some camera panning around the city. In the first scene, just watch the sky. It's amazing how realistically the clouds move and it's cool watching the occasional plane fly over head.
The author of the video had this to say:
"As I was playing the game, I realized the potential for time lapse filmmaking thanks to the day/night cycle and all the varying weather patterns.
This work was achieved by using one particular motorbike in the game (and the odd helicopter) which offers an uncluttered frame, free of any bodywork in shot. The shots required cramp-inducing holds on the controller for sustained periods of time, in order to get slow and steady shots. Slow pans required delicate movement of the thumb sticks. There is no way to cheat it. Everything is done in-game without glitches, just lots of experimentation and patience.
Fortunately, Rockstar Games gave the means to turn off the HUD, etc, and created a world vibrant enough to allow this type of creative outlet."
This is not a new tip, in fact I'm pretty sure I've blogged about it in the past, but the fastest way to open a file is via the "Open Resource" dialog box. Pressing [CTRL]+[SHIFT]+[R] opens the dialog box, which allows you to free form type a search string that will show you all the files that match your search string.
This is extremely handy when you know the name of the file you want to open and have lots of resources or just tons of files in your projects. I deal with several really large projects and this is almost always faster than opening the file via the Navigation View.

Are there songs that still give you those "chills" when you hear them? Maybe it's just a single note or a lick here or there. There are dozens of songs that still invoke that feeling in me. Songs I've listened to hundreds—maybe even thousands of times.
I was just listening to "No One Like You" by the Scorpions. Even though I've heard that song countless times, the open guitar harmonies still make the little hairs on the back of my neck stand up. I love it! I can't help but listen to that intro a couple of times whenever it comes on my mp3 player.
I was working on another SVN hook today and only wanted to run some code if a particular folder was modified, just to save some processing time from unnecessarily running an SVN update process. Here's the little snippet I came up with to run in my post-commit.bat file:
The idea behind this is simple. We check the log for the revision that was just checked in to see if it contains a specific string—which in this case is a folder path. If the log does contain the string, we update our local copy. If it doesn't exist, we skip that step and just output a message that says no updates found.
Make sure to check out my other posts on using SVN hooks in Windows for more tips and tricks.
I haven't seen this tip anywhere (because maybe it's too obvious, I don't know) so I thought I'd share it. You can safely bypass paying your tolls driving straight through the middle gap between all the toll booths on a motorcycle. You need to be on a motorcycle, because it's the only vehicle that will fit. :)
Sometimes I don't feel like outrunning the cops and don't like slowing down to pay the tool, so slipping between the booths saves me a lot of time (although I admittedly have been using taxis more and more often—it's just a great way to quickly get from point A to point B.)
Oh snap. Someone built a giant work NES controller that doubles as a coffee table. Pretty sweet:

Here's video of the coffee table in action while they play Super Mario Bros.
Raymond Camden blogged about a question someone had about getting the folder path for the current template. While Raymond addressed how to get the OS path, how would you get the URL path? So, if you had your user was on the URL http://www.example.com/some/folder/and/file.cfm, how would you go about getting the "/some/folder/and/" path?
While there are always many ways to solve a problem, I've tried to come up with a solution that should work for any version of ColdFusion from 6.0 and above. I wanted to avoid using CGI variables (since those vary by webserver,) so I went with using getPageContext() instead.
Here's the solution I wiped up:
If you just call getWebPath() it will return the current web folder path for the current base template.
We use a regular expression to strip out additional path info information that can sometimes be present for people using SEO-friendly URLs. For example, the URLs on my site appear like: http://blog.pengoworks.com/index.cfm/2006/9/27/CFMX-UDF-Parsing-a-URI-into-a-struct which returns a path of /index.cfm/2006/9/27/CFMX-UDF-Parsing-a-URI-into-a-struct. We need the regex to find the last period in the string and assume everything else is additional path info. The default regex should work in the vast majority of cases, but you can adjust it for the corner cases.
You can also manually supply a path such as: #getWebPath('/index.cfm/2006/9/27/CFMX-UDF-Parsing-a-URI-into-a-struct')#. This would return "/" as the web path.
Anyway, hopefully some of you will find this little UDF useful.
I haven't really had much to give in terms of updates on my Black Lab Nikki's recovery. The first couple of weeks were a bit rocky, but after that things calmed down and recovery was just slow (but generally uneventful.) She really handled being couped up much better than I imagined she would. She's just such a high energy dog, I thought she'd drive us crazy being confined to her kennel. I think the fact that I took her on 4-5 walks a day helped a lot. While most of the walks were relatively short (mostly just up and down our street,) it allowed her to get out and burn off some energy.
On Wednesday I took Nikki for her 10 week checkup (which was actually on week 11.) The surgeon who performed the double bilateral TTA is doing a paper on healing after the 6 week period, so I've been taking her in every couple of weeks to get new X-Rays done. Since this was part of a research paper he's working on, they haven't been charging for the visits or X-Rays.
After looking at the X-Rays, he gave us the "Ok" to let Nikki resume normal activities. She's allowed to do whatever she wants, but he wants us to limit her amount of activity for the first couple of weeks. He basically wants us to keep physical activities under 2 hours—which quite frankly shouldn't be an issue.
So, last night I finally got to play fetch with both our Labs in the backyard. She's running a little funky still—she short of hops her back legs. I expect as she's able to really stretch things out and regain complete range of motion of her back knees she'll return to full stride. The doctor warned us she'll probably show signs of limping for the first couple of weeks if she plays hard and not to be concerned unless it doesn't go away after a night's rest.
Well our pocket book is much lighter, we finally got our Nikki back. :)