-1, 'post_parent' => get_the_ID(), 'post_type' => 'attachment', 'post_mime_type' => 'image', 'order' => 'ASC', 'exclude' => $exclude_thumbnail ? array(get_post_thumbnail_id()) : array(), 'orderby' => 'menu_order ID' ))); } //ADD FULL WIDTH BODY CLASS add_filter( 'body_class', 'isis_fullwdth_body_class'); function isis_fullwdth_body_class( $classes ) { if(of_get_option('nosidebar_checkbox') == "1") $classes[] = 'isis_fullwdth_body'; return $classes; } //Custom Excerpt Length function isis_excerptlength_teaser($length) { return 30; } function isis_excerptlength_index($length) { return 12; } function isis_excerptmore($more) { return '...'; } function isis_excerpt($length_callback='', $more_callback='') { global $post; if(function_exists($length_callback)){ add_filter('excerpt_length', $length_callback); } if(function_exists($more_callback)){ add_filter('excerpt_more', $more_callback); } $output = get_the_excerpt(); $output = apply_filters('wptexturize', $output); $output = apply_filters('convert_chars', $output); $output = '

'.$output.'

'; echo $output; } /*-----------------------------------------------------------------------------------*/ /* Display tag /*-----------------------------------------------------------------------------------*/ // filter function for wp_title function isis_filter_wp_title( $old_title, $sep, $sep_location ){ // add padding to the sep $ssep = ' ' . $sep . ' '; // find the type of index page this is if( is_category() ) $insert = $ssep . __('Category','isis'); elseif( is_tag() ) $insert = $ssep . __('Tag','isis'); elseif( is_author() ) $insert = $ssep . __('Author','isis'); elseif( is_year() || is_month() || is_day() ) $insert = $ssep . __('Archives','isis'); elseif( is_home() ) $insert = $ssep . get_bloginfo('description'); else $insert = NULL; // get the page number we're on (index) if( get_query_var( 'paged' ) ) $num = $ssep . __('Page ','isis') . get_query_var( 'paged' ); // get the page number we're on (multipage post) elseif( get_query_var( 'page' ) ) $num = $ssep . __('Page ','isis') . get_query_var( 'page' ); // else else $num = NULL; // concoct and return new title return get_bloginfo( 'name' ) . $insert . $old_title . $num; } add_filter( 'wp_title', 'isis_filter_wp_title', 10, 3 ); function isis_rss_title($title) { /* need to fix our add a | blog name to wp_title */ $ft = str_replace(' | ','',$title); return str_replace(get_bloginfo('name'),'',$ft); } add_filter('get_wp_title_rss', 'isis_rss_title',10,1); /** * Add default options and show Options Panel after activate */ if (is_admin() && isset($_GET['activated'] ) && $pagenow == "themes.php" ) { //Do redirect wp_redirect( admin_url( 'admin.php?page=options-framework' ) ); exit; } //SIDEBAR function isis_widgets_init(){ register_sidebar(array( 'name' => __('Right Sidebar', 'isis'), 'id' => 'sidebar', 'description' => __('Right Sidebar', 'isis'), 'before_widget' => '<div id="%1$s" class="widget %2$s"><div class="widget_wrap">', 'after_widget' => '</div></div>', 'before_title' => '<h3 class="widgettitle">', 'after_title' => '</h3>' )); register_sidebar(array( 'name' => __('Footer Widgets', 'isis'), 'id' => 'foot_sidebar', 'description' => __('Widget Area for the Footer', 'isis'), 'before_widget' => '<div id="%1$s" class="widget %2$s"><div class="widget_wrap">', 'after_widget' => '</div></div>', 'before_title' => '<h3 class="widgettitle">', 'after_title' => '</h3>' )); } add_action( 'widgets_init', 'isis_widgets_init' ); //**************isis SETUP******************// function isis_setup() { //Custom Background add_theme_support( 'custom-background', array( 'default-color' => '', 'default-image' => get_template_directory_uri() . '' ) ); add_theme_support('automatic-feed-links'); //Post Thumbnail add_theme_support( 'post-thumbnails' ); //Register Menus register_nav_menus( array( 'primary' => __( 'Primary Navigation(Header)', 'isis' ), ) ); // Enables post and comment RSS feed links to head add_theme_support('automatic-feed-links'); // Localisation Support load_theme_textdomain('isis', get_template_directory() . '/languages'); $locale = get_locale(); $locale_file = get_template_directory() . "/languages/$locale.php"; if ( is_readable( $locale_file ) ) require_once( $locale_file ); /* * Loads the Options Panel */ /* Set the file path based on whether we're in a child theme or parent theme */ if ( get_stylesheet_directory() == get_template_directory_uri() ) { define('OPTIONS_FRAMEWORK_URL', get_template_directory() . '/admin/'); define('OPTIONS_FRAMEWORK_DIRECTORY', get_template_directory_uri() . '/admin/'); } else { define('OPTIONS_FRAMEWORK_URL', get_stylesheet_directory() . '/admin/'); define('OPTIONS_FRAMEWORK_DIRECTORY', get_stylesheet_directory_uri() . '/admin/'); } require_once (OPTIONS_FRAMEWORK_URL . 'options-framework.php'); include(get_template_directory() . '/lib/widgets.php'); } add_action( 'after_setup_theme', 'isis_setup' ); ?> <?php