FORUMS CLOSED DUE TO SPAM. YOU STILL CAN ADD POST!

Can you automate the Teaser?

Feed 3 posts, 2 voices

Avatar
79 posts

Could we possibly automate the teaser?
What about this?

<?php if ($article->hasContent('extended')) {echo substr($article->hasContent('extended'),0,400); echo $article->link('Continue Reading…');} ?>

ah maybe something like that actually works. Where that would just be in the ‘body’ part?

 
Avatar
1493 posts

Here you go JREAM -> Teaser HowTo

:)

 
Avatar
79 posts

Oh hey, Yeah I read that, see from this what Im trying to do:

<?php if ($article->hasContent('extended')) {

$article->hasContent('extended') = $ext;
echo substr($ext,0,600); // Here
echo $article->link('Continue Reading…'); 

}

?>

So I dont have to put anything in the Body, and it will only read 600 characters until the extended is opened, thus making is automated and not having to re edit by hand. I didnt see that in there

 
Avatar
1493 posts

Ahhh… Gotcha! You might be interested in knowing about Andy’s get-leading-sentences solution, too.

Might be worth adding some of these to the “how-to”, do you think?