Support Forum

Please login to receive premium support.

Support for the free plugin can be found here.

Home Forums Pro Support Caching issues? Categories not styled as assigned Reply To: Caching issues? Categories not styled as assigned

#6728
Jason
Participant

Thanks Tom, I think I’m almost there. I copied the archive.php into my child theme and replaced get_template_part() with the code from the other post but replaced my WPSP post id of course.
Here’s my code snippet in archive.php:

`/* while ( have_posts() ) : the_post(); */

/*
* Include the Post-Format-specific template for the content.
* If you want to override this in a child theme, then include a file
* called content-___.php (where ___ is the Post Format name) and that will be used instead.
*/
if ( is_single() ) {
$cats = get_the_category();
$cat = $cats[0];
} else {
$cat = get_category( get_query_var( ‘cat’ ) );
}
$cat_slug = $cat->slug;
wpsp_display( 13607, ‘tax_term=”‘ . $cat_slug . ‘”‘ );

/*endwhile;*/`

Here is a page with the results: https://keepmake.com/stage1/category/food-drink/

I have a few questions about the result:
Why is the footer hanging right below and behind the header? Do you know how to correct that?

Other than that, I’m pretty pleased that this works and for all your help and patience with this.
If you have any ideas on how to make this more modular – meaning perhaps different WPSP layouts for different categories or maybe some integration into the GP Elements section that would be an added bonus.

I could see this becoming a future feature of WPSP perhaps. The idea of duplicating all those layouts for separate pages for 20 some categories (and no duplicate/clone feature) was something I wanted to avoid.