How to Use Single Event Data Values

September 20, 2023

Since EventON 4.5, it is now possible to display event data in plain text without any HTML using the standard calendar shortcodes that are already available in the plugin. This is ideal for site owners who would not prefer to use HTML within the post content or if you are looking for a minimalist layout for one of these reasons:

  • Accessibility: Plain text is more accessible to individuals with disabilities who rely on screen readers or other assistive technologies to browse websites.
  • Dynamic event dates: Using the plain text option allows you to change the event dates on embedded posts without having to edit the post again. You would only need to change the event date under the Events post type.
  • Consistency across various devices: Using event details values ensures that the page/post containing the event details is consistent across various devices and screen sizes.
  • Faster load times: Reducing the CSS and HTML on a page might help to reduce the load time of the page.
  • Legal Requirements: In certain industries or regions, there may be legal requirements for event details to be displayed in a specific format, often plain text for clarity and compliance.
  • AMP pages: Using the event shortcode in plain text will ensure that converting the page to AMP will work smoothly.

To get started with this feature, create a new event by going to WP Admin > Events > Add Event and add your event details. Please go through this guide for more details about creating new events: Getting Started with EventON: Adding Events.

Once this is done, go to the page or post that you want to embed the calendar. For the purpose of this tutorial, we’ll create a new post by going to WP Admin > Posts > Add New:

Once the post title and content have been added, we can embed the event shortcode within the content by following these steps:

Add the EventON block

Click on the Add block button and select the EventON shortcode block.

Add a Single Event

Using the shortcode generator, add a single event and select the Only selected event data values as the Event Display Style as shown below:

Enable the display of selected values

In the next option, toggle the option to Show only select Data values of the event and then select the fields that you would like to be displayed as shown below:

Save the shortcode and publish the post

You are now ready to publish the post and this should look like so:

Did this article help you? If not, send us a ticket via helpdesk

Ready to setup your calendar?