__( 'Main Menu', 'alpha-store' ), 'top_menu' => __( 'Top Menu', 'alpha-store' ), ) ); add_theme_support( 'post-thumbnails' ); set_post_thumbnail_size(300,300, true); add_image_size( 'alpha-store-single', 688, 325, true ); add_image_size( 'alpha-store-carousel', 270, 423, true ); add_image_size( 'alpha-store-category', 600, 600, true ); add_image_size( 'alpha-store-widget', 60, 60, true ); add_theme_support( 'automatic-feed-links' ); add_theme_support( 'woocommerce' ); // Display a admin notices add_action('admin_notices', 'alpha_store_admin_notice'); function alpha_store_admin_notice() { global $current_user; $user_id = $current_user->ID; /* Check that the user hasn't already clicked to ignore the message */ if ( ! get_user_meta($user_id, 'alpha_store_ignore_notice') ) { echo '
'; printf(__('Like Alpha Store theme? You will LOVE Alpha Store PRO! ','alpha-store').''.__('Click here for all the exciting features.','alpha-store').'', '?alpha_store_notice_ignore=0'); echo "
';
echo '';
}
}
endif;
////////////////////////////////////////////////////////////////////
// Enqueue Styles (normal style.css and bootstrap.css)
////////////////////////////////////////////////////////////////////
function alpha_store_theme_stylesheets()
{
wp_enqueue_style('alpha-store-bootstrap-css', get_template_directory_uri() . '/css/bootstrap.css', array(), '1', 'all' );
wp_enqueue_style( 'alpha-store-stylesheet', get_stylesheet_uri(), array(), '1', 'all' );
// load Font Awesome css
wp_enqueue_style( 'alpha-store-font-awesome', get_template_directory_uri() . '/css/font-awesome.min.css', false );
wp_enqueue_style( 'alpha-store-flexslider-css', get_template_directory_uri() . '/css/flexslider.css', false );
}
add_action('wp_enqueue_scripts', 'alpha_store_theme_stylesheets');
////////////////////////////////////////////////////////////////////
// Register Bootstrap JS with jquery
////////////////////////////////////////////////////////////////////
function alpha_store_theme_js()
{
wp_enqueue_script('alpha-store-bootstrap-js', get_template_directory_uri() . '/js/bootstrap.js',array( 'jquery' ),true );
wp_enqueue_script('alpha-store-theme-js', get_template_directory_uri() . '/js/customscript.js',array( 'jquery' ),true );
wp_enqueue_script('alpha-store-flexslider', get_template_directory_uri() . '/js/jquery.flexslider-min.js', array('woocommerce'));
}
add_action('wp_enqueue_scripts', 'alpha_store_theme_js');
////////////////////////////////////////////////////////////////////
// Register Custom Navigation Walker include custom menu widget to use walkerclass
////////////////////////////////////////////////////////////////////
require_once('lib/wp_bootstrap_navwalker.php');
////////////////////////////////////////////////////////////////////
// Register Widgets
////////////////////////////////////////////////////////////////////
add_action( 'widgets_init', 'alpha_store_widgets_init' );
function alpha_store_widgets_init() {
register_sidebar(
array(
'name' => __( 'Homepage Sidebar', 'alpha-store' ),
'id' => 'alpha-store-home-sidebar',
'before_widget' => '',
'before_title' => '