Creating the Difference

How to change default Event Dates & Times

Posted on: 15-12-2019 Last modified: 03-07-2021
Categories: HTML, PHP Tags:

When creating a new event in Events Manager, the working and the lay-out of the “When” meta box always bothered me.

I found it cluttered. The Time Picker always started at 00:00 and showed steps of 15 minutes.
My events always start at :00 or :30, so I have no need for :15 and :45. And… I like my interface clean and tidy.

Since the default times are hard-coded to midnight, it’s not easy to change those, right? WRONG! ;-)

Step 1: Create a new file on your server.

Create a new file on your live server in:

Step 2: Copy, Paste & Edit.

Copy the section of code below and paste it in the new file.
You may want to edit lines 5,6,12, 24, 25 and 26 to your personal needs.

Save the new file when you’re done.

Step 3: Log-in to WordPress

Log-in to WordPress and navigate to “Add New Event” to see the magic unfold before your eyes…
That’s all there is to it!

⇐ Previous