Custom Excerpt Placeholder for Events Manager

This PHP snippet creates a #_CUSTOMEXCERPT placeholder to be used with the Events Manager plugin. Just throw it in functions.php, and you can then use #_CUSTOMEXCERPT in place of #_EVENTEXCERPT in your event/list templates.

The snippet has two variables you may wish to edit:

  • $strip_HTML – whether or not to remove HTML tags from the custom excerpt. Be careful if setting this to false, as this can cut off in the middle of your tag attributes (e.g., <img src=”/wp-content/uploa” />)
  • $length – the length of your custom excerpt (characters)

5 thoughts on “Custom Excerpt Placeholder for Events Manager”

    1. Thanks for making such a great plugin, Marcus! We use it to take our class registrations on this very site, and we are quite enamored of it. Good work!

    1. Sure thing, you would just have to adjust the subsequent parsing logic that follows (e.g. break the string up by spaces, and then grab however many words you want).

  1. Hey! Thanks for this post. I think this is just what I need.
    I have a quick question though… (note: PHP newbie here) Here’s my website – thefullquiver.com. If you look at the home page and look at the box that says “Upcoming Events” I want the external links in the event excerpt to be clickable in the list format (home page and Events page). Right now I’m using the placeholder #_EVENTEXCERPT{5,…}. How can I keep everything the same as it is now (using the code you provided), but make the external links (ex. facebook) clickable/hyperlinked?
    Your help is greatly appreciated! Thank you.

Leave a Reply

Your email address will not be published. Required fields are marked *