<?php
function drk_add_market_date_meta_boxes(){
	add_meta_box(
		"post_metadata_market_date_id",
		"Market sience",
		"drk_meta_box_market_date",
        array("markets","venders",'tlg_channels','other_services','top_forums'),
		"normal",
		'default'
	);
}

add_action('add_meta_boxes', "drk_add_market_date_meta_boxes");

function drk_meta_box_market_date() {
	global $post;
	$market_date = get_post_meta($post->ID, '_market_date',true);
	?>
	    <input name="_market_date" type="date" value="<?php echo $market_date?>"/> 
<?php
}

function drk_save_market_date_meta_boxes(){
	global $post;
	if(defined('DOING_AUTOSAVE') && DOING_AUTOSAVE){
		return;
	}
	update_post_meta($post->ID,"_market_date", $_POST["_market_date"]);
	
}

add_action("save_post", "drk_save_market_date_meta_boxes");