Current File : /pages/54/47/d0016649/home/htdocs/ipc1/wp-content/themes/lhst/includes/theme/theme.schemes.menu.php
<?php
$location = isset($args[1]) ? $args[1] : NULL;
$item = isset($args[0]) ? $args[0] : NULL;
if ( $item )
	$item_suffix = '_' . $item;
else
	$item_suffix = '';

$scheme = array();
switch ($location) {
	default:

			$scheme = array_merge( $scheme, array(
					array(
						'type'      =>  'group',
						'id'		=>	'',
						//'menu-condition' =>	'= 0',
						'data'		=>	array(

							array(
								'type'      =>  'module',
								'title'     =>  __('Visibility','envision'),
								'data'      =>  array(
									## Element
									array(
										'type'      =>  'select',
										'id'        =>  PFIX.'_visibility' . $item_suffix,
										'value'     =>  cloudfw_get_post_meta($item, 'visibility'),
										'default'	=> '',
										'source'	=>	array(
											'type'		=>	'function',
											'function'	=>	'cloudfw_admin_get_visibility_options'
										),
										'width'		=> 180
									), // #### element: 0

								)
							),

							array(
								'type'      =>  'module',
								'title'     =>  __('Sub Menu Direction','envision'),
								'data'      =>  array(
									## Element
									array(
										'type'      =>  'select',
										'id'        =>  PFIX.'_dropdown_direction' . $item_suffix,
										'value'     =>  cloudfw_get_post_meta($item, 'dropdown_direction'),
										'default'	=> '',
										'source'	=>	array(
											'NULL'		=>	__('Default','envision'),
											'left'		=>	__('To Left','envision'),
											'right'		=>	__('To Right','envision'),
										),
										'width'		=> 180
									), // #### element: 0

								)
							),

							array(
								'type'      =>  'module',
								'title'     =>  __('Sub Menu Direction in Sticy Mode','envision'),
								'data'      =>  array(
									## Element
									array(
										'type'      =>  'select',
										'id'        =>  PFIX.'_dropdown_direction_sticky' . $item_suffix,
										'value'     =>  cloudfw_get_post_meta($item, 'dropdown_direction_sticky'),
										'default'	=> '',
										'source'	=>	array(
											'NULL'		=>	__('Default','envision'),
											'left'		=>	__('To Left','envision'),
											'right'		=>	__('To Right','envision'),
										),
										'width'		=> 180
									), // #### element: 0

								)
							),

						)
					),

					array(
						'type'      =>  'group',
						'id'		=>	'',
						'menu-condition' =>	'= 0',
						'data'		=>	array(

							array(
								'type'      =>  'module',
								'title'     =>  __('Enable Mega Menu','envision'),
								'data'      =>  array(
									## Element
									array(
										'type'      =>  'onoff',
										'id'        =>  PFIX.'_megamenu' . $item_suffix,
										'value'     =>  cloudfw_get_post_meta($item, 'megamenu'),
										'default'	=>	'FALSE',
									), // #### element: 0

								)
							),

							array(
								'type'      =>  'module',
								'title'     =>  __('Mega Menu Columns','envision'),
								'data'      =>  array(
									## Element
									array(
										'type'      =>  'slider',
										'id'        =>  PFIX.'_megamenu_columns' . $item_suffix,
										'value'     =>  cloudfw_get_post_meta($item, 'megamenu_columns'),
										'default'	=>	3,
										'max'		=>	6,
										'min'		=>	1,
										'unit'		=>	__('column(s)','envision'),
										'class' 	=> 'input input_100',
										'width'		=>	'150',
									), // #### element: 0

								)
							),

							array(
								'type'      =>  'module',
								'title'     =>  __('Mega Menu Layout','envision'),
								'data'      =>  array(
									## Element
									array(
										'type'      =>  'select',
										'id'        =>  PFIX.'_megamenu_layout' . $item_suffix,
										'value'     =>  cloudfw_get_post_meta($item, 'megamenu_layout'),
										'default'	=> '',
										'source'	=>	array(
											'NULL'			=>	__('Specific Width','envision'),
											'fullwidth'		=>	__('Fullwidth','envision'),
										),
										'width'		=> 180
									), // #### element: 0

								)
							),


							array(
								'type'      =>  'module',
								'title'     =>  __('Mega Menu Width','envision'),
								'data'      =>  array(
									## Element
									array(
										'type'      =>  'slider',
										'id'        =>  PFIX.'_megamenu_width' . $item_suffix,
										'value'     =>  cloudfw_get_post_meta($item, 'megamenu_width'),
										'default'	=>	'-1',
										'max'		=>	960,
										'min'		=>	-1,
										'steps'		=>	array( '-1' => __('default','envision') ),
										'class' 	=> 'input input_100',
										'width'		=>	'150',
										'desc'		=>	__('This option is for the "Specific Width" layout','envision')
									), // #### element: 0

								)
							),

						)

					),

					array(
						'type'      =>  'group',
						'menu-condition' =>	'> 0',
						'data'		=>	array(

							array(
								'type'      =>  'module',
								'title'     =>  __('Link Text Align','envision'),
								'data'      =>  array(
									## Element
									array(
										'type'      =>  'select',
										'id'        =>  PFIX.'_dropdown_text_align' . $item_suffix,
										'value'     =>  cloudfw_get_post_meta($item, 'dropdown_text_align'),
										'default'	=> '',
										'source'	=>	array(
											'NULL'		=>	__('Default','envision'),
											'left'		=>	__('Left','envision'),
											'center'	=>	__('Center','envision'),
											'right'		=>	__('Right','envision'),
										),
										'width'		=> 180
									), // #### element: 0

								)
							),

							array(
								'type'      =>  'module',
								'title'     =>  __('Mega Menu Item Style','envision'),
								'data'      =>  array(
									## Element
									array(
										'type'      =>  'select',
										'id'        =>  PFIX.'_megamenu_style' . $item_suffix,
										'value'     =>  cloudfw_get_post_meta($item, 'megamenu_style'),
										'default'	=> '',
										'source'	=>	array(
											'NULL'			=>	__('Default','envision'),
											'standard'		=>	__('Standard Style','envision'),
											'big-title'		=>	__('Big Title Style','envision'),
											'strong-title'	=>	__('Strong Title Style','envision'),
											'list'			=>	__('List Style','envision'),
										),
										'width'		=> 180
									), // #### element: 0
								)
							),

							array(
								'type'      =>  'module',
								'title'     =>  __('Mega Menu Image','envision'),
								'data'      =>  array(
									## Element
									array(
										'type'      =>  'upload',
										'id'        =>  PFIX.'_megamenu_image' . $item_suffix,
										'value'     =>  cloudfw_get_post_meta($item, 'megamenu_image', ''),
										'store'		=>	true,
										'library'	=>	true,
										'removable'	=>	true,
										'hide_input'=>	true,
									), // #### element: 0

								)
							),

							array(
								'type'      =>  'module',
								'title'     =>  __('Mega Menu HTML Code','envision'),
								'data'      =>  array(
									## Element
									array(
										'type'      =>  'textarea',
										'id'        =>  PFIX.'_megamenu_html' . $item_suffix,
										'value'     =>  cloudfw_get_post_meta($item, 'megamenu_html', ''),
										'width'		=>	230,
										'line'		=>	3
									), // #### element: 0

								)
							),

							array(
								'type'      =>  'module',
								'title'     =>  __('Mega Menu Custom Text Color','envision'),
								'data'      =>  array(
									## Element
									array(
										'type'      =>  'color',
										'style'     =>  'mini',
										'id'        =>  PFIX.'_megamenu_text_color' . $item_suffix,
										'value'     =>  cloudfw_get_post_meta($item, 'megamenu_text_color', ''),
									), // #### element: 0

								)
							),

							array(
								'type'      =>  'module',
								'title'     =>  __('Hide Title','envision'),
								'data'      =>  array(
									## Element
									array(
										'type'      =>  'onoff',
										'id'        =>  PFIX.'_megamenu_hide_title' . $item_suffix,
										'value'     =>  cloudfw_get_post_meta($item, 'megamenu_hide_title', 'FALSE'),
									), // #### element: 0

								)
							),

						)
					),

					/*array(
						'type'      =>  'group',
						'menu-condition' =>	'= 1',
						'data'		=>	array(

							array(
								'type'      =>  'module',
								'title'     =>  __('Divider','cloudfw'),
								'data'      =>  array(
									## Element
									array(
										'type'      =>  'onoff',
										'id'        =>  PFIX.'_megamenu_divider' . $item_suffix,
										'value'     =>  cloudfw_get_post_meta($item, 'megamenu_divider', 'FALSE'),
									), // #### element: 0

								)
							),

						)
					),*/

					array(
						'type'      =>  'group',
						//'menu-condition' =>	'> 0',
						'data'		=>	array(

							array(
								'type'      =>  'module',
								'title'     =>  __('Disable Link','envision'),
								'data'      =>  array(
									## Element
									array(
										'type'      =>  'onoff',
										'id'        =>  PFIX.'_disable_link' . $item_suffix,
										'value'     =>  cloudfw_get_post_meta($item, 'disable_link', 'FALSE'),
									), // #### element: 0

								)
							),

						)
					),

					array(
						'type'      =>  'module',
						'title'     =>  __('Inline Style Code For Item','envision'),
						'data'      =>  array(
							## Element
							array(
								'type'      =>  'text',
								'id'        =>  PFIX.'_megamenu_inline_style' . $item_suffix,
								'value'     =>  cloudfw_get_post_meta($item, 'megamenu_inline_style', ''),
								'width'		=>	230,
							), // #### element: 0

						)
					),

					array(
						'type'      =>  'module',
						'title'     =>  __('Inline Style Code For Link','envision'),
						'data'      =>  array(
							## Element
							array(
								'type'      =>  'text',
								'id'        =>  PFIX.'_megamenu_inline_style_link' . $item_suffix,
								'value'     =>  cloudfw_get_post_meta($item, 'megamenu_inline_style_link', ''),
								'width'		=>	230,
							), // #### element: 0

						)
					),

					array(
						'type'      =>  'group',
						'id'		=>	'',
						//'menu-condition' =>	'= 0',
						'data'		=>	array(

							array(
								'type'      =>  'module',
								'title'     =>  __('Logical Condition(Login)','envision'),
								'data'      =>  array(

									## Element
									array(
										'type'      =>  'select',
										'id'        =>  PFIX.'_menu_logical_condition_result' . $item_suffix,
										'value'     =>  cloudfw_get_post_meta($item, 'menu_logical_condition_result'),
										'default'	=> '',
										'source'	=>	array(
											'NULL'		=>	'',
											'show'		=>	__('Show','envision'),
											'hide'		=>	__('Hide','envision'),
										),
										'width'		=> 180
									), // #### element: 0

									## Element
									array(
										'type'      =>  'select',
										'id'        =>  PFIX.'_menu_logical_condition' . $item_suffix,
										'value'     =>  cloudfw_get_post_meta($item, 'menu_logical_condition'),
										'default'	=> '',
										'source'	=>	array(
											'NULL'		=>	'',
											'is_logged_in'		=>	__('If user logged in','envision'),
											'is_not_logged_in'	=>	__('If user not logged in','envision'),
										),
										'width'		=> 180
									), // #### element: 0

								)
							),

						)

					),

					array(
						'type'      =>  'group',
						'id'		=>	'',
						//'menu-condition' =>	'= 0',
						'data'		=>	array(

							array(
								'type'      =>  'module',
								'title'     =>  __('Logical Condition(User Capabilities)','envision'),
								'data'      =>  array(

									## Element
									array(
										'type'      =>  'select',
										'id'        =>  PFIX.'_menu_logical_condition_roles_result' . $item_suffix,
										'value'     =>  cloudfw_get_post_meta($item, 'menu_logical_condition_roles_result'),
										'default'	=> '',
										'source'	=>	array(
											'NULL'		=>	'',
											'show'		=>	__('Show','envision'),
											'hide'		=>	__('Hide','envision'),
										),
										'width'		=> 180
									), // #### element: 0

									## Element
									array(
										'type'      =>  'text',
										'id'        =>  PFIX.'_menu_logical_condition_roles' . $item_suffix,
										'value'     =>  cloudfw_get_post_meta($item, 'menu_logical_condition_roles'),
										'default'	=> '',
										'holder'    => __('User Role','envision'),
										'width'		=> 180,
										'desc'      =>  __('Split by comma for multiple','envision'),
									), // #### element: 0

								)
							),

						)

					),

				)

			);

		break;


	case 'topbar':

			$scheme = array_merge( $scheme, array(
					array(
						'type'      =>  'group',
						'id'		=>	'',
						//'menu-condition' =>	'= 0',
						'data'		=>	array(

							array(
								'type'      =>  'module',
								'title'     =>  __('Visibility','envision'),
								'data'      =>  array(
									## Element
									array(
										'type'      =>  'select',
										'id'        =>  PFIX.'_visibility' . $item_suffix,
										'value'     =>  cloudfw_get_post_meta($item, 'visibility'),
										'default'	=> '',
										'source'	=>	array(
											'type'		=>	'function',
											'function'	=>	'cloudfw_admin_get_visibility_options'
										),
										'width'		=> 180
									), // #### element: 0

								)
							),
						)
					),

					array(
						'type'      =>  'module',
						'title'     =>  __('Sub Menu Direction','envision'),
						'data'      =>  array(
							## Element
							array(
								'type'      =>  'select',
								'id'        =>  PFIX.'_dropdown_direction' . $item_suffix,
								'value'     =>  cloudfw_get_post_meta($item, 'dropdown_direction'),
								'default'	=> '',
								'source'	=>	array(
									'NULL'		=>	__('Default','envision'),
									'left'		=>	__('To Left','envision'),
									'right'		=>	__('To Right','envision'),
								),
								'width'		=> 180
							), // #### element: 0

						)
					),

					array(
						'type'      =>  'group',
						'id'		=>	'',
						//'menu-condition' =>	'= 0',
						'data'		=>	array(

							array(
								'type'      =>  'module',
								'title'     =>  __('Logical Condition(Login)','envision'),
								'data'      =>  array(

									## Element
									array(
										'type'      =>  'select',
										'id'        =>  PFIX.'_menu_logical_condition_result' . $item_suffix,
										'value'     =>  cloudfw_get_post_meta($item, 'menu_logical_condition_result'),
										'default'	=> '',
										'source'	=>	array(
											'NULL'		=>	'',
											'show'		=>	__('Show','envision'),
											'hide'		=>	__('Hide','envision'),
										),
										'width'		=> 180
									), // #### element: 0

									## Element
									array(
										'type'      =>  'select',
										'id'        =>  PFIX.'_menu_logical_condition' . $item_suffix,
										'value'     =>  cloudfw_get_post_meta($item, 'menu_logical_condition'),
										'default'	=> '',
										'source'	=>	array(
											'NULL'		=>	'',
											'is_logged_in'		=>	__('If user logged in','envision'),
											'is_not_logged_in'	=>	__('If user not logged in','envision'),
										),
										'width'		=> 180
									), // #### element: 0

								)
							),

						)

					),

					array(
						'type'      =>  'group',
						'id'		=>	'',
						//'menu-condition' =>	'= 0',
						'data'		=>	array(

							array(
								'type'      =>  'module',
								'title'     =>  __('Logical Condition(User Roles)','envision'),
								'data'      =>  array(

									## Element
									array(
										'type'      =>  'select',
										'id'        =>  PFIX.'_menu_logical_condition_roles_result' . $item_suffix,
										'value'     =>  cloudfw_get_post_meta($item, 'menu_logical_condition_roles_result'),
										'default'	=> '',
										'source'	=>	array(
											'NULL'		=>	'',
											'show'		=>	__('Show','envision'),
											'hide'		=>	__('Hide','envision'),
										),
										'width'		=> 180
									), // #### element: 0

									## Element
									array(
										'type'      =>  'text',
										'id'        =>  PFIX.'_menu_logical_condition_roles' . $item_suffix,
										'value'     =>  cloudfw_get_post_meta($item, 'menu_logical_condition_roles'),
										'default'	=> '',
										'holder'    => __('User Role','envision'),
										'width'		=> 180
									), // #### element: 0

								)
							),

						)

					),

				)

			);

		break;

}