Custom Fields are fields that can holds arbitrary extra information known as meta-data.

learn more… | top users | synonyms (2)

0
votes
1answer
20 views

Sorting posts by meta values: 2 different orders

I have a meta value for a custom post type called workshop which is the start_time of the workshop as a UNIX timestamp. Right now I'm able to sort the posts ascending or descending with ...
0
votes
1answer
105 views

How to add google map to custom field

I need to show a map throw custom field Here's my code, the field name is 'show_map' <div id="view1"> <?php $location = get_field('show_map', 'options'); ...
1
vote
0answers
51 views

Custom User meta field display

I'm using PODS plugin (https://wordpress.org/plugins/pods/) to extend main types in wp and WP Tiles for tiles rendering (https://wordpress.org/plugins/wp-tiles/). I'v already added field position to ...
0
votes
0answers
26 views

How to add a default field Name to post Custom Fields

I would like to have the "Name" field in the Custom Fields section of of Wordpress backend to have a certain value by default. For example, when the user starts a new post, I would like the Name of ...
1
vote
1answer
111 views

How to Filter Posts by Custom Fields?

I would like to learn the best way to filter custom post types by custom fields. In the example I am working on, I use custom taxonomies to organize my posts and filter them. I would like to add ...
-2
votes
2answers
70 views

How to display search query as formatted text?

I am trying to display a site vistors search query on the search page. The form has custom fields so is not showing if it's "Search" and it doesnt show none of my custom fields. My search form - ...
-2
votes
1answer
45 views

How much worse is querying custom fields compared to custom taxonomies, quantitatively

OK, I know (because i've read it many times) why custom fields is less efficient than custom taxonomies when it comes to querying/filtering posts, but just how inefficient is it by comparison? I'd ...
0
votes
1answer
35 views

How to use a specific custom field in a custom post type as slug

I'd like use a specific custom field in a custom post type as the slug for the post. My custom post type is members and the custom field that I want to use as the slug is member_user. How can I do ...
0
votes
0answers
26 views

Search on Category and BETWEEN custom meta field

Background I am building simple car theme where I want to review cars, however, I'm really struggling with my search implementation. I have added a couple of custom meta fields to the post including ...
0
votes
1answer
65 views

Loop through two different sets of custom fields

I created a Custom Field ('custom_name') to allow content editors to specify a 'custom_name' (different from the title of the page) to any post created: custom_name - (Field type --> 'text') For a ...
0
votes
1answer
55 views

Custom Fields as Post Type Options

Im using a theme for vehicle listings and the WPUF Pro plugin for frontend submitting. WPUF plugin automatically reads the taxonomies of themes post_type (vehicle), but the theme got vehicle ...
0
votes
1answer
58 views

Loop through incrementing custom fields

I created 4 custom fields for a specific page. Field type: Post Object (I grab thumbnails and titles from the posts) Field names: featured_content_1 featured_content_2 featured_content_3 ...
0
votes
0answers
90 views

How to get posts ORDERBY a custom taxonomy term's custom field?

I have a custom taxonomy program_taxonomy : /* register a common taxonomy for DRAMAS & reality_shows to get post by terms in PROGRAMS page */ register_taxonomy( 'program_taxonomy', array ...
0
votes
0answers
25 views

Send email to different users depending on the field selected in woocommerce?

So, I've been searching high and low and I don't know if this is possible, but I figure this is the best place to try and see.. I have a checkout field added to my checkout page in woocommerce. It ...
0
votes
0answers
35 views

Trouble displaying custom fields within post type in WP_Query Loop?

I'm trying to write a query that displays a custom field within my custom post type 'Inventory'. The custom field name is category and the field type is taxonomy. The category is selected by a ...
0
votes
1answer
927 views

Create a full width responsive header image per page

I’m new to Wordpress - currently building a site that has a few pages (Home, Artists, History, Videos). Each of those pages need a custom header containing a responsive full width image (the image ...
2
votes
3answers
117 views

Order posts according to user defined order for meta values?

I have set up some CPTs and storing a meta key/val for each of them. When I get those posts, I need to order them by the meta value, but, the order of the meta values will be defined in an array by ...
0
votes
0answers
22 views

Custom elements for Wordpress Admin Menu Manager

Scenario: I want to allow users for a theme to set icons (fontawesome) to their menu items via the wordpress Menu Manger. To achieve this, one could set "screen options" to show css class field and ...
0
votes
0answers
21 views

View list of categories from values ​​in custom fields

Through the Advanced Custom Fields created a field to add values ​​in each category. example: Category A = Cars Category B = Aircraft Category D = Boats Category E = Aircraft Category F = Boats ...
0
votes
1answer
64 views

Get file size from ACF repeater field

I am using ACF plugin and trying to get file size which in a repeater field, but it returns nothing. Here is my code. <?php if(have_rows('download')) : ?> <ul class="file"> ...
1
vote
0answers
174 views

Display value of custom field of custom taxonomy in single post?

I have a review site, which uses a custom taxonomy called 'show' to organize posts. I have used Advanced Custom Fields to add a field to the 'show' taxonomy called 'twitter_handle'. I am trying to ...
0
votes
1answer
70 views

Transfer self made functions.php custom fields to Advanced Custom Fields [closed]

I have recently taken over a wordpress site that needs some serious renovating. The previous developer created custom fields himself in functions.php. I am serious advocate of Advanced Custom Fields, ...
0
votes
3answers
119 views

Display posts if a custom field value is equal to another custom field value

I have 2 custom post types "Shops" and "Restaurants". Each of these have custom fields associcated with them. For example, One field in Shops is "Shop ID" and one in Restaurants is "Restaurant ID". ...
0
votes
1answer
31 views

How can I set and update the the_date according to a custom field of the post

How can I set and update the the_date according to a custom field of the post? I have a custom field "date-time" with the following format yyyy-mm-dd hh:mm e.g. 2015-09-30 08:12 I'd like this date ...
0
votes
0answers
49 views

Automatically set the_post_thumbnail to Custom Field Value

I have a custom field (built using Advanced Custom Fields) that I've chosen a Featured Image with. Everything works great, but I'm looking at using this plugin for Social Sharing: ...
0
votes
1answer
52 views

How to copy a custom field from the user's CPT to the user's normal posts

Each author has a single post in a CPT. In their CPT post they have a custom field. Each author can also post to a normal post type as much as they like. How can I copy the custom field of the ...
0
votes
1answer
137 views

Cannot save values to custom fields for variations on Woocommerce 2.4.6

I'm having trouble setting up custom fields for variations on Woocommerce. I followed this very helpful tutorial to get the ball rolling, and everything worked well enough except that my values for ...
1
vote
1answer
273 views

Create a random unique 6 digit number as custom field for custom post type

I use the following function to create a random unique 6 digit number and save it in a custom post type meta field. I am unsure about the use of rewind_posts() inside a while loop. The idea is that ...
0
votes
1answer
25 views

create a custom field that let me include other posts

I need to create a custom post type with a single custom field that is, basically, a list of other posts id. In order to find that ids I would like to add a kind of "ajax search" ability to that ...
0
votes
0answers
27 views

Copy custom field value to serialized meta

The scenario: I've been using Advanced Custom Fields to create a custom field called "subtitle", to have, of course, a subtitle below the post titles. It's called using: get_field ('subtitle'); ...
0
votes
1answer
189 views

How to enable revisions for post meta data?

Normally wordpress keeps revision of wp_post table. But for generating a report I need some custom fields to be tracked while any update happens. As custom fields are saved in wp_postmeta table I need ...
0
votes
1answer
39 views

How do I save Multiple fields in a meta box?

Currently I am doing public function prfx_meta_save ($post_id){ if (isset( $_POST[ 'firstname'])){ update_post_meta($post_id, 'firstname', $_POST[ 'firstname']); } if (isset( ...
0
votes
1answer
224 views

How to create a searchable database with a single-field search box at the front end?

I have seen many websites having developed a (hidden) database of their certified clients (actually details of the clients and the given certificates) and they have devoted a web page where clients ...
0
votes
1answer
78 views

WP_Query with Pagination and orderby meta_value_num showing duplicates

I have the following set of Arguments I'm running in a WP_Query. $paged = (get_query_var('paged')) ? get_query_var('paged') : 1; $args = array( 'tag' => $taxonomy, 'post_type' ...
0
votes
0answers
34 views

Custom fields in a loop won't display without post_id

I am trying to loop through the posts to extract custom field values to use it in html. Using Advanced Custom Fields and the plugin has a nice get_field() and the_field() functions that should work in ...
0
votes
0answers
132 views

How to dynamically populate select field with custom taxonomy?

I'm using the WP Types plugin to create custom post types, taxonomy and custom fields. I have a custom post type 'Offers' and the Offers are grouped into specific groups using a 'brands' taxonomy for ...
0
votes
1answer
251 views

Upload file to product page via admin panel

My client wants to be able to upload a product datasheet file (PDF) for each product. At the moment I simply upload the PDFs to the server and add HTML to link to them in the 'product Short ...
0
votes
1answer
39 views

How to Pass values to Custom Field through PHP in WordPress Posts?

Suppose i have a function function mytable(){ $count_value = get_kudos_count( $post_id ); } How to send $count_value dynamically to the custom field present in WordPress post ? Let us assume the ...
0
votes
2answers
101 views

Add new post using a page inside the website

I have been searching for several hours to find a way to embed the "Add New Post" inside a page in the front end. I read this post but sadly no answer to it. I have embedded the login form in ...
0
votes
1answer
73 views

How to display a WordPress Custom Field only on a specific day of the week?

I've got WordPress site for which I've set up a custom post_type along with some custom fields created with CMB2 to display extra stuff within my custom posts. When editing a single item for my ...
0
votes
1answer
20 views

Unable to render custom field after attempt to generate a list of recent post in page template

When I try to render a list of recent post type either by using WP functions or WP query, I'm not able to render the custom fields that I have to render bit after. The content of box with class ...
0
votes
0answers
15 views

Custom Meta box not Saving

I read the other questions but i couldn't find an answer which suits my exact problem. I noticed my custom meta boxes dont save the values anymore. It worked fine until recently. Here's the pastebin: ...
0
votes
1answer
86 views

How to hide meta box values from custom fields list?

I have created a metabox : function drama_description_metabox_markup() { global $post; $drama_description_metabox_markup = get_post_meta( $post->ID, 'drama_description', true ); ?> ...
0
votes
0answers
21 views

Image didn't load from taxonomy's custom meta field

adding some custom fields (image field) to custom taxonomy (issue) basing on code from (https://github.com/bainternet/Tax-Meta-Class), trying to out put the image attached to each taxonomy term by ...
0
votes
0answers
32 views

Special characters WP Custom Fields Search

I am using WP Custom Fields Search for my custom content Search. I have the problem, that my special characters are not displayed as utf-8 character. Database is correct utf-8 ... Thanks
0
votes
1answer
62 views

How to display Meta Field Value?

I am trying to display the value of a Meta field on single.php. The Meta Key is 'current_rank'. I tried... <?php echo get_post_meta( get_the_ID(), 'current_rank', true); ?> This code does ...
0
votes
1answer
173 views

How to add meta fields to custom taxonomy add/edit page?

I have a custom taxonomy 'issue'. I tried to add some meta fields to the add/edit issue pages in the dashboard using the method explained by Ohad Raz ...
0
votes
1answer
22 views

Append custom field items to content from plugin

I know you can use add_filter( 'single_template', 'modify_page_template' ); function modify_page_template($single_template) { global $post; if ($post->post_type == 'post' || ...
0
votes
0answers
39 views

how to save custom field added to a custom taxonomy's quick edit

I registered a custom taxonomy as tags for a custom post. I use Advanced Custom Fields plugin to add a custom field to it. I wrote a plugin to customize edit-tags.php: I have my custom field showing ...
1
vote
1answer
22 views

Can I create a template or doctype for my blog site?

I am new to wordpress, but I know other cms system like umbraco or orchard. Say I want to do a blog site, in umbraco or orchard, I can add a custom field (e.g. main image), and in the layout design, ...