Something I discovered at WordCamp San Francisco over the weekend shouldn’t come as a great shock: I’m not the only developer/designer who can’t / doesn’t keep an updated blog. Who’s got the time?
I made a sort of promise to myself the other day and that was to try to blog at least once a week. With all of the troubleshooting and tinkering that goes into any Web project, it shouldn’t be that difficult for me to outline the problem and solution right here on WerdsWords. So that’s the plan, we’ll see if I can follow through. Call me out though if you start to see weeds growing up between the cracks.
Wow, OK, so this is a random collection of thoughts after #WCSF last weekend.
Never before have I dreamt, thought about or immersed myself in so much WordPress in such a short amount of time.
#WCSF proved to be ample opportunity for networking, learning, eating and traveling. I met a lot of really passionate people out there from bloggers to developers, designers, entrepreneurs, web hosts and many of the people behind the mammoth that WordPress has become. It really was a fun time.
So here’s a shoutout to Adria Richards, Theme.fm, bluehost, Dream Host, the guys over at Media Temple, Matt Mullenweg, Brad Williams, Jeff Kropp, Lou Anne McKeefery, Pete Mall, Brian Tickler, Dan Ross, the guys over at StudioPress, Adam Chew, Linda Sherman and many others.
Probably the best-spent 3 days I’ve had in the 3 years I’ve been developing and designing for WordPress. Until next time!
According to a recent WordPress trac ticket, theme authors could soon be rewarded with a little nugget of functionality that would make using child themes much more extensible.
The ticket suggests introducing a function that works similarly to locate_template(), but rather than returning the path of the file (in the parent theme only), it would return a URI to the file, thus allowing a child theme to override the parent’s .js, .css and even image files. The proposed function is called locate_theme_file().
According to the suggested patch posted by johnbillion, this is the current method for loading template files in parent themes only:
<p>wp_enqueue_style( 'dark', get_template_directory_uri() . '/colors/dark.css', array(), null ); </p>
If locate_theme_file() is introduced, we could instead see functions like these:
<p>wp_enqueue_style( 'dark', locate_theme_file( 'colors/dark.css' ), array(), null ); </p>
<p>wp_enqueue_style( 'bar', locate_theme_file( 'bar.css' ) );</p>
<p><img src="<?php echo locate_theme_file( 'icon.png' ); ?>" /></p>
locate_theme_file() would automatically load any of these files via the child theme, BEFORE the parent. Pretty neat huh?
Up to this point, child themes could only override a parent theme’s template files. If theme authors are rewarded with the ability to enqueue many more types of files at the child theme level with this much ease, I anticipate seeing some really exciting new uses for child themes emerging.