1
2
3
4
5
6
7
8
9
10
11
12
13
14
add_action('admin_enqueue_scripts', function() {
	wp_register_script('jqeury-validate', 'http://ajax.aspnetcdn.com/ajax/jquery.validate/1.8.1/jquery.validate.min.js');
	wp_register_script('ae-admin', get_bloginfo('template_directory') . '/js/admin.js', array('jquery', 'jquery-validate'));
	wp_localize_script('ae-admin', 'WpAjax', array(
			'AjaxUrl' => admin_url('admin-ajax.php')
	));
	wp_enqueue_script('jquery-validate');
	wp_enqueue_script('ae-admin');
});

add_action('admin_enqueue_styles', function() {
	wp_register_style('ae-validate', get_bloginfo('template_directory') . '/css/validate.css');
	wp_enqueue_style('ae-validate');
});