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

learn more… | top users | synonyms (2)

4
votes
1answer
591 views

Display content from custom meta boxes in revisions

When I see a "revision" for a given post type, I only see the title, the content and the excerpt. How can I see the content of a custom meta box (or any other field, for that matter)?
0
votes
2answers
587 views

How to recover the post ID earlier in the WP admin hook action “firing” sequence?

I am creating a WP plugin based around Custom Post Types (CPT), where you can dynamically specify a CPT, complete with any number of associated dynamic Meta Boxes and form elements such as radio ...
3
votes
1answer
2k views

upload image in a meta box

im trying to implement uploading via a meta box without using the media manager, but i want it to add as a post attachment. im currently doing it just uploading and saving to the server. <?php ...
1
vote
1answer
186 views

Dashboard - get status and position of metaboxes and pass them to ajax method

I'm wondering if it's possible to get status and position of metaboxes added to a dashboard-like page. The main page of my plugin has several metaboxes laying in a two-columns page and a "table of ...
0
votes
1answer
352 views

Add box with custom per-page properties

Hey, I'm stuck trying to add a box with settings for all pages (the ones users create/edit). What I'm attempting to do is add 6, 7 check boxes and an input field for all pages that alters the ...
1
vote
1answer
888 views

post-excerpt not one of the options under screen options

I want to turn the post-excerpt function on but it doesn't even show as an option under 'screen options' for posts. How do I get it to display as a check box under screen options? I have tried ...
0
votes
1answer
185 views

conditionally echo <br /> in meta box data loop

I am working on a Thematic child theme and using the WPAlchemy Meta Box Class to create an 'Artwork Info' meta box that I want to conditionally echo like this at the end of each post: Title Medium ...
1
vote
3answers
2k views

Conflicting save_post functions when passing the post id and saving custom meta boxes for different post types

Post save functions are conflicting with each other when adding them to the save_post action hook. 2 different custom post types with 2 different (one for each post type) custom meta boxes. I'm ...
7
votes
4answers
8k views

How to set default screen options?

I'd love to be able to hide meta boxes using screen options, instead of removing them or restricting them to user roles, the goal is to just "uncheck" the meta box for the user. I see how this would ...
9
votes
3answers
5k views

Passing error/warning messages from a meta box to “admin_notices”

I have a simple meta box that updates the post custom fields (using update_post_meta()). How can I send a error or warning message to the next page after the user publishes/updates the post and ...
0
votes
1answer
91 views

Prevent custom post type from showing up in custom menus

How do I do that? Any custom post type I register shows up as a meta box on the menu page...
3
votes
2answers
2k views

Add filter 'wpautop' to meta box textarea

I'm using -this tutorial- to add simple meta boxes to a custom post type. But the textarea meta boxes are spitting out content all as one big paragraph, with no <p> formatting applied. What ...
0
votes
3answers
1k views

Wordpress global variables?

I've got page with metabox called "something". It can have two values "value" and "value2". I'm using a shortcode at this page and want it to display something's value. The problem is I don't know ...
5
votes
1answer
2k views

Action hook on Edit custom post type?

Is there an explicit action hook that will fire when (or just before) the admin Edit page renders for a custom post type? Something similar to {$new_status}_{$post->post_type}? I'm trying to find the ...
0
votes
1answer
909 views

meta box & callback function

Situation I got a class where i add a meta box to the post edit screen. EDIT: This is the working version now /** * Calls the class on the post edit screen */ function call_someClass() { ...
7
votes
2answers
2k views

post formats - how to switch meta boxes when changing format?

Problem After realizing that post formats are pretty popular, but only a extremly rough drawn concept, i see that users will run into possible traps. Post format ... uses post meta fields & ...
2
votes
6answers
3k views

Dynamically Creating Meta Boxes

So I was wondering if it's possible to dynamically create meta boxes in the post admin. I have a lot of data but don't want to hardcode every meta box needed in functions.php. An example would be a ...
3
votes
4answers
4k views

custom fields for attachments?

is it possible to add extra fields via the functions.php script for attachments in wordpress? Tried loads of examples but none seem to work. Worried an existing plugin might be affecting my attempts ...
0
votes
1answer
642 views

How to add a textarea to only one of the fields of this custom metabox?

This is the code I used to create the meta boxes: <?php $key = "project"; $meta_boxes = array( "project_services" => array( "name" => "project_services", "title" => ...
1
vote
2answers
5k views

Custom Post Type Metabox - Not Saving

I've added a custom post type, which is working great; I've also added two metaboxes, which appear to work well, but the content in them always disappears after a few minutes. If anyone could help ...
1
vote
2answers
703 views

Metabox saves on Update or Publish, but not on Saving Draft

I have created custom post types that also have custom meta_boxes I've created. Currently, they save when I publish or update a post, but they don't save when I'm in draft mode making changes. ...
1
vote
1answer
1k views

Why is save_post hook not running?

I am trying to save my meta box, I have something like function xxx_meta_box_callback() { add_meta_box('xxx-meta', 'xxx Details', 'xxx_meta_box', 'xxx-post-type', 'side', 'default'); ...
0
votes
1answer
425 views

Custom sidebars - get_sidebar() problems

I want to have different sidebars on different pages. So firstly I registered a few basic sidebars in functions.php. So they will be always there no matter where I move my theme. Let's name them ...
2
votes
3answers
428 views

validate a metabox based on the category that is selected

Ok Let's say I have 2 Categories. If a user select category A, they have to fill in metabox A and similarly for category B, it's metabox B. So my question is, I want to do a validate check, whereby if ...
0
votes
1answer
1k views

Metadata in loops

I have a standard Wordpress loop displaying items: $loop = new WP_Query( array( 'post_type' => 'images', 'orderby' => 'menu_order', ) ); while ...
1
vote
1answer
768 views

Automatically exclude categories from metabox based on title

I am designing a website which will be used as a school PA system. Users will be posting entries into categories named for specific dates that correspond to school assemblies. We have two assemblies a ...
0
votes
1answer
5k views

Getting metabox value?

I have a custom metabox made using the code from Wordpress Reference: http://codex.wordpress.org/Function_Reference/add_meta_box <?php /* Define the custom box */ // WP 3.0+ // ...
0
votes
2answers
453 views

Moving/dragging a metabox removes TinyMCE's content

I added a TinyMCE editor to my plugin settings page, but once I move (drag) the metabox, editor's content get lost. (the TinyMCE editor is completely not editable until refresh) Here is how I added ...
3
votes
2answers
3k views

Dashboard like meta boxes in my plugin - how to save their position and open/closed state?

I am trying to mimic the dashboard meta boxes UI in my WP plugin - the small metaboxes. I have already styled them and also the drag & drop feature works as I loaded the following script and ...
5
votes
1answer
2k views

Put the media uploader in a metabox

I find it very unnecessary to have an "add image" button that brings me to yet another screen that will let me upload content to my post. Ideally I would like to have a meta box with the option to ...
1
vote
1answer
1k views

How to add a “custom” date field to a custom post type?

Hey guys, I'm building a portfolio (which is a custom post type) and I want to store the date of the projects. I can achieve it the "regular" way with a meta box but I would like a "datepicker" or ...
0
votes
1answer
193 views

Move title “meta box” in post mode

I've created a custom post type with my own custom meta boxes. Now I want to move the title box to the side or simply remove it and place the same content in a custom meta box. How do I go about to ...
3
votes
3answers
260 views

How can I avoid re-inventing the Custom Fields wheel in my Plugin's Metabox?

Here's the scenario: In my plugin, I want to have a metabox show up on the post / page editor. I want the metabox to be -exactly- like WordPress' 'Custom Fields' metabox, ( Add another, delete, ...
1
vote
2answers
3k views

How to store multiple input values with same meta_key

is there a way to store the input value from multiple custom meta box fields with the same meta_key? I use the following code to store ONE value for the meta_key 'startdate': function startdate() { ...
1
vote
1answer
374 views

Change meta box when the page's template is changed

For my WordPress theme I have a custom portfolio post type and a portfolio page template to display them. What I want to do is add a meta box to the edit page area, but only when the page has the ...
0
votes
1answer
419 views

Post edit screen: How to check if meta_box is registered?

I got some custom post types where i deregistered the "title" meta box. Now i always get "Auto Draft" as title. To avoid this i'd like to add the name of a taxonomy as the title. But how would i check ...
2
votes
2answers
1k views

WP 3.0.5: Best way to add custom metaboxes for post categories?

I haven't been working with WP for a while and noticed that there are some new features in WP 3+ such as creating meta data for taxonomies. I'd like to be able to add unique meta data setups for ...
1
vote
1answer
3k views

How to add a select menu to this metabox code?

I'm using a metabox script that works great for having absolute control over the design and placement of the metabox fields. There is one problem: I can't remember where I found the script and need to ...
0
votes
1answer
206 views

Can I attach a plugin via my add_filter callback contents?

I'm trying to add my plugin interface to the Category Editor. I've easily attached it to the post and page editor using the add_meta_box() filter, but there does not appear to be an add_meta_box hook ...
0
votes
1answer
187 views

Custom Meta Data is not being saved

I have created a custom meta box using following link in wordpress 3.0: http://farinspace.com/how-to-create-custom-wordpress-meta-box/ I am using same code and custom meta data is not being saved. I ...
1
vote
2answers
1k views

Unable to save custom taxonomy terms in a custom-built metabox

I've roughly followed the tutorial here on how to create "custom taxonomy input panels". I'm using a custom post type of homes and a custom taxonomy called beds (used to record the number of beds in a ...
1
vote
1answer
3k views

I'm using add_meta_box() but want to include TinyMCE editor *and* Media Uploads for each box

I'm using a very lightweight plugin called WPAlchemy that lets me rapidly create meta-boxes for posts and pages. I've ben able to convert <textarea>'s into rich, TinyMCE's editors just fine. ...
0
votes
3answers
393 views

Adding admin menus to wordpress

I am trying to add a menu box to Pages > Pages or Pages > Add New, basically whenever they access a page, be it to edit an existing page or add a new one, I would like to add a menu box under ...
0
votes
1answer
795 views

Add a custom field when adding / editing a page / post in admin panel

I create a new theme and I the page / post is divided to: Title Slogan Content I want to add a slogan field in the admin panel, where the user adds or edits a post or page. After I will use in ...
0
votes
2answers
2k views

Meta Box on Custom Post Type not saving

I have a custom post type which is working fine, however the meta box does isn't saving. Long & short, i'm stumped! add_action('init', 'portfolio'); function portfolio() { $args = array( ...
3
votes
3answers
4k views

Meta Boxes in Front End Post Submission Form

How can I add meta boxes to the front end post submission form? Similar to front end post submission that creates new posts, the form replies should go directly into the post meta boxes. Meta Boxes ...
0
votes
2answers
2k views

Display list of tags as drop down menu or radio buttons in a meta box?

I would like to group posts of a custom post type based on tags, but the default functionality does not do for the project I am working on. I want the user to be able to select only one tag, not ...
1
vote
1answer
442 views

metabox with custom post type values

I need to re-write a current WP website and I think Custom post types are required, combined with Meta Box. The basic layout is Author (custom) Books (custom) Photos (custom) All 3 custom post are ...
7
votes
4answers
8k views

Creating a metabox to upload multiple images

Is it possible to make a meta box that attaches multiple images to a post?
1
vote
3answers
302 views

Is it possible to create relational metabox values in a custom post?

I have a custom post type ('Model') for a sports modelling agency, and it requires the model to enter sports they are competent at, and also rank their ability from 1 to 5. For example, given the ...