Search type Search syntax
Tags [tag]
Exact "words here"
Author user:1234
user:me (yours)
Score score:3 (3+)
score:0 (none)
Answers answers:3 (3+)
answers:0 (none)
isaccepted:yes
hasaccepted:no
inquestion:1234
Views views:250
Sections title:apples
body:"apples oranges"
URL url:"*.example.com"
Favorites infavorites:mine
infavorites:1234
Status closed:yes
duplicate:no
migrated:no
wiki:no
Types is:question
is:answer
Exclude -[tag]
-apples
For more details on advanced search visit our help page
Results tagged with Search options user 3966

Custom Post Types extend the WordPress back-end to support additional, non-Post content.

2
votes
The WordPress Template Hierarchy for custom post type archive index pages provides the solution. Simply create a template file, named archive-{post-type}.php - which in your case would be archive-blo …
answered Nov 13 '13 by Chip Bennett
4
votes
There's a core function for that: get_post_types(): <?php get_post_types( $args, $output, $operator ); ?> So, for example, to return public, custom post types by name: $custom_post_types = get_pos …
answered Nov 16 '12 by Chip Bennett
0
votes
I assume you're talking about a custom post meta box? If so, then you need to ensure that you *specify the $posttype when you call add_meta_box(). e.g.: <?php add_meta_box( $id, $title, …
answered Feb 23 '12 by Chip Bennett
1
vote
Custom Posts don't use custom static page template files. Custom Posts have their own template files for custom post archive index pages and single custom post pages. For a single custom post page, y …
answered May 25 '12 by Chip Bennett
3
votes
If the template page in question is the archive index for the custom post type, you can simply create a custom template file, archive-{post-type}.php, and add in the Title and custom text. If you don …
answered May 10 '11 by Chip Bennett
7
votes
You need to create a Custom Post Type, "Portfolio". Posts are Posts. Why try to use them as something they're not, and then try to change their nomenclature, instead of writing one or two simple func …
answered Apr 28 '11 by Chip Bennett
3
votes
Create custom page template The first step is to create a custom page template to hold the code. For example, name the file template-cpt-list.php: <?php /** * Template Name: Custom Post Types List …
answered Nov 21 '12 by Chip Bennett
3
votes
Looking at the Codex entry for get_post_meta(), the function returns the specified value (if it exists), or else it returns an empty string. So, you just need to check for an empty string: if ( '' ! …
answered Aug 14 '13 by Chip Bennett
2
votes
You need to declare 'has_archive' => true in the arguments array you pass to register_post_type(). The default value is false, which means that WordPress does not generate an archive index for the pos …
answered Nov 12 '13 by Chip Bennett
0
votes
One possible solution: Custom Post Type draw-results, where each post is a contest/game result Custom Taxonomy contest (or game), where each term is a different contest/game When you create a draw-r …
answered Nov 1 '11 by Chip Bennett
0
votes
The problem is that you're not letting the template file do what it is intended to do. Instead of outputting the default loop, you're ignoring the default loop, and outputting a custom query loop. Re …
answered Oct 11 '13 by Chip Bennett
1
vote
There are a couple of solutions: Create archive-vendors.php, that displays whatever output you want (including static content or a secondary query, for example), and omitting the default loop (CPT a …
answered Nov 19 '13 by Chip Bennett
2
votes
There are a few methods to return all child posts via get_pages(). One fairly straightforward method would be to get all of the IDs of the top-level parent posts, and then pass those IDs to the exclu …
answered Mar 8 '12 by Chip Bennett
1
vote
Try changing this: add_theme_support( 'post-thumbnails', array( 'post' ) ); to this: add_theme_support( 'post-thumbnails' ); IIRC, that array is explicit, meaning that by including only post, ev …
answered Jul 8 '11 by Chip Bennett
4
votes
Did you add post-type support for those features, via add_post_type_support()? Use this format: <?php add_post_type_support( $post_type, $supports ) ?> The $supports argument is an array, that can …
answered Oct 22 '11 by Chip Bennett

15 30 50 per page