TwentyEleven Child Theme Learnings

For the past week or so I’ve been playing around with a TwentyEleven child theme for a soccer team project I am fiddling with.  For the most part I’ve been able to accomplish what I want using a TwentyEleven child theme.  Using TwentyEleven as a base for this project isn’t bad but it certainly is different than using a theme framework (e.g. Thematic).

Last week I had posted that I didn’t care much for how the header was constructed and after working with it for a week, I still feel that way.  TwentyEleven has a number of filters and actions but customizing the header isn’t among them.  I also find it very odd how the default behavior is to use featured images as the header if there is one available.  I can’t imagine what application that turns out to be a good thing.  Fortunately it is fairly easy to disable that and set your own header.

TwentyEleven has a showcase template that is sort of like a magazine style but not exactly.  For it to work it requires that posts be tagged as “sticky” which also means they appear at the top of the list in a standard chronological post view.  What I really wanted was functionality like the showcase for the latest articles and let that view become the default home page.  I was able to accomplish this by copying the showcase.php file from TwentyEleven into my child theme directory and calling it latest-news.php.  I now have a new template that shows the five latest posts using the featured content slider which TwentyEleven has built into the showcase template.

Now that I have it working, I am finding that images in the showcase template are wonky and adding a featured image really messes things up.  I am sure I’ll figure it out but the decisions the theme designer(s) made in this area are odd.  It’s like having an 80% solution but the other 20% will take a while to work out.

The one thing I am pretty happy with though is how well it seems to work on my iPad and I didn’t have to do anything special to make it work.  It just works which is nice.  Once I am done with this I will probably turn it into a generic soccer theme but for now it is really only useful for CASL teams.

Read-Only Google Forms?

This morning I added a new feature to my WordPress Google Form plugin.  You can now set a form to be ‘read only’ using the readonly=’on’ attribute in the shortcode.  This option, when turned on, use a little snippet of jQuery to disable all of the form elements.

[gform form='<long_url_to_your_google_form>' readonly='on']

I suspect your immediate reaction to this is “why would I want my form to be read only?” and it is a logical reaction.  After all, the whole point of creating a form is to collect data right?  The purpose of some forms, in fact I’d bet it is the case for most forms, is to collect data for some period of time and after a certain point (e.g. 5:00 PM on October 31), there is no reason to collect data any longer.

Imagine a sign up sheet for working the snack bar at your local High School football game.  Once the game has happened, there is no value in letting people sign up any more.  The readonly option will allow you to retain the form as part of your WordPress web site while preventing the collection of any more data.

I need to do little more testing before I release an update but so far, it looks pretty good!

Note:  The more I think about this, I may want add an expire option after which the form will automatically become read only.

Support for multi-page Google Forms?

I received an email the other day about my WordPress Google Form plugin wondering whether or not it should work with multi-page Google Forms  It hadn’t even occurred to me to test it as none of the forms I had needed myself were multi-page forms but my gut reaction was I didn’t think it would work.

I took a look at a multi-page Google Form and have determined that the current (v0.10) version of the WordPress Google Form plugin (aka wpGForm) will not work with multi-page forms.  No real big surprise but I want it to be clear before someone else wastes their time trying to make it work.

From looking at the form code it may be possible to support multi-page forms in the future but it will require some additional jQuery scripting and more importantly, some time to dedicate to it.  I hope to look at this soon but I have a couple of WordPress theme projects that I need to get off my plate before I can go back to wpGForm.

WordPress Google Form v0.10 released

Yesterday I committed the final changes (and still missed a few typos – ugh) to the WordPress plugin repository.  The v0.10 release addresses the problems with required fields on a Google Form.  I’ve heard from several people who’ve told me this fixes the problems they were seeing but if you run into something, add a comment here and I’ll do my best to take a look at it.

Note:  I’ve also changes the beta download link to resolve to the WordPress download so the beta is no longer available.

WordPress Google Form beta update

This morning I fixed a bug which occurred when the default CSS was not enabled (which it isn’t by default).  When the default CSS was not enabled, the jQuery Validation plugin wasn’t loading and then the jQuery script that initialized the validation would fail.

If you downloaded the beta prior to 10:00 EDT on 10/7, you should download it again and re-install.

[download#7]

WordPress Google Form bug with required fields

Google forms allow fields to be designated as required.  When running the form using the standard Google URL, the form will be validated and presented back to the user if any of the required fields are not entered.  There is an issue (aka bug) with required fields in the current version of the plugin.

If a user submits a form that is embedded in WordPress using the plugin, because there are missing fields the form processing does not complete.  There is no indication for the user that something is wrong, the form is simply presented again without any of the fields having data in them.

To resolve this I am looking at doing form validation on the client side using a jQuery plugin.  Hopefully I will have this resolved fairly quickly as I need this to work correctly for my own project.  My testing didn’t take into account a user not completely the form correctly.  Oops.  This bug affects all versions of WordPress Google Form up to and including v0.9.

Stay tuned.

Screen shots added to WordPress Google Form plugin

I have added the missing screen shots to the WordPress Google Form plugin.

The plugin has been updated to v0.9 and will appear in the WordPress Updates on the Dashboard.

wpGForm plugin updated to v0.8

Over the past 24 hours I have committed a number of changes to my wpGFrom plugin.  The WordPress auto update process sometimes takes a little while to recognize a new version is out there but v0.8 should appear fairly soon.  I actually updated it a couple times so you may have seen v0.6 and/or v0.7 show up as well.

This update addresses two bugs (the spurious output of CSS and embedded Javascript) and also adds some new features.  Check out the Changelong on the WordPress plugin repository for more details.  I’ve been using the plugin for one of my own projects and to the best of my knowledge, it is working ok.  If I don’t run into anything else in the next week or two, I’ll bump the version to 1.0 and call it ready.

Child theme or not? That is the question …

Off and on over the past few weeks I’ve been working on a Thematic child theme.  I’ve always had a hesitation with child themes in that you need the parent theme in order for the child theme to work.  Duh.  While it may be pretty obvious to anyone who is familiar with WordPress, it isn’t so for the casual user.

When I was working with Sandbox I figured out a way to essentially build a child theme while ensuring that the parent theme dependency wasn’t an issue by including all of the Sandbox code  using a SVN external reference to Sandbox and some other tricks to include the code.  It worked well and I was able to distribute my themes without concern as to whether or not Sandbox was installed.  It simply didn’t matter.

I was not planning to do that with the Thematic child theme I am working on right now but am having second thoughts.  It turns out that the version of Thematic that I need (0.9.8) is not the version which is in the WordPress Theme Repository and I have no idea when this will change.

If I got the SVN external route again I can ensure that my child theme will work with a known revision of Thematic.  However, it is a fundamental shift in my approach and I don’t know if it will work the same way I did it with Sandbox.  Decisions, decisions.

It looks like there have been some recent commits to the Thematic SVN repository so maybe it will be updated and released soon.  That would help address my dilemma.

wpGForm v0.5 fixes Settings page bug

I have just committed v0.5 of the WordPress Google Form plugin.  It addresses the problem with the Tabs on the Settings page not working correctly.  It turns out that I had a couple of problems which were masked by the theme I was using.  I have moved my development environment back to the stock Twenty-Eleven theme and turned off all other plugins.

By doing this I determined that the jQuery UI libraries I expected to be loaded, were in fact, not loaded at all.  They were being loaded by the theme!  Once I got the libraries loaded correctly the Tabs started working but they didn’t have the proper styling.  WordPress doesn’t appear to include the jQuery UI CSS so I ended up loading it from Google’s CDN.

Everything seems to be working correctly now, v0.5 should appear as an update shortly if it hasn’t already.