PluginProbe
WP Ultimate Post Grid / 2.8.0
WP Ultimate Post Grid v2.8.0
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_boxes / meta_box_general.php

meta_box_general.php in WP Ultimate Post Grid 2.8.0, at helpers/meta_boxes/meta_box_general.php

28 lines 1.3 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 // Grid should never be null. Construct just allows easy access to WPUPG_Grid functions in IDE.
3 if( is_null( $grid ) ) $grid = new WPUPG_Grid(0);
4 $premium_only = WPUltimatePostGrid::is_premium_active() ? '' : ' (' . __( 'Premium only', 'wp-ultimate-post-grid' ) . ')';
5 ?>
6
7 <input type="hidden" name="wpupg_nonce" value="<?php echo wp_create_nonce( 'grid' ); ?>" />
8 <table id="wpupg_form_general" class="wpupg_form">
9 <tr>
10 <td><label for="wpupg_type"><?php _e( 'Type', 'wp-ultimate-post-grid' ); ?></label></td>
11 <td>
12 <select name="wpupg_type" id="wpupg_type" class="wpupg-select2">
13 <?php
14 $grid_type_options = array(
15 'posts' => __( 'Grid of Posts or Pages', 'wp-ultimate-post-grid' ),
16 'terms' => __( 'Grid of Category or Taxonomy Terms', 'wp-ultimate-post-grid' ) . $premium_only,
17 );
18
19 foreach( $grid_type_options as $grid_type => $grid_type_name ) {
20 $selected = $grid_type == $grid->type() ? ' selected="selected"' : '';
21 echo '<option value="' . esc_attr( $grid_type ) . '"' . $selected . '>' . $grid_type_name . '</option>';
22 }
23 ?>
24 </select>
25 </td>
26 <td><?php _e( 'Type of grid to use.', 'wp-ultimate-post-grid' ); ?></td>
27 </tr>
28 </table>