Custom “Hours Logged” Messages in Freshbooks

March 30th, 2008 by erin

If you’re a regular reader of the BrightMix blog (Google Reader anyone?), you are probably well aware of the fact that we do things a little differently here. Since joining the company a little over a month ago, I’ve quickly learned to love the BrightMix way of doing business. It’s pretty safe to say that I drank the Kool Aid, and now I am hooked.

As Kevin and Dusty have mentioned in previous posts, a lot of our business tools live on the web. Sure, we all have Microsoft Office, but I’ve honestly only used it once.

One product that I’ve enjoyed working with so far is Freshbooks. They offer web-based time tracking/billing software. My personal experience has been limited to the time tracking piece, but I really like their interface. In fact, one of the high points in my day is to receive a hilarious confirmation message when I log my time. Unfortunately, the function that determines your message limits your odds of receiving a funny message, and will often display “Hours Logged,” instead.

Egregious!!!

I recently went through a rather long drought, receiving nothing but “Hours Logged” for a couple of weeks. So I did what any good user would do – I made a feature request to give me more control over my messages. Freshbooks responded promptly, and has opened a new post for suggesting new funny messages.


Before clicking “Log Hours”

After clicking “Log Hours,” I usually receive the boring “Hours Logged” message

Greasemonkey – That Funky Monkey

The response was great, but fell short of my ultimate goal – ridding my life of the much too corporate “Hours Logged” message. Luckily, Kevin and Dusty value funny messages almost as much as they value me logging billable hours, and they gave me the green light to work out a script to override the Freshbooks function.

To do this, I used Greasemonkey, which is an Add-on for Firefox that allows you customize the way a web page looks or behaves using JavaScript. This was my first experience with GreaseMonkey, and it was rather enjoyable…

The process was pretty painless: find the function on the Freshbooks page that determines the confirmation message, create a modified version of that function in my user script, and have Greasemonkey tell the page to call my function instead of the one on the page. I think I spent more time brainstorming additional messages than actually writing the meat of the script.

Check out the sampler button below, which has been modified to never display “hours logged” and has some additional messages picked by us BrightMix’ers… (Note: if you’re reading this through a feedreader, you’re probably going to have to come to this page to see it in action.)

Try Logging your Hours! (click the button)

How to get your own custom messages:

Step 1: Use FireFox

Step 3: Download GreaseMonkey Here

Step 2: Download the Script Here

Step 4: Add custom messages to script as needed