Post meta is a data set containing additional core as well as custom post information.

learn more… | top users | synonyms

0
votes
1answer
9 views

Custom Search Query – include only custom fields and title

I have a custom post type and I also need a custom search. I want the post title and two custom fields to be indexed/queried. I found solutions for title only and for custom fields but not for both so ...
1
vote
1answer
255 views

Filter list by a unique meta value dilemma

I'm been racking my head at this for a while now, and I can't figure out how to fix the code. Here's the issue; I found a snippet of code online to filter my post results in edit.php based on ...
0
votes
1answer
96 views
+50

using update_user_meta to rank users

I'm using a plugin that allows users to vote on posts, I'd like to add each vote that's cast to the authors user_meta so I can rank users the same way I rank posts. There's a couple of different ...
2
votes
1answer
426 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: ...
0
votes
0answers
9 views

Post meta not appear in admin edit menu for custom post type

I have a custom post type 'Vehicles' within I have a taxonomy 'cars'. Also a front end adding from a html form. After the form is send, here is a sample what actually is happening. My idea is to hook ...
-1
votes
0answers
6 views

Woocommerce - Replace _product_url on page load [on hold]

Current status : i run a woocommerce driven product catalog . All products in the catalog have an external link, they all are affiliate products. Because I can only generate 1000 affiliate links via ...
0
votes
0answers
34 views

SQL query for converting post meta image url to featured image

WordPress guru, we have a question: We work on a website, which was not updated a while. Most of time it have wordpress 3.2 installed. We've updated it to the latest wordpress version, but ...
-1
votes
0answers
25 views

Woocommerce - Add custom field to products and display in Orders [on hold]

I need to add a custom field to my products that will contain an internal SKU used by my distributors. There's a great article here describing how to create and save the data when you add/edit a ...
1
vote
1answer
647 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
0answers
23 views

Multiple meta data one label

I am wanting one label but multiple data to be under the label. I also want to reference each input option individually so that I can query for specific meta data. Currently I have, function ...
0
votes
0answers
21 views

Individual page data in one page template

So I am trying to create a one page template but still allow the user to add separate pages in the admin panel. What I did to output all the pages in one template file is as followed: <?php ...
0
votes
1answer
273 views

Create action running on trashed_post hook to modify post_meta value

I have a custom post type that always do math operation to its post_meta and other custom post type post_meta. For example: post-type 1 = cpt_product_order post-type 1 post_meta = ...
0
votes
0answers
23 views

Prevent Duplicate Instagram Posts using Instagram API

Below is the code I am using to fetch every hour (using WP CRON) Instagram posts using the Instagram API, but more often than not I am getting duplicate, triple, and even quadruple identical posts and ...
0
votes
1answer
22 views

retrieve wordpress post-meta using php not wordpress functions

I am trying retrieve wordpress postmeta USING PHP not WORDPRESS functions, it needs to be in php no wordpress functions please. this is what I have: $resultat = mysqli_query($con,"SELECT * FROM ...
1
vote
1answer
519 views

Create Multiple File Upload Metabox in Wordpress

I am trying to create a metabox to upload multiple files (can be images or files). Currently I have the upload field and its working file till the time we press upload and saving the data. The only ...
0
votes
1answer
564 views

Auto save title as custom meta field value

I create a custom post type where I removed the "Title", instead I want to use one of my custom meta value to become the title. This is just to make sure the title look good. Know that the post ...
0
votes
3answers
679 views

If Post Meta Equals Current Title Conditional Advanced Custom Fields

I would like to create a custom query loop to display data depending on the current post title. Pseudo-code: if post title = custom filed Show related content I have a page called artists ...
0
votes
1answer
255 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
1k views

Hide Post Meta Data on a specific category

I'm using the Canvas theme from Woothemes, and their framework (obviously.) I built a child theme and have my custom CSS segregated in a custom.css file in that directory. I've made some changes to ...
0
votes
0answers
14 views

Replace meta_key _product_url

I have this 2 functions that replace the links in posts with an affiliate generated link . But it works only for posts and the links in the posts . I am running woocommerce and the link I would like ...
1
vote
1answer
885 views

Displaying Meta Box Image

I have some problems displaying info from my custom meta box in my custom post type single. I'm using Reusable Custom Wordpress Meta Boxes by Tammy Hart. I'm able to display the textfields using ...
0
votes
2answers
283 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) { ...
3
votes
1answer
263 views

Change post format using custom field

I'm creating a theme using the CF Post Formats plugin. But I've run into some trouble I don't know how to solve. Here's what I want to be able to do: Create a new standard-format post Enter a url ...
0
votes
1answer
18 views

get_post_meta() empty in preview WHEN custom post is published

So my client managed to find some (bug?), when custom post is published and he previews post all information what is posted with custom meta boxes is inaccessible. When I started debugging I found ...
0
votes
1answer
20 views

Posts with no meta field do not appear when sorting by meta field

I want to order my posts by a custom meta field "fieldA". I am using the following code: $query->set( 'meta_key', 'fieldA); $query->set( 'orderby', 'meta_value_num' ); $query->set( 'order', ...
0
votes
1answer
33 views

How to create content automatically when a post is published?

Goal: Ability to automatically create content in WordPress posts/pages. Goal Details: When a post is created/published, it will automatically create or configure content based on the base data inputs ...
2
votes
1answer
56 views

How to make orderby 'meta_value_num' OPTIONAL?

$args = array( 'cat' => 5, 'posts_per_page' => 8, 'meta_key' => 'custom_sort_order', 'order' => 'ASC', 'orderby' => 'meta_value_num' ...
0
votes
1answer
352 views

Build Array from Input Fields question

I have a series of input fields sets: <input type="text" name="people[name]" /> <input type="text" name="people[lastname]" /> <input type="text" name="people[email]" /> <input ...
2
votes
2answers
279 views

Grouping related postmeta data via SQL query

I am using someone else's WP plugin which stores lots of related data in wp_postmeta using an "artificial key". So effectively we hijack wp_postmeta to create a nested relational database. So one row ...
0
votes
1answer
267 views

Counting number of identical meta keys

Im looking to count how many meta keys exist within a post, because each time a specific user action happens, a new meta key is created with a date in it. I have this, which does not return anything ...
0
votes
1answer
43 views

Insert data from custom created php page to wp_postmeta table

Hi i am working wordpress site here i have created one custom page in bellow directory /home/planmyme/public_html/php/ with the name response.php. on this page i am getting some value that value i ...
0
votes
1answer
28 views

Display a post count from a custom metabox selection

I was wondering if this is possible. I have a custom post type call projects that displays a metabox with drop down menu. In that drop down menu I have a few choices listed, draft, open, pending, ...
0
votes
2answers
564 views

Add a meta description to home page?

I have the theme Hatch and I can't figure out how to change the meta-description of the home-page. It is not an actual page, it is the default view for posts. Have searched everywhere for an answer ...
0
votes
1answer
83 views

Group WP_Query by meta_key date

I have a wp_query which lists posts from a custom post type, sorted by a custom field 'time'. I'd like to group this list by another custom field 'date', so that every post that has the same custom ...
1
vote
1answer
50 views

echo a specific meta_key queried through a custom post

I'm new to coding but love tinkering around (on Virtual Server) with bits to upgrade my current website when I have the time. What would be really useful to me would be to post an individual ...
1
vote
1answer
42 views

Calling Different Custom Post Timestamps in a table

I use WordPress to run an events site that people can sign down to if they have a subscription. At the bottom of each event, if you are admin you can see a guest list with Name, Email, Tel, Avatar ...
0
votes
0answers
27 views

How to save dynamically generated value in post type?

I'm trying to use the count of the amount of people that register a post id to a table in the DB. I want to save this COUNT value to the post_meta so when I display the list of posts it can also show ...
3
votes
2answers
688 views

Trying to get custom post meta through Jetpack JSON API

I'm using the Jetpack for Wordpress to produce a JSON API for my Events custom post type, which works fine: https://public-api.wordpress.com/rest/v1/sites/MYSITE/posts/?type=events&number=100 ...
2
votes
1answer
280 views

Save HTML formatted data to post meta using add_post_meta()

Array ( [post] => Array ( [jw_objective] => Exposure to e<b>nd to end development</b> of various applications; right from requirement analysis to system ...
0
votes
3answers
348 views

get Insert id for meta field

I'm in a situation where i also need to get the id of the inserted meta( meta_id for post meta and umeta_id for user meta) For eg i add a user meta ...
0
votes
3answers
96 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 ...
3
votes
1answer
2k views

Filtering posts by post meta data

I want to filter posts in such a way that only posts, for which get_post_meta($post->ID, "project_cat", true) (it returns a post ID) is equal to my specified value, are shown. Any way to do this? I ...
2
votes
2answers
4k views

Properly add an upload media button in a meta box field

i have a custom post which has a meta tag that needs to be using a file upload (for video files). I am wondering, what is the correct way of adding an Upload button that points to the wordpress media ...
0
votes
1answer
14 views

how do I set a schedule event to modify all posts's meta value weekly or monthly?

so far, I have added some functions to set post views count in post meta. But I want more: post_views_count_all: this is a post meta and save all post views; post_views_count_weekly: this is a post ...
0
votes
1answer
23 views

Can't Output get_post_meta?

I have a custom field for my post and I am trying to output it onto my post's page but nothing appears. I know my code works otherwise if instead of trying to call my custom field, I use a fixed ...
0
votes
1answer
20 views

Replace title column in post list with post meta value

I have created custom post type called booking. It have a meta booking_first_name, booking_last_name, booking_email, booking_phone, booking_phone_contact. Currently, I succeeded displaying email, ...
0
votes
1answer
40 views

get meta fields and taxonomy of any post type

I have created 6 different custom post type, each having different post meta and taxonomies associated with it. I am displaying all different custom post types in a dropdown using get_post_types() ...
0
votes
1answer
889 views

MySQL Query that looks for post with Custom Field, then changes Category

I'm looking for a MySQL Query that will look for all the posts with custom field "meta_key_I_want_to_find", then if the custom field is detected, add a category to that post. The category has already ...
0
votes
0answers
24 views

Search Form Including Price

I've been searching through posts & tutorials for four days now without any luck. My background is front-end web design but the latest project calls for a little more in depth work. I'm looking to ...
0
votes
0answers
37 views

User Answerable Multiple-Choice Question in Post

I am creating a plugin that adds multiple choice questions to WordPress. I wish for several to be displayed in a single post in a manner such that users may select an answer and receive instant ...