Using jQuery style a cftooltip span

It’s not hard to figure out how to style the box that pops up when using cftooltip.  It is controlled by the .yui-tt class.

/* Tool tip styling */
.yui-tt {
color: #444;
font-size:110%;
border: 2px solid #1C64D1;
background-color: #eee;
padding: 10px;
width:250px;
cursor:help;
}

But how do you style the text that is triggering the tooltip?  cftooltip is going to generate a span around your text with the id of cf_tooltip_999999999 (where 999999999 is some random number).  I didn’t want to add another span to the mix to provide styling so I turned to jQuery for a simple, quick solution.

In the css file I added a class:

.terms{
color:#168FC0;
border-bottom:1px dashed #168FC0;
text-decoration:none;
margin-bottom:10px;
font-weight:bold;
}

In the jQuery .ready() function I added this line:

$("[id^=cf_tooltip_]").addClass("terms");

The result is that the text which triggers all cftooltips is now controlled by the .terms class.

Best Firefox Add-ons for web developers?

I’m looking for the best Firefox Add-ons for web developers.

A few things you should know about me:

  1. I like lists.  A lot.  I make them all the time for everything.
  2. I hate repetition and drudgery in my work.  If there is a (legitimate) shortcut I want to know about it.
  3. I’m a ColdFusion web developer who dabbles in jQuery.
  4. I dig Firefox for helping me with all of the above.

Now this is where you come in… What are your favorite/most useful Firefox Ad-ins that help you get your work done on a daily basis?

Here are mine (alpha order):

  • ColorZilla – Eyedropper/colorpicker
  • Dummy Lipsum – Generate “Lorem Ipsum” dummy text.
  • Evernote Web Clipper – For selecting text to evernote
  • Fast Dial – Visual bookmark homepage
  • Firebug – My main usage is debugging AJAX
  • FIreGestures – Executes commands with mouse gestures
  • FireShot – Screen shot utility
  • iMacros – Awesome utility for building test cases or automating repetitious tasks
  • TinyURL Generator – Generates TinyURLs
  • Web Developer – Adds tons of tools (too numerous to list)
  • Xmarks – Sync your bookmarks across multiple machines (and platforms!)

Thanks, I look forward to hearing from you.

CF quickie: cfqueryparam with SQL’s LIKE operator

If you are using cfqueryparam to build a SQL statement from a search form and need to use the SQL’s LIKE operator here is how it’s done in the most basic way:

<cfquery name="qData" datasource="myDsn">
SELECT DISTINCT last_name
FROM person
WHERE last_name LIKE <cfqueryparam cfsqltype="cf_sql_varchar" value="#FORM.last_name#%">
ORDER BY last_name
</cfquery>

The magic is all in the % sign at the end of the cfqueryparam value attribute.

I’m an ACE (Adobe Certified Expert) in Advanced ColdFusion 8

Two months of studying paid off today.  I took my ACE exam for ColdFusion 8 and passed with a 98%, which also means I qualified for the Advanced status.  The Web Application Construction Kit is all you’ll ever need to become a CF Ninja.  For the exam I’d recommend reading the first volume cover to cover. Additionally I found the ColdFusion MX 7 Certified Developer Study Guide to be very useful.  Even if you don’t need it for your job challenge yourself and go for it.

ColdFusion 8 WACK ColdFusion MX 7 Certified Developer Study Guide

Put your junk in the trunk: “Moving” a subversion repo into the trunk

This post gives you the Windoze commands because this was something I worked on for my Office.

We have a project.  Let’s call it project1.  When the repo for the project was initially created it was not created with branches, trunk, and tags folders in the root.  Going forward, everything was just committed to the root instead of to the trunk folder.  Well, now we want to follow best practices and begin committing to the trunk.  We don’t want to lose any of our repo history in the process though if we have to do re-creations of the repo.

We tried to do an svn mv, but you can’t move a repo to a path within the repo.  So here’s what we did.

  1. Make a dump of the current repo
    svnadmin dump c:\Repositories\myproject1\ > c:\myproject1.dump
  2. Delete  the current repo (I’m assuming you have a backup if something goes wrong.  You do, don’t you?).
    rmdir c:\svn\myproject1
  3. Recreate the repo.  This time let’s be sure to make branches, trunk, and tags folders in the root.
    svnadmin create c:\Repositories\myproject1
    svn mkdir trunk
    svn mkdir branches
    svn mkdir tags
  4. Load the dump into the trunk (Gross):
    svnadmin load c:\Repositories\myproject1\ --parent-dir trunk < c:\myproject1.dump

There it is.

You might also give this a try: http://chipcastle.blogspot.com/2008/08/subversion-forgot-to-create-trunk.html

eMusic Premium Plan Change – 45% fewer downloads… same price

I don’t even know what to say to express the level of disappointment I have regarding this.¬† I logged in to eMusic today and discovered that my Premium Music Plan is going from 90 downloads a month to 50.¬† Ouch.¬† Looks like I’m going to have to start buying used cds again.¬† Following is the correspondence I sent them.

Changing my plan to 1/2 the downloads for the same price?¬† Not very recession friendly and pretty sorry.¬† Especially for a customer who has been with you for years.¬† If I wanted music from the Boss, Alicia Keys, and the Dixie Chicks I wouldn’t be shopping at emusic.¬† Cancel my account and the level of respect I used to have for your site.

I have used eMusic for about 5 years or so and have learned of so many great bands from the site.  What a pity.

Hide .lck files (and others) in Aptana on the Mac

I’m test driving the Aptana Studio plugin for eclipse.¬† It looks very slick.¬† Just a quick “how to” note for hiding files (like Dreamweaver .lck files, hidden system files, etc) in the project window.

  • Click the Project Window Tab
  • Hit FN+CMD+F10
  • Select “Filters…” in the dialog that opens
  • Check the boxes beside all the types you want to hide
  • Click ‘Ok’

Pretty simple.¬† So why did it take me an hour to figure it out 😐

ColdFusion Dying… Again

So I took some database training with Global Knowledge last week.¬† My office paid for the training.¬† Apparently that “back end” training may be all for naught though since my front end programming language is on life support.

Today’s Global Knowledge newsletter letter informed me (in very cheeky fashion) that ColdFusion is # 5 on their “Dying Technology” list:

“If any of these skills are your main expertise, perhaps it’s time to retrain.”

Here’s the whole article: http://www.globalknowledge.com/training/generic.asp?pageid=2347&country=United+States

The notion of ColdFusion being dead has been debated into the ground so I’m not going to belabor it.

IMHO, ColdFusion is the best thing that ever happened to me from an IT standpoint.¬† If you want to get things done quickly, easily and reliably use it.¬† If you are thinking of ColdFusion along with COBOL, Netware, Flannel Shirts and “Grunge” Bands From Seattle, and¬† you might want step outside your house more.¬† It’s not the mid 90’s anymore.

Via Con Dios, Geocities

Yahoo has officially pulled the plug on Geocities.

http://www.sitepoint.com/blogs/2009/05/03/rip-geocities/

I learned HTML making my Geocities site. I would love to see that brilliant collection of animated gifs and snazzy javascripts, but alas, I cannot find it anywhere in my archives. Even though the site I had there was terrible, I did learn some of the very basics constructing it.

Although I had long forgotten Geocities I definitely felt a little nostalgic when I learned of its demise.  Via Con Dios, Geocities.

Anyone else a little misty eyed?

imafan of imakey

I use a USB drive almost every single day. I have a problem keeping up with USB drives and caps so this can be problematic. † Enter Lacie’s imakey USB drive. I never would have thought I’d be dorky enough to carry a USB on my key ring, but this looks so much like a key I’ll risk it.

Lacie imakey USB drive

Just got it in the mail today. It’s sweet.