Blogs for Bands Development

Gigs Calendar Template System

Since version 0.3, Gigs Calendar has come with a template system to allow for complete customization of the plugin’s display pages without extensive PHP knowledge.  Hopefully, this page will answer some questions you have.

Creating your own theme

The first thing you’ll need to do is to create a copy of the basic theme.  You’ll find it in the templates folder.  Do not modify or create new files here! My plugin will certainly read any modifications you make, but upon upgrading the plugin with WordPress’s built in plugin upgrade system, your modifications will be wiped permanently.

Instead, create a new folder in your wp-content folder.  Name it gigs-templates.  Now my plugin will read templates from this folder as well.  Copy the “basic” template, folder and all into your new template path.  Be sure to rename it to anything other than “basic”, or any other templates that I end up packaging with my plugin.  Once all of the files are there, you’re ready to start playing around.

Modifying your theme

If all you want to do is to make CSS changes, open up the style.css file in your new template and start hacking around.  If you want to make more significant changes, look at the other files within the folder.  It should be fairly obvious what they are.  Many of them have a little bit of PHP logic, so it helps to understand if…else and basic loop structures.  If you haven’t done any programming, you can probably tinker around, just upload the original file if you screw anything up too badly.

One thing I should point out is that the gigs-list has a large, probably confusing block of PHP code.  This block lets your users pick and choose which fields go into the list of gigs on their blog.  If this isn’t important to you, as you might just be using this on your blog or your design calls for specific elements, feel free to rip it out and just set up exactly what you want.  If you distribute the templates, be sure to let people know that they won’t be able to use the admin pages to select the fields they want in the list.

Comments

  • Blaise Alleyne 7:12 pm on August 23, 2008 | #

    Thanks, this was really helpful. Saved me a lot of time (and effort… considering any changes I made would have been overwritten on an update).

  • Fred Boak 6:30 pm on February 25, 2009 | #

    I’d love to see a way to have use the “select fields in the list” feature AND still customize the order of the fields displayed.

  • joel 10:23 am on February 27, 2009 | #

    hey dan, thanks for this resource.

  • Al Ingham 6:05 pm on April 22, 2009 | #

    Hi Dan
    I’m wanting to modify the next-gig widget template. I’m wanting to put the Gig Description below the Gig title. I’ve tried using
    “notes ?>” to get this result, but it doesn’t seem to be working?
    Is there extra code I need in order to get the description?

Leave a Comment

  • Recent Tags

    All Updates RSS

  • Blog at WordPress.com
    Prologue theme by Automattic

  • Order kamagra 100mg buy priligy online usa