File tree Expand file tree Collapse file tree 4 files changed +10
-4
lines changed Expand file tree Collapse file tree 4 files changed +10
-4
lines changed Original file line number Diff line number Diff line change @@ -909,7 +909,7 @@ function get_teaser($text)
909
909
{
910
910
$ teaserType = config ('teaser.type ' );
911
911
912
- if (strlen ( strip_tags ( $ text )) < config ( ' teaser.char ' ) || $ teaserType === 'full ' ) {
912
+ if ($ teaserType === 'full ' ) {
913
913
echo $ text ;
914
914
} else {
915
915
$ string = preg_replace ('/\s\s+/ ' , ' ' , strip_tags ($ text ));
Original file line number Diff line number Diff line change 36
36
<?php } ?>
37
37
<div class="teaser-body" itemprop="articleBody">
38
38
<?php echo get_thumbnail ($ p ->body ) ?>
39
- <p><?php echo get_teaser ($ p ->body ) ?> ... <a href="<?php echo $ p ->url ;?> #more">more</a></p>
39
+ <p><?php echo get_teaser ($ p ->body ) ?>
40
+ <?php if (config ('teaser.type ' ) === 'trimmed ' ):?> ... <a href="<?php echo $ p ->url ;?> #more">more</a><?php endif ;?>
41
+ </p>
40
42
</div>
41
43
</div>
42
44
</div>
Original file line number Diff line number Diff line change 36
36
<?php } ?>
37
37
<div class="teaser-body" itemprop="articleBody">
38
38
<?php echo get_thumbnail ($ p ->body ) ?>
39
- <p><?php echo get_teaser ($ p ->body ) ?> ... <a href="<?php echo $ p ->url ;?> #more">more</a></p>
39
+ <p><?php echo get_teaser ($ p ->body ) ?>
40
+ <?php if (config ('teaser.type ' ) === 'trimmed ' ):?> ... <a href="<?php echo $ p ->url ;?> #more">more</a><?php endif ;?>
41
+ </p>
40
42
</div>
41
43
</div>
42
44
</div>
Original file line number Diff line number Diff line change 36
36
<?php } ?>
37
37
<div class="teaser-body" itemprop="articleBody">
38
38
<?php echo get_thumbnail ($ p ->body ) ?>
39
- <p><?php echo get_teaser ($ p ->body ) ?> ... <a href="<?php echo $ p ->url ;?> #more">more</a></p>
39
+ <p><?php echo get_teaser ($ p ->body ) ?>
40
+ <?php if (config ('teaser.type ' ) === 'trimmed ' ):?> ... <a href="<?php echo $ p ->url ;?> #more">more</a><?php endif ;?>
41
+ </p>
40
42
</div>
41
43
</div>
42
44
</div>
You can’t perform that action at this time.
0 commit comments