__( 'Primary Menu', 'bizwide' ), 'footer' => __( 'Footer Menu', 'bizwide' ), ) ); add_theme_support( 'custom-background', array( 'default-color' => 'ffffff' ) ); add_editor_style( 'editor-style.css' ); } endif; // bizwide_setup add_action( 'after_setup_theme', 'bizwide_setup' ); // Set the word limit of post content function bizwide_content($limit) { $content = explode(' ', get_the_content(), $limit); if (count($content)>=$limit) { array_pop($content); $content = implode(" ",$content).'...'; } else { $content = implode(" ",$content); } $content = preg_replace('/\[.+\]/','', $content); $content = apply_filters('the_content', $content); $content = str_replace(']]>', ']]>', $content); return $content; } function bizwide_font_url(){ $font_url = ''; /* Translators: If there are any character that are not * supported by raleway, trsnalate this to off, do not * translate into your own language. */ $raleway = _x('on','raleway:on or off','bizwide'); /* Translators: If there has any character that are not supported * by Scada, translate this to off, do not translate * into your own language. */ $scada = _x('on','Scada:on or off','bizwide'); if('off' !== $raleway ){ $font_family = array(); if('off' !== $raleway){ $font_family[] = 'raleway:300,400,600,700,800,900'; } $query_args = array( 'family' => urlencode(implode('|',$font_family)), ); $font_url = add_query_arg($query_args,'//fonts.googleapis.com/css'); } return $font_url; } function bizwide_scripts() { wp_enqueue_style('bizwide-font', bizwide_font_url(), array()); wp_enqueue_style( 'bizwide-basic-style', get_stylesheet_uri() ); wp_enqueue_style( 'bizwide-editor-style', get_template_directory_uri()."/editor-style.css" ); wp_enqueue_style( 'bizwide-nivoslider-style', get_template_directory_uri()."/css/nivo-slider.css" ); wp_enqueue_style( 'bizwide-main-style', get_template_directory_uri()."/css/responsive.css" ); wp_enqueue_style( 'bizwide-base-style', get_template_directory_uri()."/css/default.css" ); wp_enqueue_script( 'bizwide-nivo-script', get_template_directory_uri() . '/js/jquery.nivo.slider.js', array('jquery') ); wp_enqueue_script( 'bizwide-custom_js', get_template_directory_uri() . '/js/custom.js' ); wp_enqueue_style( 'bizwide-animation-style', get_template_directory_uri()."/css/animation.css" ); wp_enqueue_style( 'bizwide-font-awesome-style', get_template_directory_uri()."/css/font-awesome.css" ); if ( is_singular() && comments_open() && get_option( 'thread_comments' ) ) { wp_enqueue_script( 'comment-reply' ); } } add_action( 'wp_enqueue_scripts', 'bizwide_scripts' ); function bizwide_ie_stylesheet(){ global $wp_styles; /** Load our IE-only stylesheet for all versions of IE. * * * Note: It is also possible to just check and see if the $is_IE global in WordPress is set to true before * calling the wp_enqueue_style() function. If you are trying to load a stylesheet for all browsers * EXCEPT for IE, then you would HAVE to check the $is_IE global since WordPress doesn't have a way to * properly handle non-IE conditional comments. */ wp_enqueue_style('bizwide-ie', get_template_directory_uri().'/css/ie.css', array('bizwide-style')); $wp_styles->add_data('bizwide-ie','conditional','IE'); } add_action('wp_enqueue_scripts','bizwide_ie_stylesheet');