you put a ,
instead of ;
at end of $advert_details
. you will better see this kind of error if you better indent the code.
add_action('wp_enqueue_scripts', 'theme_enqueue_styles', 12);
function theme_enqueue_styles() {
wp_enqueue_style('parent-style', get_template_directory_uri() . '/style.css');
}
if (!function_exists('adifier_custom_meta')) {
function adifier_custom_meta() {
$meta_boxes = array();
$advert_details = array(
array(
'id' => 'advert_cond',
'name' => esc_html__( 'Condition', 'adifier' ),
'type' => 'select',
'options' => array(
'0' => esc_html__( '-Select-', 'adifier' ),
'1' => esc_html__( 'New with tags', 'adifier' ),
'2' => esc_html__( 'Manufacturer Refurbished', 'adifier' ),
'3' => esc_html__( 'Used with tags', 'adifier' ),
'4' => esc_html__( 'For Parts Or Not Working', 'adifier' ),
),
'values_callback' => 'adifier_get_advert_meta',
'save_callback' => 'adifier_save_advert_meta',
),
);
return $meta_boxes;
}
add_filter('cmb_meta_boxes', 'adifier_custom_meta');
}
you can also try a editor with syntax analyse like Eclipse PHP :
https://www.eclipse.org/pdt/