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

learn more… | top users | synonyms (1)

1
vote
1answer
31 views

Post Rank on Single Post page based on custom field

As per my previous question. How to show posts rank based on custom field value It works perfect on homepage as I wanted. Now I want to show the same rank in single post pages also.
0
votes
0answers
20 views

Display existing admin list table for custom post type in another location without recreating it

I have two custom post types; Inventory and Jobs. I have customised the columns displayed in the Inventory admin list table (ie. wp-admin/edit.php?post_type=inventory) to display relevant fields Is ...
0
votes
0answers
17 views

Post_title is only updated every other time

I have this piece of code which seems to work every other time, it is very weird. I have made a custom post type, and used the ACF plugin to create a field that now with this piece of code functions ...
0
votes
0answers
20 views

Hide All Published Posts from edit.php Paged

I am using AIT directory wordpress theme and customizing it. What i did till now is, created a custom post type similar to that came with theme, Now, all things are working correctly except one ...
0
votes
0answers
11 views

User roles: edit_post set but custom post type & posts not editable

I have a custom post type with the capability_type of "post". I then have a new user role with the following set: 'read' => true, 'edit_posts' => true, ...
1
vote
0answers
32 views

A custom post type in another post type

I can't seem to find an answer to the following question. English is not my native language so its sometimes hard to find the right words. I know how to build custom post types but i want to go a ...
0
votes
0answers
17 views

Plugin not initialising correctly

I have written a plugin that defines a custom post type, and a custom taxonomy. class Post_Type_Faq { const POST_TYPE = "faq"; private $_meta = array( 'open', ); /** * ...
0
votes
1answer
38 views

Add custom CSS class to custom post type

I created custom post type called 'song' in the installation. I am running on a theme called fabulous When I viewed the author archive page with custom posts, the post are not correctly displayed ...
0
votes
1answer
17 views

Control what custom posts a user can see

I've been looking into user roles and it would seem that there are 100 plugins to help me control what a user can edit or publish but they don't get any more specific. We have a custom post type ...
2
votes
1answer
74 views

How can I get next/ previous post links to order by a filter (by the last word of the title)?

I am trying to use the next/ previous post link functions by Wordpress to move between posts of a custom type based on the surname of a person. The custom type represents a person with a post title ...
0
votes
4answers
74 views

How can I use archive-{post_type}.php theme template?

I've got a staff_member custom post type, with 'has_archive' => true. I've got an archive-staff_member.php template, with /* Template Name: Staff */ In backoffice, to add it to the nav menu, I ...
2
votes
1answer
51 views

How do I set the default admin sort order for a custom post type to a custom column?

SOLUTION AVAILABLE HERE I've set up a custom post type called clientarea, and set up several custom columns for it in the admin area - the custom columns are all custom meta fields, as you can see ...
0
votes
1answer
16 views

How to enable the user to add value through the admin panel?

please help me! I have custom posts type 'gallery'. In my custom post type i have custom fields. I added them through the file functions.php. How to enable the user to add value through the admin ...
0
votes
0answers
21 views

include custom fields in search sql query

here is my sql query: add_filter( 'posts_where', 'title_filter', 100000, 2 ); function title_filter($where, &$wp_query){ global $wpdb; if(isset($_GET['s'])){ ...
0
votes
1answer
24 views

Filter Content on all Post Types

I had this idea to introduce a 'post type footer' using Advanced Custom Fields so that my users could set up common, reusable messages or calls to action and have them appear after the content of a ...
-2
votes
2answers
93 views

How to get Custom post type by related category ID

I have created a custom post types in function.php file. I has created 4 categories on Service menu section, aa, bb, cc and dd, I try to get a latest 5 post for specific category but I can archive ...
0
votes
0answers
119 views

Get month and day from a Date Picker custom field

I've got a custom field called fecha_del_evento from which I want to obtain the day and the month in different formats; day in numbers, and month with the 3 first letters. The code I'm using is a ...
1
vote
1answer
73 views

Archive slider for CPT

I have a custom post type and archive page. I want to be able to use the default twentyfourteen theme slider so that the archive-cpt.php page calls the js and displays a slider only for the CPT. I ...
-1
votes
2answers
104 views

WooCommerce - Show orders for a specific product ? [closed]

How to view orders for a specific product in WooCommerce using sku or product name? What I have so far is that, but it does not work.. Does anyone know how to do? <?php $args = array( ...
0
votes
0answers
13 views

How can I create a simple directory with ratings?

I have tried several commercial plugins that are far more complex than I need. I am building a site where customers can rate their bank(s). All I need is a post for each bank and an index page to ...
-1
votes
2answers
37 views

Post count for particular term

I am making by wonderful page and I want to query a given custom post type called accommodations and display the number of posts in that given location and this what I have e.g (1,110) Accommodation ...
0
votes
1answer
21 views

Inserting two categories

I am trying to define two categories together in a post. please tell me where i am doing wrong. 'post_author' => $user_id, 'post_status' => 'pending', ...
0
votes
0answers
23 views

Redirect custom post type child term to first post

is it possible to do the following in a functions.php file? I have the following URL structure: hxxp://domain.com/custom-post-type-slug/parent-term-slug/child-term-slug/page-slug/ Directly under ...
1
vote
0answers
29 views

Use “archive” as slug for custom post type

I need to have a custom post type slug and its associated taxonomy's slug to have value "archive". Any other value is ok, I've tested it, so there is no problem with the code per se. I guess the path ...
0
votes
3answers
46 views

Is it possible to add and display custom post types to an array?

My company is working on a project that will have to display Events based on a the Office they are located in and the Event Leader associated with that Office. What we need is to build a system that ...
0
votes
0answers
76 views

echo value from 'select' field type into page template using cmb2?

I'm using CMB2 plugin to add metaboxes into a custom post type. I'm adding the additional metaboxes via functions.php onto child theme. It may worth to mention that parent theme/custom post already ...
0
votes
0answers
16 views

How to control the the URL of a Custom Post Type to have multiple slugs?

I currently have a custom post type whose rewrite rule is this: 'rewrite' => array( 'slug' => 'tests', 'with_front'=> false ), So the URL is www.domain.com/tests/post-name ...
0
votes
0answers
22 views

Redirect to single post with unique custom taxonomy term

I need some help with taxonomies and custom post type to make a redirection to an specific single post. Lets suppose I have a custom taxonomy called "place_id" wich assigns each custom post type ...
0
votes
0answers
16 views

Cusom posts - tree

I am beginner in Wordpress so I am sorry if my question is too obvious. I want to create a custom post type, that can be linked with another post (with the same type). The relation should be one to ...
0
votes
1answer
35 views

Rewriting archive page slug to be different than custom post type slug

I am having trouble changing the slug of my archive page. The goal is to create a page that can be edited from the back end of WP with the slug 'speakers', but that has already been taken by the ...
1
vote
3answers
88 views

Separating Search Results By Post Type

Original question: Seperating Custom Post Search Results I've tried to implement this code to my website, but i have some problem with it. What i've changed is i've added another switch for third ...
0
votes
1answer
28 views

How can i add a custom meta box below publish box in CPT that will be like publish meta box and contain some html code?

How can i add a custom meta box below publish box in CPT that will be like publish meta box and contain some html code? See the attached shot for more info.
0
votes
0answers
23 views

Using clone of wp_post for custom post type

I'm using custom post type for example NEWS. and I want to add, update and get data from new table wp_news wich is absolutly clone of the wp_post table. Can I do it?
0
votes
0answers
17 views

Auto overwrite: Plugin edits not sticking

I am trying to edit a plugin called "Calls to Action" to add personal functionality and remove all the extra stuff I don't need; and WordPress or the plugin keeps overwriting my edits. I have even ...
2
votes
1answer
37 views

How do I create an archive page for standard posts?

I've been tasked with creating a portfolio website for a client who also wants a blog. What I've Done Thus Far: I’ve created a custom post type to separate the portfolio work from the blog posts and ...
1
vote
1answer
27 views

Add pre-existing meta box to new custom post type

I have a parent theme that creates a number of custom meta boxes that are added to the "post" and "pages" post types as well as a number of post types also created by the theme. In my child theme, I ...
1
vote
2answers
65 views

Display latest x posts from all categories in Custom Post Type/Taxonomy

I am attempting to display the latest x posts from all categories using a custom taxonomy called 'case-studies' in WordPress. I have managed to output all the category names as heading links I have ...
0
votes
1answer
34 views

Loop posts in a table ordered by a custom field value

I'm trying to generate a table for a custom post type events, in which I have a few custom fields, one of these is the date. I want to display the posts in the table and order them by the Date value. ...
0
votes
1answer
48 views

Can't replace the default sidebar with a custom sidebar on Custom Post Type in Genesis

I have an archive template ("archive-reviews.php") for a Custom Post Type I have created. I'd like to replace the default archive sidebar with a different one that I have created using the Genesis ...
-1
votes
1answer
37 views

Get all post from custom post type in custom taxonomy

I am trying to display a custom post type that has custom taxonomy, but I am not having any luck. Nothing is showing up. I appreciate any help. Post type = banner Custom Taxonomy = country The ...
0
votes
1answer
45 views

Two plugins sharing the same custom post type registration

I have two plugins Plugin A and Plugin B registering the same post type exp, aws_employee. Each plugin offers different functionality but the post type type they share is exactly the same. If I ...
0
votes
0answers
37 views

How to edit attachment images title from front-end in a custom post?

i am using a custom post in my wordpress/buddypress blog which can be created and submitted from front end. I also upload images as attachments from front-end using that custom post. When I am making ...
0
votes
1answer
28 views

Add data to post edit page, when post is published

I need to customize the "post edit page", for a custom post_type, but to keep things simple let's say it's on the post_type post for now. When the post status is published, I need to run a PHP script ...
0
votes
0answers
23 views

does it need any special functions to write in function.php?

does it need any special functions to write in function.php of template for single-{post_type}.php? I created a custom theme , but it does not move the single-{post_type.php}, my page is ...
0
votes
2answers
23 views

Expandable WordPress content (text) inside a post

I've created a CPT in my WordPress site. In this CPT I have the content element (which is the default WP content) and want to make it expandable, I mean, while viewing the CPT I want it to only ...
1
vote
1answer
44 views

How to connect two custom post types with nested loops

I have 2 custom post types created: "classes" and "teachers". I have created using Advanced Custom Fields plugin a field for "classes" custom post type, a multiselect that helps me add certain ...
0
votes
1answer
48 views

Multiple custom post types showing up in edit.php

I'm having a bit of trouble (i think) over custom post types in Wordpress. I have created multiple post types and they all work, but there is this one thing which is bothering me. Lets say I have ...
0
votes
1answer
31 views

Custom post type URL - filter by taxonomy

Created CPT = news uses default categories (IT and recruitment) I am struggling to view an archive of the posts based on their category mysite/news/ - shows all posts for that CPT whatever the ...
1
vote
0answers
17 views

CPT Validation to not show “Post updated.”

Now this has been asked several times over on all WP forums, but how you change the success message? First, I know there are 2 choices for managing the error message: setting in the options and using ...
0
votes
0answers
20 views

CPT Rewrite Rules by date

I'm having issues with date categorized posts for my CPT. I have permalinks not on the default. I created a CPT with register_post_type and setup rewrite rule as follows. 'rewrite' => array( ...