Jump to content
Sign in to follow this  
ptrubey

Editing category pages

Recommended Posts

ptrubey

I'm looking to modify the behavior of specific category pages. One type of category, I'll just show the post titles, another category, I'll have shortened excerpts, etc. What do I need to edit/create to do this? Thanks a bunch.

Share this post


Link to post
Share on other sites
Kate

Hi Philip, You can modify the file responsible for displaying posts. You can insert some type of if statement in there. If you're using PlatformPro, this would be template.postloop.php. (Other themes would be _posts.php.)

Share this post


Link to post
Share on other sites
ptrubey

Thanks - I am using PlatformPro, and have activated PlatformBase. So would I copy the template.postloop.php file from the platformpro directory into the platformbase area and then edit it there?

Share this post


Link to post
Share on other sites
cmunns

Yes that is exactly what you would do to modify the main loop

Share this post


Link to post
Share on other sites
ptrubey

OK, as I read more docs, I am maybe realizing there is another way, and that is to put code into the base's functions.php (misspelled as function.php in the pagelines docs) that uses hooks? Is one way preferred over the other? Seems to me that using hooks would be preferred in case a theme update actually modifies template.postloop.php.

Share this post


Link to post
Share on other sites
ptrubey

Well, I wasn't quite sure how to do what I wanted to do via hooks, so I did what Kate and Adam suggested and edited a copy of the template.postloop.php file stored in the base directory. It worked although I couldn't do exactly what I wanted without one CSS gyration too many, so now I'm looking at creating a special page. Thanks.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this  

×