diff --git a/functions.php b/functions.php index 2833356..80e203f 100644 --- a/functions.php +++ b/functions.php @@ -24,10 +24,10 @@ include 'plugins/arl_kottke_archives.php'; if ( ! isset( $content_width ) ) $content_width = 640; -/** Tell WordPress to run twentyten_setup() when the 'after_setup_theme' hook is run. */ -add_action( 'after_setup_theme', 'twentyten_setup' ); +/** Tell WordPress to run melville_setup() when the 'after_setup_theme' hook is run. */ +add_action( 'after_setup_theme', 'melville_setup' ); -if ( ! function_exists( 'twentyten_setup' ) ): +if ( ! function_exists( 'melville_setup' ) ): /** * Sets up theme defaults and registers support for various WordPress features. * @@ -49,7 +49,7 @@ if ( ! function_exists( 'twentyten_setup' ) ): * * @since Twenty Ten 1.0 */ -function twentyten_setup() { +function melville_setup() { // This theme uses post thumbnails add_theme_support( 'post-thumbnails' ); @@ -77,11 +77,11 @@ endif; * * @since Twenty Ten 1.0 */ -function twentyten_page_menu_args( $args ) { +function melville_page_menu_args( $args ) { $args['show_home'] = true; return $args; } -add_filter( 'wp_page_menu_args', 'twentyten_page_menu_args' ); +add_filter( 'wp_page_menu_args', 'melville_page_menu_args' ); /** * Sets the post excerpt length to 40 characters. @@ -92,10 +92,10 @@ add_filter( 'wp_page_menu_args', 'twentyten_page_menu_args' ); * @since Twenty Ten 1.0 * @return int */ -function twentyten_excerpt_length( $length ) { +function melville_excerpt_length( $length ) { return 40; } -add_filter( 'excerpt_length', 'twentyten_excerpt_length' ); +add_filter( 'excerpt_length', 'melville_excerpt_length' ); /** * Returns a "Continue Reading" link for excerpts @@ -103,7 +103,7 @@ add_filter( 'excerpt_length', 'twentyten_excerpt_length' ); * @since Twenty Ten 1.0 * @return string "Continue Reading" link */ -function twentyten_continue_reading_link() { +function melville_continue_reading_link() { return ' ' . __( 'continue reading', 'twentyten' ) . ''; } @@ -116,10 +116,10 @@ function twentyten_continue_reading_link() { * @since Twenty Ten 1.0 * @return string An ellipsis */ -function twentyten_auto_excerpt_more( $more ) { - return '… ' . twentyten_continue_reading_link() . ' »'; +function melville_auto_excerpt_more( $more ) { + return '… ' . melville_continue_reading_link() . ' »'; } -add_filter( 'excerpt_more', 'twentyten_auto_excerpt_more' ); +add_filter( 'excerpt_more', 'melville_auto_excerpt_more' ); /** * Adds a pretty "Continue Reading" link to custom post excerpts. @@ -130,13 +130,13 @@ add_filter( 'excerpt_more', 'twentyten_auto_excerpt_more' ); * @since Twenty Ten 1.0 * @return string Excerpt with a pretty "Continue Reading" link */ -function twentyten_custom_excerpt_more( $output ) { +function melville_custom_excerpt_more( $output ) { if ( has_excerpt() && ! is_attachment() ) { - $output .= twentyten_continue_reading_link(); + $output .= melville_continue_reading_link(); } return $output; } -add_filter( 'get_the_excerpt', 'twentyten_custom_excerpt_more' ); +add_filter( 'get_the_excerpt', 'melville_custom_excerpt_more' ); /** * Remove inline styles printed when the gallery shortcode is used. @@ -146,12 +146,12 @@ add_filter( 'get_the_excerpt', 'twentyten_custom_excerpt_more' ); * @since Twenty Ten 1.0 * @return string The gallery style filter, with the styles themselves removed. */ -function twentyten_remove_gallery_css( $css ) { +function melville_remove_gallery_css( $css ) { return preg_replace( "##s", '', $css ); } -add_filter( 'gallery_style', 'twentyten_remove_gallery_css' ); +add_filter( 'gallery_style', 'melville_remove_gallery_css' ); -if ( ! function_exists( 'twentyten_comment' ) ) : +if ( ! function_exists( 'melville_comment' ) ) : /** * Template for comments and pingbacks. * @@ -162,7 +162,7 @@ if ( ! function_exists( 'twentyten_comment' ) ) : * * @since Twenty Ten 1.0 */ -function twentyten_comment( $comment, $args, $depth ) { +function melville_comment( $comment, $args, $depth ) { $GLOBALS['comment'] = $comment; switch ( $comment->comment_type ) : case '' : @@ -213,19 +213,19 @@ endif; * * @since Twenty Ten 1.0 */ -function twentyten_remove_recent_comments_style() { +function melville_remove_recent_comments_style() { global $wp_widget_factory; remove_action( 'wp_head', array( $wp_widget_factory->widgets['WP_Widget_Recent_Comments'], 'recent_comments_style' ) ); } -add_action( 'widgets_init', 'twentyten_remove_recent_comments_style' ); +add_action( 'widgets_init', 'melville_remove_recent_comments_style' ); -if ( ! function_exists( 'twentyten_posted_on' ) ) : +if ( ! function_exists( 'melville_posted_on' ) ) : /** * Prints HTML with meta information for the current post--date/time and author. * * @since Twenty Ten 1.0 */ -function twentyten_posted_on() { +function melville_posted_on() { printf( __( '%2$s', 'twentyten' ), 'meta-prep meta-prep-author', sprintf( '%3$s', @@ -237,13 +237,13 @@ function twentyten_posted_on() { } endif; -if ( ! function_exists( 'twentyten_posted_in' ) ) : +if ( ! function_exists( 'melville_posted_in' ) ) : /** * Prints HTML with meta information for the current post (category, tags and permalink). * * @since Twenty Ten 1.0 */ -function twentyten_posted_in() { +function melville_posted_in() { // Retrieves tag list of current post, separated by commas. $tag_list = get_the_tag_list( '', ', ' ); if ( $tag_list ) { @@ -265,10 +265,10 @@ function twentyten_posted_in() { endif; // dropcaps -function theme_shortcode_dropcaps($atts, $content = null, $code) { +function melville_shortcode_dropcaps($atts, $content = null, $code) { return '' . do_shortcode($content) . ''; } -add_shortcode('dropcap', 'theme_shortcode_dropcaps'); +add_shortcode('dropcap', 'melville_shortcode_dropcaps'); //build out our Portfolio Theme options @@ -317,4 +317,7 @@ function melville_theme_options_page() { ?>
Melville theme for WordPress, made by Raygun. - + diff --git a/loop.php b/loop.php index e1ac644..cc9cfdd 100644 --- a/loop.php +++ b/loop.php @@ -45,7 +45,7 @@