* @copyright Copyright (c) 2013, Nicolas GUILLAUME * @link http://themesandco.com/customizr * @license http://www.gnu.org/licenses/old-licenses/gpl-2.0.html */ if ( ! class_exists( 'TC_post' ) ) : class TC_post { static $instance; function __construct () { self::$instance =& $this; //add post header, content and footer to the __loop add_action ( '__loop' , array( $this , 'tc_post_content' )); //posts parts actions add_action ( '__after_content' , array( $this , 'tc_post_footer' )); } /** * The default template for displaying single post content * * @package Customizr * @since Customizr 3.0 */ function tc_post_content() { //check conditional tags : we want to show single post or single custom post types global $post; $tc_show_single_post_content = isset($post) && 'page' != $post -> post_type && 'attachment' != $post -> post_type && is_singular() && !tc__f( '__is_home_empty'); if ( !apply_filters( 'tc_show_single_post_content', $tc_show_single_post_content ) ) return; //display an icon for div if there is no title $icon_class = in_array( get_post_format(), array( 'quote' , 'aside' , 'status' , 'link' ) ) ? apply_filters( 'tc_post_format_icon', 'format-icon' ) :'' ; ob_start(); do_action( '__before_content' ); ?>
→' , 'customizr' ) ); ?> '' ) ); ?>
post_type && 'attachment' != $post -> post_type && is_singular(); if ( !apply_filters( 'tc_show_single_post_footer', $tc_show_single_post_footer ) ) return; if ( !is_singular() || !get_the_author_meta( 'description' ) || !apply_filters( 'tc_show_author_metas_in_post', true ) ) return; $html = sprintf('', '
', apply_filters( 'tc_author_meta_wrapper_class', 'row-fluid' ), sprintf('
%2$s
', apply_filters( 'tc_author_meta_avatar_class', 'comment-avatar author-avatar span2'), get_avatar( get_the_author_meta( 'user_email' ), apply_filters( 'tc_author_bio_avatar_size' , 100 ) ) ), sprintf('

%2$s

%3$s

', apply_filters( 'tc_author_meta_content_class', 'author-description span10' ), sprintf( __( 'About %s' , 'customizr' ), get_the_author() ), get_the_author_meta( 'description' ), sprintf( '', esc_url( get_author_posts_url( get_the_author_meta( 'ID' ) ) ), sprintf( __( 'View all posts by %s ' , 'customizr' ), get_the_author() ) ) ) );//end sprintf echo apply_filters( 'tc_post_footer', $html ); } }//end of class endif;