jQuery, jQueryUI, jQuery UI widgets and theme options

Over the past few days I have been dinking around with jQuery, in particular some of the jQuery UI widgets.  I am working on a revamp of a LEGO WordPress theme and I wanted to allow the theme to support multiple color schemes and custom headers.  This is a learning project for some other themes I want to update (e.g. Swim Team and Soccer).

For the header I wanted the user to select 1-3 images from the media library to use in the header.  I also wanted to allow some styling control over the blog title and tagline and lastly choose a color scheme from a selection of 10-12 choices.  All of this information would make for a very busy theme options page so I decided to make use of the jQuery UI Accordion widget to logically group information into sections.

My theme development area was still running on WordPress 2.7.1 which includes jQuery 1.6 which is not the most recent version.  I should have upgraded WordPress before embarking on my Accordion experiments, I would have saved myself a bunch of time!

As it turns out, Accordion isn’t shipped with WordPress so I have to download it and install it as part of my theme and then load it.  This isn’t a big deal, there are lots of posts across numerous blogs that explain how to load Javascript correctly.  No matter what I did, I couldn’t get it to work.  I played around with jQuery UI Accordion and half a dozen similar solutions trying to get it to work but I could only get one solution partially working.  In the end, I decided to try updating WordPress and start with the latest and greatest.

What do you know?  My Accordion worked perfectly!  So after wasting the better part of two days trying to work with what I had installed, simply updating WordPress was the right answer.  I think the real change was in the jQuery UI ui-core component as at one point I had Accordion working in the older version but only when I loaded the custom packed jQuery download.  When I loaded just the Accordion source file it wouldn’t work.  The custom packed file included something out of jQuery UI ui-core, what I don’t know but it made a difference.  When I looked at the jQuery code in the 2.8.4 release I noticed the ui-core component also had this function where as the 2.7.1 did not.  So something was definitely different and it make a big difference.

Now that I have the Accordion working I am back to making progress on my theme options page.   I have played with jQuery just a bit, this is the first real jQuery application I have worked on.  It is pretty powerful, I can see why it has gotten so much traction.

Continuing with Sandbox

I asked the other day if Sandbox was dead and even though there was a minor update, it appears that Sandbox isn’t really dead but it is in a purgatory of sorts.  Not dead but not actively being developed either.  So

Soccer season has started and I need to update the Soccer theme I used for my daughter’s team because they changed uniform colors.  Since I had based the Soccer theme on Sandbox, I could either continue with it or start again.  For now I am continuing with it because (a) I know it pretty well now and (b) it works.  However, I do want to check out the Elastic theme editor I heard about recently on the WordPress Weekly podcast.

When I did the MacDolphins theme this past spring, I had based some of that work on the Soccer theme but was able to fix much of what had bothered me, in particular, the need to install the Sandbox theme itself and the Soccer theme as a child theme.  I love the idea of a child theme but for the casual user, the relationship between parent and child theme isn’t real obvious and failing the install the parent theme results in a non-functional blog and likely frustration.

By structuring the theme architectures such that it referenced the Sandbox source as a SVN external, I was able to bundle all of the files for the parent theme and child theme together as one theme.  This makes distributing the theme much easier and also solves the problem where the theme preview shows the parent theme instead of the child theme.  This preview problem doesn’t affect the functionality of the site but it is confusing if you don’t know what is going on.

I expect to have the soccer theme updated in the next week or so and probably offer a few more color schemes.  But first I am working on a Sandbox based LEGO theme which I’ll finish first because the NCLUG and NCLTC web sites sorely need an updated theme as the one they have now are old and don’t support widgets.  This LEGO theme is a good exercise in setting theme options, particularly the header area as I expect I will need it to make a generic version of the MacDolphins theme for any swim team to use.

Is Sandbox dead?

I had really hoped that Sandbox would see new life when ownership of the domain and it’s assets changed hands (see Scott Wallick’s post on offering plaintxt.org for sale).  The link to the posting on plaintxt.org no longer exists, apparently the new owner deleted the original post.

There hadn’t been any posts on plaintxt.org or sndbx.org in a long time.  There was a small amount of traffic in the Sandbox Forum but nothing substantial.  I really like the simplicity of the Sandbox theme and gone ahead and used it on a couple projects even though it hadn’t been updated in a while.  I figured with new ownership, it was bound to start again at some point.

Maybe I was wrong?  I don’t know.  I have been thinking of revisiting my Soccer theme since after using it for the CASL Ambassadors over the summer, I found a few minor issues with it.  As I thought about updating it I kept thinking I should switch to a framework actively being worked (e.g. the Carrington theme?).  So I went back and took a look at the PlainTxt blog and what do you know?  A post!  A minor security update was added to the Sandbox theme back in July.  Was development active again?  Poking around it appears that no, not really.  Scott Wallick had made the change not the new owner who ever that is.  Other than a couple comments asking the same questions I was pondering (has development started again?)( there wasn’t anything else.  Bummer.

Now what to do?  Continue?  Fork?  Pack up and move on?   Decisions, decisions …

MacDolphins WordPress Theme

I have had a couple people ask me for the MacDolphins WordPress theme to use as a starting point for their own swim team.  The MacDolphins theme is built on top of the Sandbox theme framework and I am happy to share it.

I have toyed around with a couple of themes but this is the first one I think is robust enough to share.  It does have a few issues left to fix (e.g. sticky posts) and I hope to do that soon.  If you end up using this theme, please make sure to credit the Sandbox theme as without it, this theme isn’t possible.

MacDolphins Theme – updated 5/28/2009 @ 11:10 PM
[download#9#image]

Theme Collection

In my quest for theme ideas, I ran across this interesting post.  It is a collection of ~140 WordPress themes.  The thing I like in particular about this article is the way the themes are presented.  The images are large enough that you can actually see the design without having to navigate away from the article itself.  I wish more theme sites did this.  It would make browsing themes much easier.

Theme Frameworks

I want to use a theme framework to develop a couple themes.  Why do I want to do this?  Because I don’t want to reinvent the wheel.  There are several to choose from or I could write my own.  I really don’t want to write my own.

Frameworks

I am sure there are more but these are the ones I have looked at.  I had pretty much settled on Sandbox as I found it easy to work with and there was some discussion a while ago about including it as part of WordPress.  I was a bit concerned that it hadn’t been updated since last summer but thought "hey, maybe it is done”.  So I started playing around with it for my LEGO Blog.  What is there now is very much a work in progress.  I got it working enough that I could see where I was going.

Then I saw this:  http://www.plaintxt.org/2009/01/looking-for-a-wordpress-brand/

Uh-oh.  What is the future of Sandbox?  I posed a question on the Wp-Hackers mailing list but the thread went wildly off track and it was  never answered.  The comments on the announcement indicate that it might end up as part of WordPress but other than that, I haven’t seen any other mention of it anywhere.

I am reluctant to invest more time in a Sandbox based theme until I know where it is headed.  I guess I’ll go back and look at the others again.  I really like the idea of child themes so I want to explore this some more before giving up.

FireBug: Indepensible for theme development

I have yet to code a WordPress theme from scratch.  I have found something I like and started from there.  For the MacDolphins web site, I had found something simple a while back and it served it’s intended purpose but it wasn’t without issues.

As the site has grown, the need to tweak the side bar in particular has increased.  I found an extension to FireFox called FireBug which has made this process significantly easier.  I am using FireBug to chase down CSS conflicts and oddities but it does much more than I realized.

My theme now works correctly even if it isn’t visually very exciting.  The mouse overs no longer overflow the sidebar for 3rd and 4th level deep menus.  I was able to resize the sidebar and the overall content area without things ending up in the wrong spot.  If you dink with themes, FireBug is really helpful.

Silver Light 0.1 theme installed

As I was sitting here noodling on how to implement SDIF, I kept staring at the default WordPress theme on this site and it became a distraction.  So I took five minutes and found a theme to load – Silver Light 0.1.  It’s ok, I don’t particularly care for the footer but it is better than the default and now this site looks a little better.

Blog Theme or lack thereof

For the time being I am using the default WordPress theme for this blog.  I’ll change it in the next week or two – for now I am happy it is installed and working.  I love SourceForge – what they offer for developers is A+ but I am still figuring how all of the services they offer work together.  I need a good SFTP client, I don’t think FileZilla supports it but I could be wrong.