2
votes
2answers
77 views

Automatically adding meta data to posts or multiple query help

I run an events company whose website uses a custom post type system for posts (blog), events and tickets all stored as CPT's in the DB. On the guestlist (which counts 'ticket' custom posts if the ...
0
votes
1answer
52 views

Timetable of Custom Meta Data using Custom Post Type and Custom Taxonomy

Scenario: I have a custom post type with custom meta boxes. Each post should represent a row in my table i.e Activity 1 Jan, Activity 1 Feb and Activity 1 Mar I have a custom taxonomy of terms ...
0
votes
0answers
18 views

Cannot save post meta data as Administrator in Wordpress

I have an wordpress installation at yogazoga.com with several custom post types. When i try to add meta data to posts through admin panel it simply does not work. See the post at: ...
0
votes
0answers
49 views

Filter plugin posts by meta value

I am a WordPress beginner, but have a few years of software development experience. I have a WordPress plugin used to display custom data via a custom post type. The index page contains something ...
0
votes
2answers
55 views

Correctly delete posts with meta and attachments [duplicate]

I am having an overview of custom post types: http://www.citizen-science.at/wordpress/projekte/roadkill/ubersicht/ These have custom tax and also an attachment. In my overview I need to provide ...
0
votes
1answer
40 views

Show future events based on custom field AND order by date

I have a custom content type (event), within that type I have a custom date field, with the name: 'date'. In my template I am running the WP_Query to return a list of events. I would like to only get ...
0
votes
1answer
57 views

Compare 3 custom fields and sort by oldest

I am building a movie archive. For each movie I am filling out the release dates for 3 countries, they're stored as custom fields (added via Pods) Now, when listing the movies I would like to build ...
0
votes
1answer
40 views

Meta box with front-end styling

I have a specific Gallery post of products that I release at the start of every Monday on my website, which differs from my other Gallery posts. These types of Gallery post don't require the Authors ...
0
votes
0answers
56 views

Show/Hide Custom Meta Boxes using any plugin

How can I show and hide the custom meta fields created using Advanced Custom Fields plugin? I want to handle the publish and unpublish of the fields and values from the admin panel. Is there any ...
0
votes
3answers
50 views

How to Echo Metadata Value in Currency Format

I have a Custom Post Type with a Metabox and an input Text field for adding "Price" to the posts. Now I would like to display the input value which can be like 49 or 59 like 49.00 or 59.00 so far I ...
0
votes
2answers
47 views

Sanitaizing Select Optin For Custom Post Type Metabox in WP

Using WordPress 3.8.1, I have a Custom post Type called "Map" and it contains a Metadata which is a Select options element as: <label for="my_meta_box_select">Countries</label> <select ...
0
votes
2answers
96 views

Issue on Working with Metabox - Checkbox to enable Sale Items

Using WP 3.8.1, I have a Custom Post Type which is called "Sport" and it has a Metdabox - medata data as I do not need to set up online shopping but I world like to add Price of my products to any ...
0
votes
0answers
55 views

Wordpress Admin Panel Search posts with custom post meta values along with title

Trying to modify default admin search by including search by custom post type fields, Below is my code, function custom_search_query( $query ) { $custom_fields = array( // put all the meta ...
0
votes
2answers
77 views

Filter posts by tax (dropdown) and meta value

I'm having a page on which all my custom post types are displayed. I now need to add another to the existing ones: $args = array( 'post_type' => 'bkroadkill', 'post_status' => ...
0
votes
1answer
39 views

How to rewrite CPT-Permalinks the correct way (incorporating meta-box-data)?

Using the below hooks, I tried to rewrite the permalinks of my custom post type magazine_issue to be made of values of additional meta-fields I added to the edit screen. The problem with my actual ...
0
votes
1answer
36 views

Rich Custom Field for Custom Post type not saving

I am new to creating meta boxes and I am trying to create a custom field meta box that is connected to a custom post type which is created by WooTheme Sensei (Post type = lesson). I am trying to use ...
0
votes
1answer
384 views

update_post_meta() whenever custom post type is updated

I need the following functionality. Whenever my custom post type is updated or saved I need to overwrite certain custom post metas. I need to make sure this only affects posts of the post type ...
0
votes
0answers
125 views

Add auto increment value to custom meta

I have a custom meta "code" in my CPT. How can I make it so that it has a number that will auto increment every time the admin publishes a post? My solution is to add a table in the database that is ...
0
votes
1answer
57 views

Custom post type submenu sorted by specific meta_key & meta_value

I have a created a custom post type called "Events" using register_post_type. I am now trying to create a submenu within "Events" that will only show events sorted by a specific meta_key and ...
0
votes
1answer
48 views

delete_post_meta() for whole CPT / multiple posts?

I'm cleaning up a theme and one of Custom Post Types has some odd, long gone custom fields. I want to delete them, unfortunately delete_post_meta() takes post->ID for an argument, while I want to ...
1
vote
2answers
198 views

How to keep a check box in custom meta box for custom post type checked by default for add new post?

In my custom plugin, I have a custom post type and have a custom meta box for it. I have few fields in it, one of it is a check box. I want this check box to be checked by default when I go for a add ...
1
vote
2answers
95 views

Custom Post Types. Are there any disadvantages/advantages in using a plugin to develop them?

There are a few plugins which can assist you in building your CPT's, and these can usually handle your taxonomies and sometimes postmeta also. Some even take it further than that. I know that as with ...
0
votes
1answer
718 views

How to add multiple featured image in meta box in post editor?

I would like to add multiple featured image in meta box in post editor area apart from default available featured image. I have added the meta box but i have no idea on adding the featured image ...
0
votes
1answer
80 views

How to retrive Custom Post Type Meta Fields in Custom WP_Query

Can some one let me know How I can render the Custom Post Type Meta Fields (Meta-boxes). I have a Custom Post Type Called "News" and I successfully added a Metabox to my Custom Post Type called "News ...
1
vote
1answer
454 views

Get all posts from custom post type and insert in select input as metabox

I would like to know if its possible to do something like this. I have Slider custom post type and Services custom post type. For slider posts I have created a metabox for URL value to display next ...
0
votes
1answer
85 views

How to get specific post meta by title or id

I have register bellow custom post type in function.php and I am using Advanced Custom Fields. Using advance custom field type I have added one image field and assigned to my Release custom post type. ...
0
votes
0answers
116 views

Filter post_meta for custom post types in Genesis 2.0

Working with Genesis 2.0: I have various Custom Post types declared, and I want to display as post meta information: - in normal post: "filed under: category1, category2..." - in the custom post ...
0
votes
1answer
141 views

Cannot Save MetaBox Data in Custom Post Type

I've been working on this issue for quite a while and am truly stumped. Below is all of the code for my custom post type: /* Services Post Type */ function services_post_type() { $labels = array( ...
0
votes
1answer
121 views

Can't sort order of wp_query with 2 meta keys

I'm trying to display custom post types by excluding the sold ones but also by displaying them in alphabetical order from the county meta_key. I'm trying to use pre_get_posts but I'm not sure that ...
0
votes
1answer
121 views

delete duplicate meta_value with same post_id

I've trying to cut down on the time to query a custom post type. After looking at the database and the wp_postmeta table, for some reason, there is some duplicate meta values for the same post_id and ...
0
votes
3answers
168 views

Using preg_replace to filter custom textarea

I am developing a custom post type, which, among others includes the possibility of sending an email from within the post editor. The email body textarea is populated through a custom settings page ...
0
votes
0answers
37 views

Displaying additional meta from a custom post type on the page?

I have added the custom field which displays in the custom post type "portfolio" just fine. // Add more custom field function woo_metaboxes_add($woo_metaboxes) { // Check for post type = ...
0
votes
2answers
89 views

HM CMB: Post Select Field for CPT ID

'm using human made's custom meta boxes framework (https://github.com/humanmade/Custom-Meta-Boxes). Using the post select: array( 'id' => 'example-field-post-select', 'name' ...
0
votes
0answers
139 views

get posts with hierarchy and all post meta

I created a custom post type to act as a Family Tree. There are currently 40+ post-meta fields that collect all of the important information. Wordpress's built in "parent" function is used to assign ...
0
votes
0answers
113 views

Repeating Posts Plugin Tweak

I am attempting to Repeat Posts (ie. publishing them multiple times) and found the plugin repeating-posts. However, I need to tweak it so that when I have it scheduled to repeat, it also repeats the ...
0
votes
0answers
102 views

One-time bulk MySQL copy post_date values to Advanced Custom Field (date field)

Disclaimer First of all let me say this is probably mostly MySQL related and unfortunately I'm nearly a total newbie on database language and commands. The problem Situation is a site running ...
0
votes
3answers
218 views

Get only used meta_values

this is how I'm getting the meta values: $apart_locations = $wpdb->get_col( "SELECT meta_value FROM $wpdb->postmeta WHERE meta_key = 'postal_location' ORDER BY meta_value ASC" ); This is how ...
0
votes
1answer
71 views

Search CPT Title AND Meta

I currently have a CPT I would like to search, the catch is I also need to be able to search the meta data for the CPT. I have the following code that currently searches the meta value needed but I ...
0
votes
1answer
81 views

Change the contents of a dropdown through the admin panel?

I have a custom post type "Events". In Events, I have a custom field for "Place" which is a dropdown list. Is there a way to edit the contents of the dropdown list through the admin panel or is ...
0
votes
1answer
36 views

Getting WordPress to store 0 values for custom post type meta

I've created a very complex custom post type system for a football website and am using custom meta boxes to store various match stats. To decide whether or not I should display a stat I check ...
0
votes
3answers
316 views

Can't publish custom post type - “You are not allowed to edit this post.”

Hey guys I've created this post type but when I click the publish button I receive the message: You are not allowed to edit this post. Have I done something wrong in my code to disallow anyone ...
1
vote
1answer
77 views

Get posts between custom dates

I created an event CPT and a meta box with a date. I saved the date as post_meta in the form dd.mm.yyyy. Now I want to create a shortcode that queries all posts which's dates meet the condition ...
2
votes
2answers
506 views

Meta query with boolean true/false value

I'm trying to show all rental properties, first by all properties that have not been rented, and then by all properties that are currently rented. There is a custom post type 'rent' with custom post ...
0
votes
1answer
38 views

Publish and save specific postmeta to a filtered post_type

I have multiple plugins with different post_type(s). When I save or publish, all of the custom_post_meta that belong to one specific post_type are also saving. I'd like to filter by post_type so ...
0
votes
0answers
242 views

Sort Custom Post Type List Table in Admin by Multiple Meta Values

I have a Custom Post Type (CPT) called Sessions. The List Table in the admin for this Custom Post Type (CPT) has the following columns: Session # (post id) Session (post title) Day (CPT meta value) ...
1
vote
1answer
162 views

How to best delete orphan wp_postmeta

I'm in the middle of doing some fairly complex queries involving metadata from a custom post type. Unfortunately if any posts are deleted the metadata stays put which complicates matters as I am ...
0
votes
0answers
62 views

Ranking authors by post meta value

I have custom post-type with custom post-meta and i want to rank authors by post meta value.I can show the SUM of a meta value on author page with this code <? php $points = ...
0
votes
2answers
191 views

Save post_parent in a custom post type

I'm using the save_post action to save some meta data in a custom post type: function my_save_post($post_id) { // is autosave? if(defined('DOING_AUTOSAVE') && DOING_AUTOSAVE) { ...
0
votes
2answers
190 views

Metadata for a taxonomy - is there any WordPress way of doing this?

If I have a CPT "movies" I know I can have various taxonomies eg "Director", but how can I store further information such as "director's nationality" for any one particular director ... or is this ...
2
votes
1answer
347 views

Admin Area Custom Type Search By Meta Fields Without Title & Content

I have a custom post type that uses several meta fields. In the admin area I would like to be able to search by those meta fields. I have implemented this currently in my functions.php with this code: ...