I'm getting a little tripped up on the best way to work with the Genesis hooks and filters.
Specifically I have a custom post type with a bunch of custom fields and am currently working on the single post template for this CPT.
At this stage I'm just basically adding my custom functions to display my custom fields to the genesis_entry_content hook.
But I need to be more precise in my layout on this template. I'm wanting to use the genesis column classes but am a little unclear on how to do this. For example, I'm wanting to create a couple of columns and display the_content() in one, maybe with some custom fields in that same column, and to also display my other custom fields in a second column.
Any suggestions on how to get started with this would be appreciated.
First, you'll want to be just editing this specific template. So the file to use would be something like single-yourposttype.php, and it should be located in the same folder as your child theme's functions.php file.
More on that here: http://codex.wordpress.org/images/1/18/Template_Hierarchy.png
The content of this file should look something like this:
// your functions here, using hooks and filters
So far as using the Genesis column classes are concerned, there are lots of things you can do!
Here's more information on using those: http://my.studiopress.com/tutorials/content-column-classes/
One solution might be to look at how the AgentPress theme and Listings plugin uses custom fields as they also output in columns and generate meta boxes on single CPT Edit screens.
Volunteer who’s written 1814 tutorials & 3000+ Code Snippets for members – Not For Hire.
Thanks for the replies, much appreciated. Will look at the AgentPress theme, thanks!
You must be logged in to reply to this topic.
Subscribe to get early access to new themes, discounts and brief updates about what's new with StudioPress!