0
votes
1answer
16 views

Return the name of the post type

I have this in the archive.php file of my theme: <?php else : ?> <h1 class="archive-title"><?php printf( __( get_post_type() ) ); ?></h1> <?php endif; ?> And it ...
0
votes
0answers
53 views

Custom post type category page not working

I have a custom post type called 'emp_case-studies'. Archive and Hierarchical are set to true. My archive-emp_case-studies.php and single-emp_case-studies.php are performing as expected. However, ...
0
votes
1answer
47 views

Archive page for custom post type and custom taxonomy

I've made a custom post type book and a custom taxonomy book_category. I've been trying to create an archive page where the books belonging to a particular category can be viewed. So far I've only ...
0
votes
1answer
251 views

Custom post type archive page pagination

I have set up an archive page for my custom post type reference, where I use a query to get all posts of type reference. This works, but when I try to paginate the result, it doesn't work. Right now, ...
0
votes
1answer
154 views

paging is not working properly on news archives page [duplicate]

I need paging on news archives page. Data is coming correctly if display all records on same page. But if i add paging code, then pagination values (such as 1,2,3,...16) coming correctly, but if i ...
0
votes
1answer
130 views

URL of a custom post type's post format archive?

With pretty permalinks enabled, the URL of a Custom Post Format archive would look like this: http://example.com/type/link/ And it works for me. Now, considering that my custom post type archive ...
0
votes
1answer
332 views

Get posts from a top category and group by child categories

I have a CPT Called "Membres" (members in English). So after that I created a category called "Membres" and his child categories. Parent category "Membres" - Subcategory1 (3 post inside) - ...
1
vote
2answers
165 views

Tell wordpress to show a single page instead of an archive

So I have multiple custom parameters in the url, and at some point when the query reaches 3 parameters (e.g. ...
0
votes
0answers
55 views

How can I set up the URL for a category archive for a custom post type?

I'm working on a site www.site.com that has an additional post type: project. In registering project, I've declared "taxonomies"=>array("category") so that I can categorize the essays. Works fine. ...
0
votes
1answer
49 views

Custom archive pages without “the loop”

Is there a way that I could control the rendering of an archive page that uses my own loop? I'd like to group the posts by a custom taxonomy, then sort them by date.
0
votes
1answer
113 views

2 loops in archive.php (one for each category)

I have a custom post type set up for a news blog on a site I'm building, the custom post type being blog consisting of 2 categories, blog-image-post ID=3 and blog-text-post ID=4. I want to loop each ...
0
votes
1answer
584 views

How to have Multiple Archives Widgets, one archive widget per category (in a different page)?

Please read the whole question before assuming this question is repeated. After one day of trying plugins and tutorials, I am convinced that there is no straightforward method of achieving what I am ...
0
votes
0answers
22 views

Make only one CPT available by slug

I did a lot of research until I figured out how to remove the slug from a custom post type. I used the method described in this post here. So I have RewriteRule ^bereiche/(.+)$ /$1 [R=301] in my ...
0
votes
1answer
48 views

How to get type of archive whether it is post or date or category archive?

using function is_archive() we can know whether it is archive page or not. But if it is archive page how can i find whether it is author archive page or category archive or date archive. I have ...
2
votes
2answers
3k views

Get custom post type slug for an archive page

How do I discover the custom post type slug when I'm on an archive page? For instance if /products/ fires the archive-products.php template, how (pragmatically) do I get the post type slug? Thanks
0
votes
2answers
474 views

paginate function in archive for custom-post-type

I have a custom-post-type for events and use the normal archive.php template to list all previous events. The thing is that I use a custom query for my event-post-type inside archive.php like this … ...
1
vote
1answer
146 views

Custom-post-type-archive: posts sorted/filtered by year?

I have a custom-post-type wr_event whose posts are sorted by meta_key "event_date". Therefore I have this handy function … function get_event_list( $latest = true, $order = 'ASC' ) { echo ...
0
votes
1answer
281 views

How to create template for taxonomy results limited by Custom Post Type?

I've got a Custom Post Type with a Custom Taxonomy set up. So how do I create an archive template to display posts from that CPT, limited by taxonomy? Here's the deal: The CPT is called Shows. Each ...
0
votes
1answer
474 views

How to have multiple archive pages?

I am building a site that needs pages such as News, Events, Projects and People. My question is, how should I achieve this in WordPress? Do I use custom post types? And if so, how do I have a page for ...
0
votes
1answer
209 views

Create a Custom Path to Archive

To get at archive pages (by default) the path is /%category%/ Which is fine. But how would i change it to have a static string prefix before the category variable (e.g. /archive/%category%). Same ...
1
vote
0answers
44 views

List Custom Post Types by Date Archive [duplicate]

Possible Duplicate: Rewrite rule for Custom post type Monthly and Yearly archive I'm not sure if I'm missing something or what! But I've been trying to get this right for past couple of ...
0
votes
1answer
425 views

Custom Post Type Date Based Archive URL rewrite [duplicate]

Possible Duplicate: custom post types, wp_get_archives and add_rewrite_rule I have a custom post type called "course" and I would like to create a date based archive similar to the default ...
0
votes
1answer
261 views

Custom Post Type Query issue

I have a conflict issue with 2 custom post types. I have a template file archive-media.php and have created the related 'media' custom post type. This all works well, however in the sidebar I have a ...
0
votes
2answers
2k views

next_posts_link and previous_posts_link problem

Below is the code from my author.php file. The problem is that next_posts_link and previous_posts_link only generate links based on the number of posts in the blog authored by the author in question, ...
1
vote
2answers
217 views

Second Custom Post Type Archive

I've got an event custom post type, and using filters, I've configured the archive page to show only event in the future, and in chronological order based on a meta value (start date). I want to make ...
1
vote
1answer
263 views

Custom archives function

I'm working on building a custom archives page for my church's website. On my archives page I want to have last week's sermon shown at the top in a special box, followed by the future sermons and then ...
0
votes
1answer
792 views

Page is defaulting to archive page and not designated template

I created a page called "Projects" through the wordpress admin I created a template called "Projects" Set the "Projects" page to use the Projects template. How come when I navigate to the Projects ...
4
votes
1answer
1k views

Custom Post Type Archives by Date with Custom Permalink

I'm a bit stuck with getting the custom permalink for custom post type (CPT) archive to work. I've registered my 'press_release' CPT as following: add_action('init', 'press_release_post_type_init'); ...
0
votes
1answer
419 views

WordPress sitemap with Custom Post Types

This is a really neat idea but I'd like to expand upon it. In his post, David Kennedy writes out some code to allow a basic wp_list_pages type feature for Custom Post Types to use as a sitemap. His ...
0
votes
3answers
2k views

How to disable pagination (next/previous links) on post type archive?

How can I remove the next and previous links in a custom post type archive page, but only for that post type? I know I could wrap any function in if ( get_post_type($post) == 'myposttype' ) {} but I ...
1
vote
0answers
397 views

Date archive shooting 404 when months and days are quarried [closed]

I know you guys have seen hundreds if not thousands of 404 questions. I assure you I have done everything in my power. 1. updates permalinks 2. using /%post_id%/%postname%/ for structure 3. have ...
2
votes
2answers
621 views

How to list custom post types?

Here's what I'd like to do: a) Create a custom post type and write panel for a menu item called "My Stuff." b) "My Stuff" will behave like a category -- but the content will not appear in the main ...
3
votes
3answers
671 views

Custom Post Type Archives with 0 Posts Redirects as 404

I'm working with the new custom post type archives in 3.1 and I noticed that when my post type has 0 posts, the archive for the type results in a 404. Looking at the order of hooks being processed, ...