Wordpress Themes - WP Forum at BFA
Click Here To DONATE! Support the theme development, get more attention and additional benefits based on your donation level. Your forum name will be highlighted.

Wordpress Themes - WP Forum at BFA » WordPress Themes » Montezuma Theme »

[SOLVED] How do I customize the teaser for each blog post on my main page


Build custom WP THEMES, without
coding.
Click here for THEMEFRAME

From the author of Atahualpa, the #1 most
downloaded (700,000+) theme @ wordpress.org
  #1  
Old Dec 4, 2012, 04:57 PM
domino66
 
6 posts · Dec 2012
Probably a noob Q, but I can't figure it out. I write blog posts, and the default Montezuma treatment is to just grab the first few sentences, and display them as the teaser/excerpt on my blog's main page.

But I actually want to write completely customized excerpts for my blog posts to appear as the teasers. For example, a blog post may start "I'm going to write all about my favorite restaurants..."

But I want the TEASER / excerpt that appears on my blog's main page to just say something like "Check out my trip reports for Chicago's best restaurants"

How do I do that?
  #2  
Old Dec 4, 2012, 05:16 PM
juggledad's Avatar
juggledad
 
21,980 posts · Mar 2009
OSX 10.8.5 WP 3.8.x Atahualpa 3.7.x Safari 6.x Firefox 25 XP
if you manually craft an excerpt in the post edit, it will automatically show up.
__________________
If you like my help, please consider donating. I am happy to provide greater detail on this and other topics if you hire me. Please send detailed support requests to me as a private message, thank you.
Juggledad | Forum Moderator/Support
  #3  
Old Dec 4, 2012, 06:20 PM
domino66
 
6 posts · Dec 2012
Quote:
Originally Posted by juggledad
if you manually craft an excerpt in the post edit, it will automatically show up.
I tried that but it didn't work. See screenshot below. Is that the EXCERPT field you're telling me to use? Because I tried, but the theme didn't use the text I put in there. It just continued to use the first couple sentences from the blog post itself.

  #4  
Old Dec 4, 2012, 06:50 PM
juggledad's Avatar
juggledad
 
21,980 posts · Mar 2009
OSX 10.8.5 WP 3.8.x Atahualpa 3.7.x Safari 6.x Firefox 25 XP
edit the subtemplate 'postformat.php' and change the line
HTML Code:
		<?php bfa_excerpt( 55, ' ...' ); ?>
to
HTML Code:
		<?php the_excerpt(); ?>
__________________
If you like my help, please consider donating. I am happy to provide greater detail on this and other topics if you hire me. Please send detailed support requests to me as a private message, thank you.
Juggledad | Forum Moderator/Support
  #5  
Old Dec 4, 2012, 07:24 PM
domino66
 
6 posts · Dec 2012
Quote:
Originally Posted by juggledad
edit the subtemplate 'postformat.php' and change the line
HTML Code:
		<?php bfa_excerpt( 55, ' ...' ); ?>
to
HTML Code:
		<?php the_excerpt(); ?>
Thanks very much; almost there...except that for some reason now my teaser (on my main blog page) looks like this...with an extraneous ellipsis and "Read More" in there:



FWIW, my subtemplate now looks like:

Quote:
<div id="post-<?php the_ID(); ?>" <?php post_class( 'cf' ); ?>>

<h2>
<span class="post-format"></span>
<a href="<?php the_permalink(); ?>" title="<?php the_title_attribute(); ?>" rel="bookmark"><?php the_title(); ?></a>
<?php bfa_comments_popup_link( '0', '1', '%' ); ?>
</h2>

<?php bfa_thumb( 620, 180, true, '<div class="thumb-shadow"><div class="post-thumb">', '</div></div>' ); ?>

<div class="post-bodycopy cf">

<div class="post-date">
<p class="post-month"><?php the_time( 'M' ); ?></p>
<p class="post-day"><?php the_time( 'j' ); ?></p>
<p class="post-year"><?php the_time( 'Y' ); ?></p>
</div>

<?php the_excerpt(); ?>

</div>

<div class="post-footer">
<a class="post-readmore" href="<?php the_permalink(); ?>" title="<?php the_title_attribute(); ?>">
<?php _e( 'read more &rarr;', 'montezuma' ); ?></a>
<p class="post-categories"><?php the_category( ' &middot; ' ); ?></p>
<?php the_tags( '<p class="post-tags">', '', '</p>' ); ?>
</div>

</div>
  #6  
Old Dec 5, 2012, 03:02 PM
domino66
 
6 posts · Dec 2012
bump; any ideas? I can't for the life of me figure out where that ... and 'read more' text is coming from!?
  #7  
Old Dec 5, 2012, 05:41 PM
juggledad's Avatar
juggledad
 
21,980 posts · Mar 2009
OSX 10.8.5 WP 3.8.x Atahualpa 3.7.x Safari 6.x Firefox 25 XP
try removing teh
HTML Code:
<?php _e( 'read more &rarr;', 'montezuma' ); ?></a>
__________________
If you like my help, please consider donating. I am happy to provide greater detail on this and other topics if you hire me. Please send detailed support requests to me as a private message, thank you.
Juggledad | Forum Moderator/Support
  #8  
Old Dec 10, 2012, 09:39 AM
domino66
 
6 posts · Dec 2012
Quote:
Originally Posted by juggledad
try removing teh
HTML Code:
<?php _e( 'read more &rarr;', 'montezuma' ); ?></a>
Nope, removing that line makes the WRONG "read more" disappear (see below)...this is really weird. I can't figure out where that line is coming from!?



EDIT: maybe this helps...when i delete this line entirely:
<?php the_excerpt(); ?>

the ugly '...read more' disappears too (but so does the entire excerpt, obv).
So i guess what i'm trying to get rid of resides in the the_excerpt element. Where do i find that thing to tweak it?

Last edited by domino66; Dec 10, 2012 at 09:42 AM.
  #9  
Old Dec 10, 2012, 10:06 AM
domino66
 
6 posts · Dec 2012
Solved:

looked in the functions.php file and found this, and removed the bolded line (tell me, I suppose, if I shouldn't have done that, or whether it'll cause problems in the future.):

// Add custom Read More link to manual excerpts:
function bfa_custom_excerpt_more( $output ) {
if ( has_excerpt() && ! is_attachment() )
$output .= bfa_read_more_link();
return $output;
}

add_filter( 'get_the_excerpt', 'bfa_custom_excerpt_more' );

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
"Post Teaser" plug-in for Atahualpa? Sally Center area post/pages 3 Jan 29, 2012 07:13 PM
[SOLVED] adding link to blog in menu (main page is static page) quidoloremipsum Page & Category Menu Bars 2 Mar 15, 2011 02:40 PM
Suddenly only 1 post appears on main blog and it is not the most recent post ScottM Forum How-To 5 Feb 6, 2011 12:21 PM
All Posts showing on main page. How can I get only certain post on main NoLimit24_FJ Forum How-To 1 Sep 22, 2009 05:18 PM


All times are GMT -6. The time now is 07:09 AM.


Powered by vBulletin® Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.