/**
  * Create the post content
  *
  * Detects whether to use the full length or excerpt of a post and displays it. Post thumbnails are included on
  * excerpt posts.
  * 
  * Override: childtheme_override_content <br>
  * Filter: seamless_post_thumbs <br>
  * Filter: seamless_post_thumb_size <br>
  * Filter: seamless_post_thumb_attr <br>
  * Filter: seamless_post 
  */
 function seamless_content()
 {
     global $seamless_content_length;
     if (strtolower($seamless_content_length) == 'full') {
         $post = get_the_content(seamless_more_text());
         $post = apply_filters('the_content', $post);
         $post = str_replace(']]>', ']]&gt;', $post);
     } elseif (strtolower($seamless_content_length) == 'excerpt') {
         $post = '';
         $post .= get_the_excerpt();
         $post = apply_filters('the_excerpt', $post);
         if (apply_filters('seamless_post_thumbs', TRUE)) {
             $post_title = get_the_title();
             $size = apply_filters('seamless_post_thumb_size', array(100, 100));
             $attr = apply_filters('seamless_post_thumb_attr', array('title' => sprintf(esc_attr__('Permalink to %s', 'seamless'), the_title_attribute('echo=0'))));
             if (has_post_thumbnail()) {
                 $post = sprintf('<a class="entry-thumb" href="%s" title="%s">%s</a>', get_permalink(), sprintf(esc_attr__('Permalink to %s', 'seamless'), the_title_attribute('echo=0')), get_the_post_thumbnail(get_the_ID(), $size, $attr)) . $post;
             }
         }
     } elseif (strtolower($seamless_content_length) == 'none') {
         $post = '';
     } else {
         $post = get_the_content(seamless_more_text());
         $post = apply_filters('the_content', $post);
         $post = str_replace(']]>', ']]&gt;', $post);
     }
     echo apply_filters('seamless_post', $post);
 }
예제 #2
0
 >

			<?php 
    // creating the post header
    seamless_postheader();
    ?>

				<div class="entry-content">

					<div class="entry-attachment"><?php 
    the_attachment_link($post->ID, true);
    ?>
</div>

						<?php 
    the_content(seamless_more_text());
    wp_link_pages(array('before' => sprintf('<nav class="page-link">%s', __('Pages:', 'seamless')), 'after' => '</nav>'));
    ?>

				</div><!-- .entry-content -->

				<?php 
    // creating the post footer
    seamless_postfooter();
    ?>

			</article><!-- #post -->

		<?php 
    // action hook for placing contentbelow #post
    seamless_belowpost();