Archives for October, 2009

Loading WordPress’ Thickbox Only When Needed

I like to use Thickbox on my site to display images and videos in overlay windows. In WordPress, it’s easy enough to use wp_enqueue_script( ) and wp_enqueue_style() to load the built-in version of Thickbox. It automatically takes care of including jQuery, putting the css in the header, and the javascript in the footer.

But there’s no need to have the bloat of Thickbox and jQuery loading on all pages when most of them don’t even use it. That’s why Joost de Valk detailed a nice tip to only load thickbox when needed by checking the page content for references to it. All it takes is a few lines of code in your functions.php file.

Unfortunately, you end up with some broken images because the built-in Thickbox defines their locations in thickbox.js as relative paths: [ Continue reading Loading WordPress’ Thickbox Only When Needed … ]

Chopping Down an Entertainment Center

I’m taking a break from my usual geek content for a woodworking project. Granted, it’s a woodworking project to contain geek stuff, though.

We purchased a nice solid oak entertainment center many years ago. But it’s worthless now in an age of widescreen TVs. I tried to sell it, and then later give it away, with no takers. It had been taking up way too much room in the garage for more than a year. [ Continue reading Chopping Down an Entertainment Center … ]

  •  
  •