This is searchable archive of our old support forums, which operated from 2012 - 2016. To find out how to get support for your current theme, please visit our support page.

Tagged: ,

How to extend post list template?

  • Creator
    Topic
  • #14387
    smlombardi
    Member

    I need to have 2 different “blogs” on my site. I am going to have the posters use 2 different categories, one for each blog. So, I need to duplicate modify the blog list template so I have 2, one which selects each category only.

    I am a WP developer and no how to do this with a vanilla theme like 2011, but unsure how to do it with Akita. Can you please point me to the relevant code and where to insert a custom query parameter?

    Unless, or course, you have a better way to do this. Thanks,

Viewing 3 replies - 1 through 3 (of 3 total)
  • Author
    Replies
  • #14397
    Jason Bobich
    Keymaster

    Hello,

    There’s no need to make any theme customizations to accomplish this. Our Post List and Post Grid page templates take custom fields that can modify which posts display in that instance of the template. For example, add a custom field with name “category_name” and value the slug of the category, and it will filter the page of posts by that.

    These available custom fields are listed in your documentation that came with your theme. You can also use this plugin to add a meta box of all of these custom fields:

    http://wordpress.org/plugins/theme-blvd-post-template-options/

    #14399
    Johanna Heath
    Participant

    Hi Jason

    How can I apply the Post Template Options to a custom post type?

    #14405
    Jason Bobich
    Keymaster

    How can I apply the Post Template Options to a custom post type?

    There’s no feature for this, but you could filter them in like this:

    function my_post_meta( $setup ) {
    	$setup['config']['page'][] = 'your_post_type';
    	return $setup;
    }
    add_filter( 'themeblvd_post_meta', 'my_post_meta' );

    See the function “setup_themeblvd_post_meta” found in /framework/admin/functions/meta.php. I’m not quite sure if everything will be implemented right on the frontend though. You can play with it a bit.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The forum ‘Akita Responsive WordPress Theme’ is closed to new topics and replies.