Questions tagged [archives]

A page showing more than one post in the main loop.

Filter by
Sorted by
Tagged with
0
votes
0answers
24 views

How to disable single page for specific posts?

I need to disable single pages for specific posts, but only after specific condition. My code is here: add_shortcode('list-posts-basic', 'ant_post_listing_shortcode'); function ...
0
votes
1answer
21 views

How can I noindex my archive pages?

I am using the following snippet in my functions.php. function add_noindex() { if(is_archive()) { echo '<meta name="robots" content="noindex,follow" />'; } } ...
1
vote
2answers
12 views

Group Posts by Category in Monthly Archive

I'm using the monthly archives on my website but my loop is currently displaying my posts this way : Category title Post title 1 Category title Post title 2 etc.. What I want to do is displaying all ...
0
votes
0answers
19 views

Can I overwrite custom taxonomy FROM “public” TO “false”

I have custom taxonomy within my WordPress installation that I created with a WordPress Plugin called Pods. For various reasons, I need to set the registering of the loop from "public" to &...
0
votes
0answers
17 views

Author Archive Page redirecting issue

When I click "Author" Hyperlink anywhere on the website, It is not working. say, I click: https://digitalvarys.com/author/admin/ And It Redirects to http://admin/ Why is it? Refer the ...
0
votes
1answer
23 views

Change the text “search result for” on search result page

I've been searching thru all WordPress files for the phrase "search result for", which is displayed on the search result page (search result for (keywords)) but can't find it. I would like ...
0
votes
0answers
22 views

Taxonomy.php inheriting first post

I created a generic taxonomy.php file to list posts with certain terms. <?php get_header(); ?> <?php if ( have_posts() ) : while ( have_posts() ) : the_post(); ?> <a href=...
1
vote
1answer
21 views

Creating a custom archive template that sorts post by date

My site's default archive sorting is set to alphabetical, which I am happy with. However, I want to create a custom page template so I can also have an archive page which sorts all posts by date. I'm ...
0
votes
1answer
9 views

Simplest way to archive a Wordpress (and take down)?

I want to take down a Wordpress site but save it somehow. Is there a way to archive it?
1
vote
1answer
33 views

How to query for pages/post depending on slug?

I work on a blog that contains both English and Romanian posts. I made the site bilingual by prefixing the slug of every article with ro- and en-. It is a simple way and it works pretty well. Now I ...
0
votes
0answers
9 views

After submit a form redirects to search archive

I have a form which after submitting it redirects to thanks page but when I'm logged in as an admin and I'm submitting the form it redirects me to the search archive. Anyone have any idea why this is ...
0
votes
0answers
10 views

Add copy to individual taxonomy and term archive page

I have a product attribute setup as 'style' and a term of 'illustrative', so I wanted to add some seo copy to the bottom of the illustrative archive page of my woocommerce shop using the hook '...
0
votes
1answer
9 views

how to hide all posts under one category

Suppose I have a lot of posts under notices category. When I click on notices, it will display all posts one after another under the notices.Instead of displaying one post after another, how to hide ...
0
votes
0answers
15 views

How do I stop the same post showing multiple times in a archive?

For some reason the archives for my custom taxonomy is showing each post 3 times and I can't seem to figure out why. Here is the page: https://portfolioadviserlink.com/topics/esg/ $...
0
votes
1answer
18 views

Conditional post thumbnail based on logged status and post tag

I'd like to show different post thumbnails in archive.php and category.php like this: user logged out & post has tag "private" -> shows a "default-private" image user logged in & post has tag ...
0
votes
0answers
35 views

archive.php child theme

I am trying to implement an archive of all posts in my child theme as follows Currently I am playing with the following WP_Query which I put into archive.php in my child theme <?php $...
0
votes
1answer
37 views

Show the parent taxonomy by creating shortcode in woocommerce?

How would I create a shortcode to show the parent taxonomy in woocommerce? My product categories should be like: - Food -- Fruits --- Healthy Fruits --- Organic Fruits -- Meat --- Pork --- ...
0
votes
2answers
14 views

How to get post archives urls list without any markup?

I'm using wp_get_archives but I cannot prepend any text inside the links. I want code like this: <a href="archive link">[my custom prepend] 2020<a/> But the 'before' option will prepend ...
1
vote
0answers
26 views

A clean custom rewrite rule for weekly archives

Weekly archives are nearly undocumented, but WordPress can produce them, which I want. Good. But the URLs are ugly, eg. http://example.com/?m=2020&w=18 This gets partially rewritten to /2020/?w=...
0
votes
0answers
13 views

Category custom post type admin dashboard

I use the plugin to create custom entries and the taxonomy of CPT UI and use Categories (WP Core) for the category, but when I open the entries, I don’t have a category list on the side where I can ...
0
votes
1answer
21 views

Archive links for custom post types

How do you display a list of archive(last 6 months or so) for custom post types? Something like this: https://blog.evolveformazione.com/
0
votes
0answers
13 views

Add divider except for the first post of every month?

I'm making an archive page. Thus far it looks like this: April 2020 Name Of Post - excerpt. Name Of Post - excerpt. Name Of Post - excerpt. I want there to be a line between each entry except the ...
0
votes
0answers
21 views

Category filter in the archive

I want to display in the page.php all category (now it's do it) but when i click to a specific category, then it's go to the archive.php and dipslay me all category again, but i want display the post ...
0
votes
0answers
13 views

Set archives link only for certain categories on Wordpress

I have a sidebar that displays all post archives from a post-type. I wonder if there is a method, for taxonomy pages, to call only the archive dates of that taxonomy. Here is the main query: $months =...
0
votes
0answers
10 views

Wordpress Astra archive page: chronological numbering w/ reverse-chronological display ordering? [duplicate]

On Wordpress using the Astra theme I have archive pages containing titles and excerpts from 10 blog entries each, and when a new blog entry is written its title and excerpt go to the front. So the ...
0
votes
0answers
162 views

How to reverse the pagination numbers of an archive?

I have archive pages that each contain titles and excerpts from 10 blog entries. Both entries and archive pages are in reverse chronological order: when a new blog entry is written its title and ...
1
vote
0answers
77 views

Fetch Children of Grouped Products Inside WooCommerce Product Loop

I am overriding the WooCommerce archive-product.php in a child theme so I can list single products and grouped products. The loop outputs each product as a single item which is what I want for Simple ...
0
votes
1answer
15 views

Show title bar only on archives / hide it on all posts and pages

My theme has a title bar below the menu. The title bar displays the Title and a breadcrumbs menu. The code is in a template file called title-bar.php. The title bar now shows up on all pages and on ...
0
votes
0answers
9 views

404 on archive page with category and tag in url

Any archive page with a category and a tag returns a 404, for example: https://lespetitsproducteurs.be/categorie/recettes/etiquette/amande/ While archive page with category only works fine: https://...
0
votes
1answer
38 views

Custom Taxonomies Archive Page 404

I used the "Custom Post Types UI" and "Custom Fields" plug-ins to set up my structure. I have a custom post type called "artwork". This works fine. Posts have URLs like domain.cc/artwork/title-of-...
0
votes
1answer
121 views

How can I loop only months foreach year?

I have a Wordpress archive bar that loops foreach year that have posts, displaying the years and months. The output should look like this: //year output 2020 //month output month1 month2 month3 2019 ...
1
vote
0answers
19 views

Loop through years and months in Wordpress archives

In wordpress, Im trying to loop through every year archives, displaying a list of every mouth per year. The html output should look like this: //year output <ul> <li> 2020 //month ...
1
vote
1answer
23 views

How can I define a custom archive for childs of a specific category?

I want to show several comics I make without having to rely on plugins (already tried them, each has some limitations I rather just do the work on my own). So I made a parent category called Comics ...
0
votes
1answer
111 views

Pagination Not Working on `WP_Query` Archive Page

I have an archive page that pulls two different custom post types into an archive using WP_Query(). Because there is a home page to the site which shows 9 of the custom post type posts, I offset the ...
1
vote
1answer
130 views

List monthy archives for specific year with wp_get_archives

I just want a simple list with the monthly archives for one specific year. Like so: January February March April etc. I don't need anything fancy like yearly grouping. Ideally I would like a ...
1
vote
1answer
22 views

Custom template page with custom archives listing by user

I'm having an archive page for my post type. It's working, I'm using the template part with the get_post_type() parameters. content-activite.php: <?php $post_id = get_the_ID(); $post_thumbnail = ...
0
votes
1answer
32 views

Only display archive subtitle on the first archive page

I would like to only display the archive subtitle on the first archive page. Now, it shows at the top of every page. I am putting a lot of information with direct links in the subtitle of the tags (...
0
votes
2answers
118 views

Show icons or badges under title on product archives/category pages

I have a website that sells gaming related stuff, i need to show some buffs as icons/small images under every product below the product image, on the archive/category page, apparently there is no such ...
0
votes
0answers
42 views

Archive page for category/tag across all post types, grouped by post type?

I have a site about a city. The built-in post type is used for listings of businesses. For this, I have a taxonomy with categories like "restaurants" and tags used for the towns. I have several other ...
0
votes
0answers
29 views

Exclude category from function - PHP

I have the following code in my functions.php to move product category description to the bottom of the category page. remove_action( 'woocommerce_archive_description', '...
0
votes
1answer
30 views

Make custom post type archive for administrator only

Simply I have made a custom post type named ticket and have created an archive-ticket.php file I want to make if the user that tries to visit the tickets archive page is not administrator redirect him/...
0
votes
0answers
28 views

Custom Post type page content (archive page)

I have website with multiple Custom post types and I need to create an Archive page for each post type that also has extra content (short description and the like). The way I would about this would be ...
0
votes
1answer
28 views

Show All Custom Post Types On A Single Archive Page

I have 3 different custom post types on a site - is it possible to set up and archive page that shows all 3 of these custom post types (that will display in the default WP date order). The custom ...
1
vote
1answer
17 views

Automatically Give All Custom Post Types a Pre-Set Category [duplicate]

I am building a site with 5 different custom post types on and would like to create an archive page that pulls in all of these posts and then sorts them by the standard WP date order. Instead of ...
0
votes
0answers
20 views

Query distinct years in a category

I'm building out a custom archive widget that displays a select dropdown of months for each year. How can I extend this query to to pass $categories[0]->term_id? This is my query so far... $...
1
vote
1answer
31 views

Dynamic loading of Archive content based on custom taxonomy term name

Context I've created my own custom taxonomy called kernal-category using the CPT UI plugin. This taxonomy is hierarchical and will have a large number of secondary, and tertiary categories. ...
0
votes
1answer
29 views

Link to index.php from home.php?

I have home.php that displays recent posts from two prominent categories. At the bottom of home.php, I have a link that says "All Posts" which I would like to have point to a listing of all posts. ...
0
votes
0answers
22 views

Set up Custom Taxonomy Archive Template File To Cover 3 Categories

I have a custom post type that has 3 customer taxonomies (categories). I'd like to set up a custom taxonomy archive template file which will be the same design for all 3 custom categories. In the ...
0
votes
1answer
43 views

Issue with custom loop in Archive page

I customized my loop in archive.php to display 8 posts per page. However I have an issue passing the args: the loop displays all my posts from all my categories. Here is my PHP code for the loop: &...
0
votes
0answers
17 views

What is the best approach to having WordPress with two blog archives?

I'm trying to figure out how to have two blog archives on one instance of WP. I have a single WP instance with a blog. I have a custom page template for the archive index of posts. I exclude a ...

1
2 3 4 5
19