'Sidebar', 'before_title' => '
  • ', 'after_title' => '
  • ', )); // The Alert Widget // Location: displayed on the top of the home page, right after the header, right before the loop, within the contend area register_sidebar(array('name'=>'Alert', 'before_widget' => '
    ', 'before_title' => '

    ', 'after_title' => '

    ', )); // post thumbnail support add_theme_support( 'post-thumbnails' ); // custom menu support add_theme_support( 'menus' ); if ( function_exists( 'register_nav_menus' ) ) { register_nav_menus( array( 'header_menu' => 'Header Menu', ) ); } // custom background support add_custom_background(); // enable threaded comments function enable_threaded_comments(){ if (!is_admin()) { if (is_singular() AND comments_open() AND (get_option('thread_comments') == 1)) wp_enqueue_script('comment-reply'); } } add_action('get_header', 'enable_threaded_comments'); // removes detailed login error information for security add_filter('login_errors',create_function('$a', "return null;")); // Removes Trackbacks from the comment cout add_filter('get_comments_number', 'comment_count', 0); function comment_count( $count ) { if ( ! is_admin() ) { global $id; $comments_by_type = &separate_comments(get_comments('status=approve&post_id=' . $id)); return count($comments_by_type['comment']); } else { return $count; } } function new_excerpt_length($length) { return 12; } add_filter('excerpt_length', 'new_excerpt_length'); // custom excerpt ellipses for 2.9+ function custom_excerpt_more($more) { return 'Read More »'; } add_filter('excerpt_more', 'custom_excerpt_more'); // no more jumping for read more link function no_more_jumping($post) { return ''.'Continue Reading'.''; } add_filter('excerpt_more', 'no_more_jumping'); // category id in body and post class function category_id_class($classes) { global $post; foreach((get_the_category($post->ID)) as $category) $classes [] = 'cat-' . $category->cat_ID . '-id'; return $classes; } add_filter('post_class', 'category_id_class'); add_filter('body_class', 'category_id_class'); // Automatic Shortened URLs function getTrimUrl($url) { $tinyurl = file_get_contents("http://api.tr.im/api/trim_simple?url=".$url); return $tinyurl; } // A Function that output's the current page's URL // Used in the canonical link within the header but can be used elsewhere // output with: echo curPageURL(); function curPageURL() { $pageURL = 'http'; if ($_SERVER["HTTPS"] == "on") {$pageURL .= "s";} $pageURL .= "://"; if ($_SERVER["SERVER_PORT"] != "80") { $pageURL .= $_SERVER["SERVER_NAME"].":".$_SERVER["SERVER_PORT"].$_SERVER["REQUEST_URI"]; } else { $pageURL .= $_SERVER["SERVER_NAME"].$_SERVER["REQUEST_URI"]; } return $pageURL; } ?>