[Plugin: The Events Calendar] Improvement: enable the [more-tag] for excerpts
Right now the event-list only shows the manually added excerpts.
If an event has no manually added excerpt, the event-list shows the complete content.
WordPress also allows to add a “more-tag” to the content of a post/event, which marks a line between the excerpt and the rest of the content.
To enable this functionality in The Events Calendar,
change the following in /views/list.php (lines 39-43)
<?php if (has_excerpt ()): ?> <?php the_excerpt(); ?> <?php else: ?> <?php the_content(); ?> <?php endif; ?>
<?php the_excerpt(); ?>
This is because when there is no manually added excerpt, the has_excerpt() method returns false and then the current code shows the complete content.
By replacing it with the_excerpt(), the automatic excerpts work also.
Best regards and thanks for a great plugin.
- The topic ‘[Plugin: The Events Calendar] Improvement: enable the [more-tag] for excerpts’ is closed to new replies.