meta-boxes

wordpress: add custom meta-box to pages overview not only to posts/pages?

不问归期 提交于 2021-02-11 01:16:54
问题 I know how to add meta boxes to pages/posts/custom_post_type ($post_type) pages: $screens = array( 'post', 'page' ); foreach ( $screens as $screen ) { add_meta_box( 'myplugin_sectionid', __( 'My Post Section Title', 'myplugin_textdomain' ), 'myplugin_meta_box_callback', $screen ); } but how do i add a meta box to the pages-overview? i need a link-list there to some special pages ... I know there are plugins who can do this: http://wordpress.org/plugins/meta-box/screenshots/ but only on posts

wordpress: add custom meta-box to pages overview not only to posts/pages?

天涯浪子 提交于 2021-02-11 01:16:19
问题 I know how to add meta boxes to pages/posts/custom_post_type ($post_type) pages: $screens = array( 'post', 'page' ); foreach ( $screens as $screen ) { add_meta_box( 'myplugin_sectionid', __( 'My Post Section Title', 'myplugin_textdomain' ), 'myplugin_meta_box_callback', $screen ); } but how do i add a meta box to the pages-overview? i need a link-list there to some special pages ... I know there are plugins who can do this: http://wordpress.org/plugins/meta-box/screenshots/ but only on posts

Is it possible to make WordPress page attribute meta box select option display as images?

∥☆過路亽.° 提交于 2021-01-29 08:28:01
问题 I am customizing the page attribute meta box for posts pages on a WordPress them I am developing. I will have multiple templates to choose from for each post and I was wondering if there is a way I can replace the select > option text where the templates show to display as images of how each template would look and the user would then select one of them and the correspondent template would be selected. Have tried a million things but nothing seems to do it... Would appreciate any help. Thank

When does Wordpress add hide-if-js class to metaboxes

烂漫一生 提交于 2020-05-26 16:27:42
问题 I have 2 metaboxes added to "page" type. But only in first case Wordpress (on its own) adds hide-if-js class to metabox container. Questin is - when does Wordpress add this hide-if-js to the metabox container div ?? First metabox add code - this one gets hide-if-js class automatically: add_action( 'add_meta_boxes', 'add_portfolio_template_meta' ); function add_portfolio_template_meta() { add_meta_box('projects-details-for-template', 'Portfolio template options:', 'projects_details_for

Add a custom meta box on order edit pages and display it on the customer order pages

故事扮演 提交于 2020-05-26 09:36:16
问题 In WooCommerce, would like to add a custom meta box on WooCommerce Admin order pages. In this box, I just want to enter a tracking number in a text field that saves to that order. Then on the customer view order page, I would like to display a button that opens a modal with tracking information. The modal will just pull in an iframe with a URL that has the tracking number at the end. The courier company I'm using has a tracking website so for now I'm just going to display the iframe in the

Add a custom meta box on order edit pages and display it on the customer order pages

醉酒当歌 提交于 2020-05-26 09:36:06
问题 In WooCommerce, would like to add a custom meta box on WooCommerce Admin order pages. In this box, I just want to enter a tracking number in a text field that saves to that order. Then on the customer view order page, I would like to display a button that opens a modal with tracking information. The modal will just pull in an iframe with a URL that has the tracking number at the end. The courier company I'm using has a tracking website so for now I'm just going to display the iframe in the

Add a custom meta field value after the price on single products pages

吃可爱长大的小学妹 提交于 2020-01-23 11:40:11
问题 I have created a custom Metabox named "Info" on my product pages. I would like to show the corresponding meta field value in the template content-single-product.php behind the product price. But it doesn't output the corresponding meta field value and this is not working. My problem is that I don't know how I can call the corresponding meta field value. Is it in function.php php file or in content-single-product.php template. This is the code that I use to create the Metabox (and it works) :

Add a custom meta field value after the price on single products pages

点点圈 提交于 2020-01-23 11:39:47
问题 I have created a custom Metabox named "Info" on my product pages. I would like to show the corresponding meta field value in the template content-single-product.php behind the product price. But it doesn't output the corresponding meta field value and this is not working. My problem is that I don't know how I can call the corresponding meta field value. Is it in function.php php file or in content-single-product.php template. This is the code that I use to create the Metabox (and it works) :