</div> </div> <?php break; case "video": // Video Player or Embed theme_video_player($post->ID); break; } ?> </header> <div class="span7"> <?php theme_post_title($post->ID, 'h2'); ?> <div class="entry-summary"> <?php the_excerpt(); ?> </div><!-- .entry-summary --> <div class="entry-meta portfolio-details"> <?php // Portfolio meta details if ($item_client = get_post_meta($post->ID, 'theme_portfolio_client', true)) { echo '<span class="item-detail"><h6>' . __('Client:', 'framework') . '</h6> ' . $item_client . '</span>'; } if ($item_date = get_post_meta($post->ID, 'theme_portfolio_date', true)) {
<?php global $custom_query, $column_left, $column_right, $headerClass; /** * * The template for displaying posts in the Gallery post format * */ // Title (for everything except image left layout) if (!$column_right) { theme_post_title(); } $headerClass = $column_left ? 'span' . $column_left : ''; // Image size $shortcode = isset($custom_query->query) ? $custom_query->query : false; $size = get_post_image_size('post-thumbnail', $shortcode); // Check for specific width and height settings $max_w = ''; $max_h = ''; $style = ''; if (is_array($size)) { if ($size[0] != 0) { $max_w = 'max-width: ' . $size[0] . 'px;'; } if ($size[1] != 0) { $max_h = 'max-height: ' . $size[0] . 'px;'; } $style = 'style="' . $max_w . ' ' . $max_h . '"'; $size = $size[0] . 'x' . $size[1]; } $rotatorParams = array('columns' => 1, 'type' => 'post-gallery', 'image_size' => $size, 'transition' => 'fade', 'slide_paging' => 'true', 'autoplay' => 'true', 'interval' => '3500', 'class' => 'slideshow');
function theme_post_content($post_id = false, $content = false, $excerpt = false) { global $post, $custom_query, $portfolio; $post_id = $post_id ? $post_id : $post->ID; $post_type = get_post_type($post_id); $postExcerpts = get_options_data('blog-options', 'post-excerpts', 'false'); $postExcerpts = $postExcerpts == 'true' ? true : false; $excerptLength = get_options_data('blog-options', 'excerpt-length', false); $readMore = get_options_data('blog-options', 'read-more', -1); $readMore_Exclude = array('quote', 'link', 'image'); // post formats to exclude read more link $fromShortcode = $custom_query ? true : false; // Check for setting overrides by a shortcode query if (isset($custom_query)) { $customPostExcerpts = isset($custom_query->query['post_excerpts']) ? $custom_query->query['post_excerpts'] : false; $postExcerpts = $customPostExcerpts && !empty($customPostExcerpts) && $customPostExcerpts !== 'false' ? true : false; $customExcerptLength = isset($custom_query->query['excerpt_length']) ? $custom_query->query['excerpt_length'] : false; if ($customExcerptLength && !empty($customExcerptLength)) { $excerptLength = $customExcerptLength; } $customReadMore = isset($custom_query->query['read_more']) ? $custom_query->query['read_more'] : false; if ($customReadMore !== false && !empty($customReadMore)) { $readMore = $customReadMore; } } if (!is_single() && ($postExcerpts === true || is_search()) || is_single() && $fromShortcode && $postExcerpts) { ?> <div class="entry-content summary"> <?php $excerpt = get_the_excerpt(); // Excerpts only when exists and never on "Grid" style posts for the image format (unless it's a portfolio item which would have $post_type=portfolio) // if (strlen($excerpt) && !(isset($portfolio) && get_post_format() == 'image' && $post_type == 'post')) { if (strlen($excerpt) && !(get_post_format() == 'image' && $post_type == 'post')) { ?> <p><?php echo !in_array($excerptLength, array('0', '-1')) ? customExcerpt($excerpt, $excerptLength) : ''; ?> </p> <?php } if (!isset($portfolio)) { if (isset($readMore) && !empty($readMore) && $readMore != -1 && !in_array(get_post_format(), $readMore_Exclude)) { ?> <p class="readmore"><a href="<?php the_permalink(); ?> " class="btn small"><?php echo $readMore; ?> </a></p> <?php } } ?> </div><!-- .entry-summary --> <?php } elseif (!(!is_single() && $post_type == 'portfolio')) { ?> <div class="entry-content"> <?php the_content(__('Continue reading <span class="meta-nav">→</span>', 'framework')); ?> <?php wp_link_pages(array('before' => '<div class="page-links">' . __('Pages:', 'framework'), 'after' => '</div>')); ?> </div><!-- .entry-content --> <?php } // Footer if ($post_type == 'post' && !isset($portfolio)) { ?> <footer class="entry-footer entry-meta"> <?php if (is_single()) { edit_post_link(__('Edit', 'framework'), '<span class="edit-link">', '</span>'); } if (get_post_format() == 'image' && !is_single()) { // Image post format, title in footer theme_post_title(); } // theme_post_meta(); theme_post_tags(); if (is_single() && get_the_author_meta('description') && is_multi_author()) { // If a user has filled out their description and this is a multi-author blog, show a bio on their entries. ?> <div class="author-info"> <div class="author-avatar"> <?php echo get_avatar(get_the_author_meta('user_email'), apply_filters('theme_author_bio_avatar_size', 68)); ?> </div><!-- .author-avatar --> <div class="author-description"> <h2><?php printf(__('About %s', 'framework'), get_the_author()); ?> </h2> <p><?php the_author_meta('description'); ?> </p> <div class="author-link"> <a href="<?php echo esc_url(get_author_posts_url(get_the_author_meta('ID'))); ?> " rel="author"> <?php printf(__('View all posts by %s <span class="meta-nav">→</span>', 'framework'), get_the_author()); ?> </a> </div><!-- .author-link --> </div><!-- .author-description --> </div><!-- .author-info --> <?php } ?> </footer><!-- .entry-meta --> <?php } else { if ($post_type == 'post' && isset($portfolio)) { // This is the alternate footer for grid style post lists ?> <footer class="entry-footer entry-meta"> <?php // Read more if (isset($readMore) && !empty($readMore) && $readMore != -1 && !in_array(get_post_format(), $readMore_Exclude)) { ?> <p class="readmore"><a href="<?php the_permalink(); ?> " class="btn small"><?php echo $readMore; ?> </a></p> <?php } // Meta details theme_post_meta(); ?> </footer><!-- .entry-meta --> <?php } } // End Footer }