field_select( $option, $post_id ); elseif( isset($option['type']) && $option['type'] === 'select_multi') $this->field_select_multi( $option, $post_id ); elseif( isset($option['type']) && $option['type'] === 'select2') $this->field_select2( $option, $post_id ); elseif( isset($option['type']) && $option['type'] === 'checkbox') $this->field_checkbox( $option, $post_id ); elseif( isset($option['type']) && $option['type'] === 'radio') $this->field_radio( $option, $post_id ); elseif( isset($option['type']) && $option['type'] === 'radio_image') $this->field_radio_image( $option, $post_id ); elseif( isset($option['type']) && $option['type'] === 'textarea') $this->field_textarea( $option, $post_id ); elseif( isset($option['type']) && $option['type'] === 'scripts_js') $this->field_scripts_js( $option, $post_id ); elseif( isset($option['type']) && $option['type'] === 'scripts_css') $this->field_scripts_css( $option, $post_id ); elseif( isset($option['type']) && $option['type'] === 'number' ) $this->field_number( $option, $post_id ); elseif( isset($option['type']) && $option['type'] === 'text' ) $this->field_text( $option, $post_id ); elseif( isset($option['type']) && $option['type'] === 'text_icon' ) $this->field_text_icon( $option, $post_id ); elseif( isset($option['type']) && $option['type'] === 'text_multi' ) $this->field_text_multi( $option, $post_id ); elseif( isset($option['type']) && $option['type'] === 'range' ) $this->field_range( $option, $post_id ); elseif( isset($option['type']) && $option['type'] === 'colorpicker') $this->field_colorpicker( $option, $post_id ); elseif( isset($option['type']) && $option['type'] === 'datepicker') $this->field_datepicker( $option, $post_id ); elseif( isset($option['type']) && $option['type'] === 'repeater') $this->field_repeater( $option, $post_id ); elseif( isset($option['type']) && $option['type'] === 'faq') $this->field_faq( $option, $post_id ); elseif( isset($option['type']) && $option['type'] === 'addons_grid') $this->field_addons_grid( $option, $post_id ); elseif( isset($option['type']) && $option['type'] === 'custom_html') $this->field_custom_html( $option, $post_id ); elseif( isset($option['type']) && $option['type'] === $type ) do_action( "settings_tabs_field_$type", $option, $post_id ); //if( !empty( $details ) ) echo "

$details

"; } public function field_select( $option, $post_id ){ $id = isset( $option['id'] ) ? $option['id'] : ""; $args = isset( $option['args'] ) ? $option['args'] : array(); $placeholder = isset( $option['placeholder'] ) ? $option['placeholder'] : ""; $value = get_post_meta( $post_id, $id, true ); //var_dump($value); $title = isset( $option['title'] ) ? $option['title'] : ""; $details = isset( $option['details'] ) ? $option['details'] : ""; ?>

generate_args_from_string( $args ); $option_value = get_post_meta( $post_id, $id, true ); foreach( $args as $key => $value ): $checked = is_array( $option_value ) && in_array( $key, $option_value ) ? "checked" : ""; ?>
generate_args_from_string( $args ); $option_value = get_post_meta( $post_id, $id, true ); $default_value = isset( $option['default_value'] ) ? $option['default_value'] : ""; $title = isset( $option['title'] ) ? $option['title'] : ""; $details = isset( $option['details'] ) ? $option['details'] : ""; //var_dump($option_value); $option_value = empty($option_value) ? $default_value : $option_value; ?>
$value ): $name = $value['name']; $thumb = $value['thumb']; $checked = ($key == $option_value) ? "checked" : ""; //var_dump($checked); ?>

"; echo ""; } public function field_custom_html( $option, $post_id ){ $id = isset( $option['id'] ) ? $option['id'] : ""; $html = isset( $option['html'] ) ? $option['html'] : ""; $title = isset( $option['title'] ) ? $option['title'] : ""; $details = isset( $option['details'] ) ? $option['details'] : ""; ?>