linkedin

Frequently Asked Questions

⌘K
  1. Home
  2. /
  3. Docs
  4. /
  5. Frequently Asked Question...
  6. /
  7. Events
  8. /
  9. How do I display the even...

How do I display the event date in a specific place on my website?

If you would like to have the date display in a specific place you might have to do some custom development as this is controlled by your WooCommerce theme/template.

If you would like to modify the product/event page template, you will need to override the default WooCommerce templates. To do so, create a WooCommerce folder in your theme and copy over the relevant WooCommerce theme files and modify them.

WooCommerce themes:
https://docs.woocommerce.com/documentation/plugins/woocommerce/woocommerce-codex/theming/

Template Structure & Overriding Templates:
https://docs.woocommerce.com/document/template-structure/

The WooCommerce template that you usually need to start with is called content-single-product.php as this is where the product (event) is displayed in the store. You also need to add your own actions in order to add or change a layout.

Here is some more information about adding your own actions:
https://wordpress.stackexchange.com/questions/198447/woocommerce-overwrite-action-hook

In certain cases, you can display the Event Date custom field in a different location. Alternatively, you could consider making the date part of the event name or the event description and style it differently.

You will have to override the WooCommerce template and then display the custom fields called for that post (i.e event) “WooCommerceEventsDate” and “WooCommerceEventsEndDate“.

Tags , , ,