balmet.com

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs

taxonomy.php (9133B)


      1 <?php
      2 /**
      3  * Redux Pro Taxonomy Meta config.
      4  * For full documentation, please visit: http://devs.redux.io/
      5  *
      6  * @package Redux Pro
      7  */
      8 
      9 defined( 'ABSPATH' ) || exit;
     10 
     11 if ( ! class_exists( 'Redux_Taxonomny' ) ) {
     12 	return;
     13 }
     14 
     15 // Change the priority the Redux_Taxonomy boxes appear.
     16 Redux_Taxonomy::set_args(
     17 	$opt_name,
     18 	array(
     19 		'taxonomy_priority' => 50,
     20 	)
     21 );
     22 
     23 Redux_Taxonomy::set_term(
     24 	$opt_name,
     25 	array(
     26 		'id'             => 'demo-taxonomy',
     27 		'title'          => __( 'Cool Options', 'your-textdomain-here' ),
     28 
     29 		// Slug for every taxonomy you want.
     30 		'taxonomy_types' => array( 'category', 'post_tag' ),
     31 
     32 		'add_visibility' => true,
     33 
     34 		// Can bet set on term, section, or field level. Denotes what fields to be displayed on the add {TERM} pages.
     35 		'sections'       => array(
     36 			array(
     37 				'title'  => __( 'Home Settings', 'your-textdomain-here' ),
     38 				'icon'   => 'el-icon-home',
     39 				'fields' => array(
     40 					array(
     41 						'id'             => 'tax-text',
     42 						'type'           => 'text',
     43 						'add_visibility' => true,
     44 						'title'          => __( 'Input 1', 'your-textdomain-here' ),
     45 					),
     46 
     47 					array(
     48 						'id'             => 'tax-text-2',
     49 						'type'           => 'text',
     50 						'add_visibility' => true,
     51 						'required'       => array( 'dovy1', '=', '222' ),
     52 						'title'          => __( 'Input 2', 'your-textdomain-here' ),
     53 					),
     54 					array(
     55 						'id'             => 'opt-button-set',
     56 						'type'           => 'button_set',
     57 						'title'          => __( 'Button Set Option', 'your-textdomain-here' ),
     58 						'subtitle'       => __( 'No validation can be done on this field type', 'your-textdomain-here' ),
     59 						'desc'           => __( 'This is the description field, again good for additional info.', 'your-textdomain-here' ),
     60 						'add_visibility' => true,
     61 						'options'        => array(
     62 							'1' => 'Opt 1',
     63 							'2' => 'Opt 2',
     64 							'3' => 'Opt 3',
     65 						),
     66 						'default'        => '2',
     67 					),
     68 					array(
     69 						'id'             => 'dovy3',
     70 						'type'           => 'text',
     71 						'add_visibility' => true,
     72 						'title'          => __( 'Dovy Input3', 'your-textdomain-here' ),
     73 					),
     74 					array(
     75 						'id'       => 'webFonts',
     76 						'type'     => 'media',
     77 						'title'    => __( 'Web Fonts', 'your-textdomain-here' ),
     78 						'compiler' => 'true',
     79 						'mode'     => false,
     80 						// Can be set to false to allow any media type, or can also be set to any mime type.
     81 						'desc'     => __( 'Basic media uploader with disabled URL input field.', 'your-textdomain-here' ),
     82 						'subtitle' => __( 'Upload any media using the WordPress native uploader', 'your-textdomain-here' ),
     83 					),
     84 					array(
     85 						'id'       => 'section-media-start',
     86 						'type'     => 'section',
     87 						'title'    => __( 'Media Options', 'your-textdomain-here' ),
     88 						'subtitle' => __( 'With the "section" field you can create indent option sections.', 'your-textdomain-here' ),
     89 						'indent'   => true,
     90 					),
     91 					array(
     92 						'id'       => 'mediaurl',
     93 						'type'     => 'media',
     94 						'url'      => true,
     95 						'title'    => __( 'Media w/ URL', 'your-textdomain-here' ),
     96 						'compiler' => 'true',
     97 						'desc'     => __( 'Basic media uploader with disabled URL input field.', 'your-textdomain-here' ),
     98 						'subtitle' => __( 'Upload any media using the WordPress native uploader', 'your-textdomain-here' ),
     99 						'default'  => array( 'url' => 'http://s.wordpress.org/style/images/codeispoetry.png' ),
    100 					),
    101 					array(
    102 						'id'     => 'section-media-end',
    103 						'type'   => 'section',
    104 						'indent' => false,
    105 					),
    106 					array(
    107 						'id'       => 'media-nourl',
    108 						'type'     => 'media',
    109 						'title'    => __( 'Media w/o URL', 'your-textdomain-here' ),
    110 						'desc'     => __( 'This represents the minimalistic view. It does not have the preview box or the display URL in an input box. ', 'your-textdomain-here' ),
    111 						'subtitle' => __( 'Upload any media using the WordPress native uploader', 'your-textdomain-here' ),
    112 					),
    113 					array(
    114 						'id'       => 'media-nopreview',
    115 						'type'     => 'media',
    116 						'preview'  => false,
    117 						'title'    => __( 'Media No Preview', 'your-textdomain-here' ),
    118 						'desc'     => __( 'This represents the minimalistic view. It does not have the preview box or the display URL in an input box. ', 'your-textdomain-here' ),
    119 						'subtitle' => __( 'Upload any media using the WordPress native uploader', 'your-textdomain-here' ),
    120 					),
    121 					array(
    122 						'id'       => 'gallery',
    123 						'type'     => 'gallery',
    124 						'title'    => __( 'Add/Edit Gallery', 'your-textdomain-here' ),
    125 						'subtitle' => __( 'Create a new Gallery by selecting existing or uploading new images using the WordPress native uploader', 'your-textdomain-here' ),
    126 						'desc'     => __( 'This is the description field, again good for additional info.', 'your-textdomain-here' ),
    127 					),
    128 					array(
    129 						'id'      => 'slider1bDOVY23',
    130 						'type'    => 'slider',
    131 						'title'   => __( 'JQuery UI Slider Example 1', 'your-textdomain-here' ),
    132 						'desc'    => __( 'JQuery UI slider description. Min: 1, max: 500, step: 3, default value: 45', 'your-textdomain-here' ),
    133 						'default' => '46',
    134 						'min'     => '1',
    135 						'step'    => '3',
    136 						'max'     => '500',
    137 					),
    138 					array(
    139 						'id'      => 'slider2bc',
    140 						'type'    => 'slider',
    141 						'title'   => __( 'JQuery UI Slider Example 2 w/ Steps (5)', 'your-textdomain-here' ),
    142 						'desc'    => __( 'JQuery UI slider description. Min: 0, max: 300, step: 5, default value: 75', 'your-textdomain-here' ),
    143 						'default' => '0',
    144 						'min'     => '0',
    145 						'step'    => '5',
    146 						'max'     => '300',
    147 					),
    148 					array(
    149 						'id'      => 'spinner1bcd',
    150 						'type'    => 'spinner',
    151 						'title'   => __( 'JQuery UI Spinner Example 1', 'your-textdomain-here' ),
    152 						'desc'    => __( 'JQuery UI spinner description. Min:20, max: 100, step:20, default value: 40', 'your-textdomain-here' ),
    153 						'default' => '40',
    154 						'min'     => '20',
    155 						'step'    => '20',
    156 						'max'     => '100',
    157 					),
    158 					array(
    159 						'id'       => 'switch-parent',
    160 						'type'     => 'switch',
    161 						'title'    => __( 'Switch - Nested Children, Enable to show', 'your-textdomain-here' ),
    162 						'subtitle' => __( 'Look, it\'s on! Also hidden child elements!', 'your-textdomain-here' ),
    163 						'default'  => 0,
    164 						'on'       => 'Enabled',
    165 						'off'      => 'Disabled',
    166 					),
    167 					array(
    168 						'id'       => 'switch-child1',
    169 						'type'     => 'switch',
    170 						'required' => array( 'switch-parent', '=', '1' ),
    171 						'title'    => __( 'Switch - This and the next switch required for patterns to show', 'your-textdomain-here' ),
    172 						'subtitle' => __( 'Also called a "fold" parent.', 'your-textdomain-here' ),
    173 						'desc'     => __( 'Items set with a fold to this ID will hide unless this is set to the appropriate value.', 'your-textdomain-here' ),
    174 						'default'  => false,
    175 					),
    176 				),
    177 			),
    178 
    179 			array(
    180 				'title'  => __( 'Home Layout', 'your-textdomain-here' ),
    181 				'desc'   => __( 'Redux Framework was created with the developer in mind. It allows for any theme developer to have an advanced theme panel with most of the features a developer would need. For more information check out the Github repo at: <a href="https://github.com/ReduxFramework/Redux-Framework">https://github.com/ReduxFramework/Redux-Framework</a>', 'your-textdomain-here' ),
    182 				'icon'   => 'el-icon-home',
    183 				'fields' => array(
    184 					array(
    185 						'id'             => 'homepage_blocks',
    186 						'type'           => 'sorter',
    187 						'title'          => 'Homepage Layout Manager',
    188 						'desc'           => 'Organize how you want the layout to appear on the homepage',
    189 						'compiler'       => 'true',
    190 						'add_visibility' => true,
    191 
    192 						'options'        => array(
    193 							'enabled'  => array(
    194 								'placebo'    => 'placebo', // REQUIRED!
    195 								'highlights' => 'Highlights',
    196 								'slider'     => 'Slider',
    197 								'staticpage' => 'Static Page',
    198 								'services'   => 'Services',
    199 							),
    200 							'disabled' => array(
    201 								'placebo' => 'placebo', // REQUIRED!
    202 							),
    203 						),
    204 					),
    205 
    206 					array(
    207 						'id'       => 'presets',
    208 						'type'     => 'image_select',
    209 						'presets'  => true,
    210 						'title'    => __( 'Preset', 'your-textdomain-here' ),
    211 						'subtitle' => __( 'This allows you to set a json string or array to override multiple preferences in your theme.', 'your-textdomain-here' ),
    212 						'default'  => 0,
    213 						'desc'     => __( 'This allows you to set a json string or array to override multiple preferences in your theme.', 'your-textdomain-here' ),
    214 						'options'  => array(
    215 							'1' => array(
    216 								'alt'     => 'Preset 1',
    217 								'img'     => ReduxFramework::$_url . '../sample/presets/preset1.png',
    218 								'presets' => array(
    219 									'switch-on'     => 1,
    220 									'switch-off'    => 1,
    221 									'switch-custom' => 1,
    222 								),
    223 							),
    224 							'2' => array(
    225 								'alt'     => 'Preset 2',
    226 								'img'     => ReduxFramework::$_url . '../sample/presets/preset2.png',
    227 								'presets' => '{"slider1":"1", "slider2":"0", "switch-on":"0"}',
    228 							),
    229 						),
    230 					),
    231 				),
    232 			),
    233 		),
    234 	)
    235 );