WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] [Plugin: Custom Post Template] Use with Thematic and Gallery child theme (8 posts)

  1. NativePaul
    Member
    Posted 4 years ago #

    I'm trying to customize Chris Wallace's 'Gallery' child theme for Thematic.

    I want to use the Custom Post Template for certain posts but it doesn't work because of Thematic's structure.

    Can anyone tell me how to use this plugin with these themes?
    I tried creating a new php file and selected it from the plugin drop-down list but the post still used the standard layout specified by the Gallery child-theme.

    I guess I should add it to the functions.php file but have no idea what code to add.

    Any help would be appreciated.

    http://wordpress.org/extend/plugins/custom-post-template/

  2. NativePaul
    Member
    Posted 4 years ago #

    I haven't found an answer to my question, but I did find a solution to my problem.

    It seems like a messy way to do things, but it gets the job done. This was inspired by hacking myspace css to create custom layouts.

    I wanted some posts to display at the full width, without a large gallery image. The easiest way to achieve this was to just add some CSS to the actual post (in html mode).

    `<style>
    .single .artwork-container{display:none;}
    .single .entry-content{ margin: 20px 0 0 20px; width: 900px;}
    </style>'

    The first line hides the artwork container.
    The second line resizes the post content by reducing the left margin and increasing the width of the container.

    If anyone can offer a better solution, I'd love to hear it.

  3. simonwells
    Member
    Posted 4 years ago #

    Native Paul,
    I have started a tutorial guide for the Gallery theme by Chris>
    It still is a Work In Progress but covers certain aspects of installing and tweaking.
    Currently it all from my experience of the theme, but slowly writing in some users tips too, which I would like to add you hack to.
    Hopefully we can find a better solution for you.

  4. fezzicnex
    Member
    Posted 4 years ago #

    @simonwells what is the website you are referring to. I'm looking into tweaking the gallery theme and I need help.

  5. NativePaul
    Member
    Posted 4 years ago #

    Hey Simon
    You can gladly use my hack. I've made quite a few modifications to the gallery theme. Hopefully I've found a few more effective ways to use it.

    I plan to write a blog about it at some point. I'll post a link in the forums when I eventually do that.

  6. holling
    Member
    Posted 4 years ago #

    Hi NativePaul -

    I know this comment is late, but, better late than never.

    We got around this issue by putting the template into the Thematic directory instead of the child theme dir. Quite defeats the purpose of a child theme, of course, but it got the job done.

    Best - Holling

    ps. site in question (my design has been destroyed since the site launch) : http://www.meatlessmonday.com/

    pps. post template is most easily seen on their recipes.

  7. helgatheviking
    Member
    Posted 4 years ago #

    My comment is also massively late, but I just just ran into the issue of this plugin not working w/ child themes. The problem is that the plugin uses TEMPLATEPATH, which is Thematic or whatever parent framework we are using. So here is what I did to the custom-post-templates.php to get the plugin to use the child theme's folder.

    add to beginning:

    // Set constant for current theme directory
    $dirname = get_stylesheet_directory();
    define('STYLESHEETPATH', $dirname . '/');

    then change:

    $custom_template = TEMPLATEPATH . "/" . $template_file;

    to

    $custom_template = STYLESHEETPATH . $template_file;

    obviously it is not ideal to go hacking away at plugins either for the same reason as putting the template in the Thematic directory.

  8. helgatheviking
    Member
    Posted 4 years ago #

    can't seem to edit my post- but the development version of this plugin fixes this issue and works with child themes, so i suspect it will be working with the next update.

    http://wordpress.org/extend/plugins/custom-post-template/download/

Topic Closed

This topic has been closed to new replies.

About this Topic