Refers to a box-like reusable user-interface component common in the WordPress backend.

learn more… | top users | synonyms (2)

0
votes
2answers
986 views

How to make a metabox that contains link categories?

I'm looking for some suggestions or tutorial links about how to create a meta box that allows users to choose from a list of link categories. So far I've been looking at this post about taxonomies in ...
-1
votes
0answers
29 views

unable to pass array variable to select field in metabox

I'm using this code to get data from text type metabox..this will create an array $args = array('post_type' => 'locations_add'); $prefix = 'nilgiris_'; $the_query = new WP_Query($args); if ...
2
votes
2answers
793 views

How to Use WordPress Color Picker API in Custom Post Type Metabox

I have a Custom Post Type called "Banner" which has a custom Meta box with two advanced fields "Title" (text Field) and "Color" (color Picker). Can you please let me know how to use the WP Color ...
18
votes
9answers
23k views

meta_query with meta values as serialize arrays

I'm working on a project in which I'm creating a custom post type and custom data entered via meta boxes associated with my custom post type. For whatever reason I decided to code the meta boxes in ...
0
votes
1answer
23 views

Problem with saving large amount of data in postmeta/usermeta

I am facing issues saving large amount of data in post meta field e.g. I have created a field Bio/description and put a huge amount of text in it. Now when I save it, it saves some of the text and ...
0
votes
1answer
30 views

Odd behaviour for the update button when displaying a WP_List_Table

I am currently trying to add a WP_List_Table to a metabox in the edit page of a custom type. The code is currently class Post_Table extends WP_List_Table { public function __construct() ...
0
votes
1answer
430 views

Multiple wp_editor instances in custom post type using Ajax

In a custom metabox, I need to generate a tinny wysiwyg wp_editor everytime we click on a button.. I struggled a lot with this and couldn't achieve it. The js $.ajax({ url: ajaxurl, data: ...
0
votes
0answers
14 views

How to add custom meta box to Quick Edit?

I have custom post type imggal. I want to add custom meta box imggallink to quick edit and can't find any right info for it. How to get it? Help please. I try to add column function ...
-3
votes
0answers
20 views

WooCommerce Product Attribute Metabox Custom Checkbox [closed]

In WooCommerce when we choose a variable product, it creates the metaboxes in file class-wc-meta-box-product-data.php using output function from html-product-attribute.php file to display in admin. ...
0
votes
0answers
9 views

Time blocking for publishing a custom post type

I'm looking for a way to replace the "time" input boxes on the post meta box. When scheduling a post I want to replace the time inputs with a dropdown populated from the database. When someone selects ...
0
votes
2answers
453 views

Include custom fields into the content of a regular page

Here's my setup: Parent "Gallery" page: _regular page, not custom type or anything _ Several "Project" child pages (could be as few as 1, unlimited number): also normal pages Child pages will ...
0
votes
2answers
586 views

Hide Meta Boxes for Non-Admins

I have a review based wordpress site where I have a page for each different company where there users can review them. The theme I use adds a custom post type called "review" and I have used Press ...
0
votes
3answers
1k views

Add multiple custom meta boxes to different custom post types

I want to add one custom meta box to a specific custom meta type "chifres" and two custom meta boxes to a specific custom meta type "presse". This is how far I've gotten: Here is my code: //Add ...
1
vote
1answer
2k views

Add Standard Page Attributes Metabox for Page Parent

I have a custom post type 'product' supplied to me by a Wordpress eCommerce plugin that does not offer the option to change the Page Parent in the Page Attributes Metabox. I'd like to remedy that. I ...
0
votes
1answer
570 views

Help integrating Custom post type meta field with custom profile fields

I have a custom post type for "locations" and I need to have "users" log in and be able to pick a location that is within a certain distance from them. I have added some spots to the profile using ...
0
votes
0answers
16 views

Extend Metabox.io map field to sepearate lat long values

I am trying to separate the latitude and longitude values returned by the map field from the metabox.io plugin and save them as separate values. I have found a comment from the author (shown ...
0
votes
1answer
26 views

Warning: call_user_func() expects parameter 1 to be a valid callback, function

I keep getting this error when. I am trying to insert a dashboard widget and I don't know what's causing the error. Warning: call_user_func() expects parameter 1 to be a valid callback, function ...
0
votes
1answer
28 views

Adding Meta Box to Specific Submenu Page

I've created this page: function wpdocs_register_my_setting() { add_submenu_page( 'edit.php?post_type=task', 'View Tasks', 'View Tasks', 'manage_options', ...
0
votes
2answers
26 views

Get custom term meta problem on single post type

I'm trying to display a custom field value added to custom taxonomy on single custom post type. I have articles post type with custom taxonomy called issue. I used the code from Tax-Meta-Class to add ...
2
votes
1answer
978 views

wp_dropdown_categories in custom post type with custom taxonomy

I have a custom post type with its own taxonomy, basically 'show venues' is the post type and venue-regions is the taxonomy. Seeing how a venue cant exsist in mutiple regions, I've removed the ...
0
votes
2answers
478 views

Select box saves but doesn't update value in admin

I have a select dropdown in my custom meta box in the admin area. It offers two options Approved and In Progress. When I select an option and save it the database is updated, but the value in the ...
0
votes
1answer
817 views

save_post action inside a custom metabox class not working

I am writing a class to create metaboxes and save the form data. The problem is, I keep getting a warning when I click "publish": Warning: call_user_func_array() expects parameter 1 to be a valid ...
1
vote
1answer
436 views

How to add meta box to plugin admin page?

There is the codes. add_action('admin_menu', 'test'); function test(){ add_menu_page( 'Test plugin', 'Test plugin', 'manage_options', 'test_plugin_options', 'test_plugin_admin_options' ); ...
1
vote
5answers
896 views

How do I get attachment_id?

This is trivial, but I can't really find an answer, I've seen some hints like search in database etc., but this is madness. Basically, I have a metabox with upload button that allows you to upload or ...
0
votes
1answer
1k views

Using radio button meta data from a custom meta box

Very new to attempting PHP and am hacking together my first plugin using tutorials.. I have a custom meta box with a Yes/No radio button on all WordPress pages (in the editor). EDIT- I removed the ...
1
vote
2answers
2k 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
2k views

Displaying Metabox value (custom post type taxonomy)

I have been stuck on this for days, reading articles and articles and nothing works. I am trying to display the value of my metabox on a template page. I successfully added the metabox, and I see ...
0
votes
0answers
29 views

Redirect to an anchor after click update button in a metabox (CPT)

On my Custom Post Type (CPT), I had multi metabox and I need to have some buttons to update each metabox. I use jQuery to trigger the submit event when a different element is clicked (see this answer ...
3
votes
3answers
3k views

Adding submit or update button to custom metabox?

I have alot of custom meta boxes, and the user has to scroll to the top everytime he wants to save the meta info. Is there a way to put submit buttons at every meta box that does that same as the ...
0
votes
0answers
19 views

Add custom field for users

I am using Metabox for a while and is a great plugin but I was using in pages and posts. Now I want to add a simple checkbox to users profile page, is that possible with Metabox plugin? Can any ...
0
votes
1answer
33 views

Filter posts of custom post type by meta key in (List All Section)

How can I filter the posts which are displayed on the admin list all page of a custom post based on the value of the a value. So far I know how to do the following anywhere on the front end: $args = ...
1
vote
1answer
73 views

How to add tab which is visible only in admin side of product in woocommerce? [closed]

I am new in wordpress development. I want to do add settings in a product page in a new tab. How to I add settings code That I tried to add Tab //add product tab link in admin ...
0
votes
2answers
470 views

CMB select with data from CPT

I'm using the CMB framework for creating metaboxes (https://github.com/jaredatch/Custom-Metaboxes-and-Fields-for-WordPress) and I want to add a select box which prepopulates with titles from a custom ...
2
votes
1answer
310 views

How to remove items in quick edit panel-Function for remove items in wordpress quick-edit panel?

I need to remove some items in the quickedit panel .Let me know is there any way to hide product attribute list from quick edit window of product page in woocommerce? Currently iam doing this via css ...
1
vote
1answer
30 views

Undefined 'post_type' error on Add new page

I created a meta box for page see the following code: add_action('add_meta_boxes', 'add_metaboxes'); function add_metaboxes() { add_meta_box( 'wpt_slider_meta', 'Add Slider ...
2
votes
3answers
1k views

Add custom field to existing meta box?

First off, I have been able to successfully implement custom fields within a custom meta box in Wordpress. I understand how this works. My question is, is there a way for me to add a custom field to ...
6
votes
3answers
4k views

Add the sidebar/widget editor to the post edit screen?

There are (among others) two common ways of customizing the sidebar on an individual post: Create a new sidebar for the post, using code or plugins like Custom sidebars, WP Custom Sidebar, Per Page ...
0
votes
1answer
24 views

Error when adding Meta Boxes, but only when adding 3 with the same callback

I have 2 functions, one which removes the original meta boxes for 3 custom taxonomies, and one which recreates them in the desired location. The problem is that with all 3 removed, NONE of the meta ...
1
vote
2answers
937 views

Wordpress 3.5 Media Uploader - Only allow 1 upload and certain file types

I am trying to include the new WP Media Uploader in a Custom Meta Box. I found this tutorial: http://codestag.com/how-to-use-wordpress-3-5-media-uploader-in-theme-options/ However i am looking for ...
11
votes
7answers
4k views

Disable dragging of meta boxes?

Anyone know how to disable this functionality so the meta boxes can't be repositioned?
1
vote
1answer
472 views

How to access global $wp_meta_boxes variable on front-end?

Is there a way to take the global $wp_meta_boxes variable to be used in the front-end? Currently the $wp_meta_boxes is accessible on specific admin pages only. I've found a similar question about ...
1
vote
1answer
45 views

How to select the contents in the text view textrea in wp_editor?

I am trying to count words among other text stats entered into the default post editor (wp_editor). Its supposed the write word count out to <div id="word count"> in the meta box immediately ...
17
votes
4answers
11k views

How can I put a custom meta box above the editor but below the title section on the edit post page?

I have a custom meta box for a custom post type that my client wants placed between the title/permalink section and the post editor in the admin panel. Is this possible and if so is there a ...
34
votes
2answers
13k views

Create more Meta Boxes as needed

I'd like users to be able to create and remove additional meta box fields as needed. For example, say a music podcast with a variable amount of songs played per episode. The user should be able to ...
0
votes
1answer
23 views

Add URL to selected post in meta box

How can I change this code $posts = get_posts(array('post_type'=> 'lesson', 'post_status'=> 'publish', 'suppress_filters' => false, 'posts_per_page'=>-1)); //here you add the ...
0
votes
0answers
15 views

Wordpress Costums Field Comment Box on Admin Page (Post Editing)

can help me about wordpress comment field on post editing in admin page? i want to change the default form like picture above : to like this...
0
votes
0answers
23 views

Move Meta Boxes for Custom Post Type

I'm trying to move the metaboxes for a custom taxonomy from 'side' to 'normal'. Unfortunately, when I remove_meta_box for the 'side' position, it breaks the 'Add term' functionality and I can't figure ...
0
votes
2answers
49 views

Creating alternate meta box context locations

I am trying to create two additional add_meta_box context locations ('after_title' and 'after_editor') within posts. This doesn't appear to do what I think it should. The meta box does appear on the ...
0
votes
1answer
64 views

Change post template the proper way

I'm trying to create an option on edit posts screen (backend) to select different post template based the selection and I need your opinions guys if that is the proper way. Here is what I've tried so ...
0
votes
1answer
319 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 ...