- This topic has 12 replies, 3 voices, and was last updated 3 years, 3 months ago by
David.
-
AuthorPosts
-
December 22, 2022 at 11:20 pm #2471198
ch1800
Hello,
I’m still using WP Show Posts on some sites and it works fine with Classic Editor.
But when clicking on WP archive pages for categories or tags I’m getting a different layout than those created by WP Show Posts and it’s normal.In order to have something homogeneous, is there a way to redirect archive pages to specific WP Show Posts lists that I create for them?
PS: I know that WP Show Posts is no longer supported, thanks.
December 22, 2022 at 11:27 pm #2471203Fernando Customer Support
Hello there,
Here’s an article for that: https://docs.wpshowposts.com/article/use-static-pages-as-category-archives/
You can also opt to use a Block Element – Loop Template if you’re open to using the Block Editor.
December 22, 2022 at 11:29 pm #2471205ch1800
Great, many thanks!
The first link will do the job just fine as I never use those terrible blocks.December 22, 2022 at 11:30 pm #2471207Fernando Customer Support
You’re welcome!
December 23, 2022 at 6:10 pm #2472007ch1800
Just to be sure I understand correctly:
I get it the page needs to have the same slug as the category but in the following section:
if ( isset( $query_vars['category_name'] ) ) { $pagename = $query_vars['category_name']; $query_vars = array( 'pagename' => "$pagename" );should I edit only the “category_name” or also the “pagename” in this snippet?
December 24, 2022 at 5:15 am #2472249David
StaffCustomer SupportHi there,
you don’t need to change anything in the code, it does it all for you.
ie. if the query var is a category then make it a page that has the same slug as the original category.If you have a LOT of categories, each of those will require a matching static page and WP Show Post lists, which can be a lot of work. Maybe we could style the archives to look like your WP Show posts lists ?
December 24, 2022 at 6:51 am #2472322ch1800
Thanks for the clarification, got it.
But yes, I think you are right for this particular site, which is mainly an archive of press clippings.
Too many taxonomies and making the archive pages look like those of WPSP would make more sense.I tried to play a bit by myself but I failed.
I include here the related links; if you have time for help it would be great.
Nothing urgent though.PS: I’ll post also another remark on my other post about post archive listings as it’s for the same site.
December 24, 2022 at 7:10 am #2472334David
StaffCustomer SupportMaybe:
1. Customizer > Layout > Blog –> Featured Images >>> Archive tab.
1.1 Set the Location toBelow Title
1.2 Check: Display Padding Around Featured Images2. Add this CSS:
.separate-containers .generate-columns .inside-article { padding: 10px; text-align: left; } .generate-columns .entry-header, .generate-columns .entry-title, .generate-columns .entry-header, .generate-columns .entry-meta, .separate-containers .generate-columns .inside-article .post-image { margin-bottom: 10px; } .generate-columns .inside-article .entry-summary { margin-top: 0; } .generate-columns .entry-header, .generate-columns .entry-meta { text-align: left; font-family: Overlock, display; font-weight: 400; font-size: 1em; }December 24, 2022 at 7:29 am #2472351ch1800
Wow, this is impressive!
In fact I now like this result more than the one by WPSP and I really wonder if I’ll replace those made by WPSP with those archives as, for this particular site, there is no real need of the plugin.Thanks a lot and happy holidays!
December 24, 2022 at 7:30 am #2472353David
StaffCustomer SupportGlad to be of help!
And Happy Holidays to your too !!December 24, 2022 at 7:32 am #2472355ch1800
PS – sorry I forgot:
why is that the title of those archive pages is aligned that way, half on the way to left alignment but no there yet?
Is there a way to get it centred?December 24, 2022 at 6:02 pm #2472656ch1800
I added this, seems to work:
.separate-containers .page-header { text-align: center; }December 26, 2022 at 3:58 am #2473525David
StaffCustomer SupportGlad to hear that !
-
AuthorPosts
- You must be logged in to reply to this topic.