Created in Gran Turismo 5's Photo Mode and enhanced with Adobe Photoshop CS5.

Javascript Race Conditions

Posted

I’ve encountered a couple issues with javascript race conditions this last week, especially in the Chrome browser.

A race condition is where the timing of one event is critically tied to other events which need to happen before it in sequence. In both situations I was enqueing a javascript file, but I also had inline javascript that wouldn’t work until the enqueued file had completely finished loading.
Read more

new-thematic-options

Thematic Options Panel

Posted

Updated: 3/19/12

The latest version of this Thematic Options theme has been completely rebuilt to use the Options Framework Plugin. It’s rather basic and has just a couple settings- but if there’s something else you’d like to see in it please file a ticket or send over a pull request on GitHub.

If you’re interested in building options for a theme other than Thematic, please check out the Options Framework Plugin or the Options Theme.

You can download the latest version of the Thematic Options on GitHub.

More Tags or Excerpts

Posted

Explanation of Excerpts

There’s two ways main ways to display posts on the home page and archive pages in WordPress. The first is to use the_excerpt tag, which checks to see if an excerpt has been manually entered. If it has, WordPress will display it. If it hasn’t, it’ll take the first 55 words from the post and display that instead.

Using the_excerpt is a perfect way to display a tiny snippet of the post so people can easily scroll through all the topics. When using the_excerpt, WordPress will also automatically remove any images or html tags that might mess with the layout in a shortened version.
Read more

How to Add Custom Post Type Icons

Posted

I recently updated Portfolio Press to use new icons for its custom post type. The previous icon worked fine, but it didn’t exactly match the rest of WordPress core. I was also lucky enough to have Ben Dunkle, the designer who created the current set of core WordPress icons, offer to make me a new one.

[Note, I no longer recommend including custom post types from a theme. Here's my Portfolio Post Type plugin on GitHub if you want to see example code]

I have a zip file of the icons I used (in psd format) which also has some other options we considered (briefcase, nicer weird eyeball) and the png files of the final choice. Feel free to use this in your own projects that need a portfolio icon. You can download it here.

There’s also a great collection of free custom post type icons available here for download which might have other icons you might be looking for.
Read more

option-feat

OptionTree Plugin Review

Posted

Derek Herman just released OptionTree, a plugin that makes it easy to set up theme options in WordPress. You can easily add uploaders, colorpickers, radio boxes, text inputs, textareas, etc to a panel- and even more advanced stuff like post, tag and page selectors.

The interface as a whole is really nice- similar to GravityForms for the options set up and the WooThemes options panel in terms of actual design. I haven’t dug into the code too much, but it seems well written and commented.
Read more

TypeKit on Body Text

Posted

There are a number of solutions for rendering “non-standard” web fonts on your site.  I was familiar with ones like SIFR and Cufon where it’s recommend to be used only on headers or certain spots of the website.  I e-mailed TypeKit to see if it worked the same way, and got this reply from Mandy Brown:

“There’s no file size or speed issue with using Typekit for body text (as there would be with, say, using SIFR or Cufon). That said, you should make sure to use a font that works well at small sizes and renders acceptably cross-browser. Be sure to take a look at the browser screenshots before deciding on a font.”

Oddly, Google failed me on this question, so I thought I’d post it here for anyone else who was curious.

demand

What’s Next for WP Theming

Posted

I’ve been working as freelance web developer for the last couple years working almost primarily with WordPress. I’ve enjoyed every minute of it, but I was recently offered the opportunity to work full time with Demand Media.

Demand Media runs eHow.com, Trails.com, Livestrong.com (among others) and social widgets that are viewed on millions of pages per day. It’s a really exciting company and position. Couldn’t pass it up. I start today, which also just happens to be my 29th Birthday.
Read more