PluginProbe
WP Ultimate Post Grid / 1.7.2
WP Ultimate Post Grid v1.7.2
4.1.1 trunk 1.5 1.6 1.7 1.7.1 1.7.2 1.8 1.9 2.0 2.1 2.2 2.3 2.4.0 2.5.0 2.6.0 2.7.0 2.8.0 2.8.2 3.0.0 3.3.0 3.4.0 3.5.0 3.6.0 3.7.0 All 32 releases
wp-ultimate-post-grid / helpers / meta_box_post.php

meta_box_post.php in WP Ultimate Post Grid 1.7.2, at helpers/meta_box_post.php

35 lines 866 B
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2
3 class WPUPG_Meta_Box_Post {
4
5 public function __construct()
6 {
7 add_action( 'admin_init', array( $this, 'add_meta_box' ), 10 );
8 }
9
10 public function add_meta_box()
11 {
12 $post_types = get_post_types( '', 'objects' );
13
14 unset( $post_types[WPUPG_POST_TYPE] );
15 unset( $post_types['revision'] );
16 unset( $post_types['nav_menu_item'] );
17
18 foreach( $post_types as $post_type => $options ) {
19 add_meta_box(
20 'wpupg_meta_box_post',
21 'WP Ultimate Post Grid',
22 array( $this, 'meta_box_post' ),
23 $post_type,
24 'normal',
25 'high'
26 );
27 }
28
29 }
30
31 public function meta_box_post( $post )
32 {
33 include( WPUltimatePostGrid::get()->coreDir . '/helpers/meta_boxes/meta_box_post.php' );
34 }
35 }