Home › Forums › Calendar Products › Events Calendar PRO › How to move Start and End Time of all events after both dates?
- This topic has 6 replies, 2 voices, and was last updated 8 years, 11 months ago by Geoff.
-
AuthorPosts
-
May 6, 2015 at 7:31 am #960793tbonnevilleParticipant
Hello,
We’d like to move the time after the dates.
So instead of this:
April 29@3:30 pm – June 3@5:30 pmWe want this:
April 29 – June 3 from 3:30 pm to 5:30 pm (or similar)Possible? If so, how to best achieve this.
Let us know – thank you.
T.
May 6, 2015 at 2:54 pm #960975GeoffMemberHey there tbonneville–nice to see you again and hope all is well. 🙂
Good question. You can change the date and time separators on the Events > Settings > Display screen. Here’s a screenshot of those fields. Go ahead and change those values and you should be able to get the format you’re looking for.
Cheers!
GeoffMay 7, 2015 at 4:39 am #961059tbonnevilleParticipantHi Geoff,
I hope you are doing well. Thank you very much for your reply.
Unfortunately, I don’t see how these fields would help me move both the start and the end time to after the last date. For you see, the events we deal with are weekly art classes, for instance a five day pottery classe from April 29 to June 3, from 3:30 to 5:30.
Have the following default format April 29@3:30 pm – June 3@5:30 pm is confusing.
We would rather have April 29 thru June 3 | 3:30 pm to 5:30 p.m.
Is that possible? and if so, how.
Thanks again for taking another look.
Best regards,
Thierry
May 7, 2015 at 7:44 am #961138GeoffMemberHey there, Thierry!
Ah gotcha–thanks for clarifying. That helps a lot. 🙂
I think the best way to get that format is to override the templates where those times are displayed. For example, changing the format on the event page itself would be:
- Make a copy of the single-event.php template. It is located at /plugins/the-events-calendar/views/single-event.php.
- Make a new folder in your theme directory called tribe-events
- Drop the copied file in that folder
Now that the template is in your theme, it can be customized to suit your needs. In this case, let’s remove this line:
<?php echo tribe_events_event_schedule_details( $event_id, '<h3>', '</h3>' ); ?>
…and instead replace it with the event details in the order you want:
Will that work for you? Please let me know. 🙂
Cheers!
GeoffMay 7, 2015 at 3:16 pm #961313tbonnevilleParticipantHi Geoff!
Thank you – I was able to add this:
<?php echo tribe_get_start_date( $postId = null, $displayTime = '', $dateFormat = '' ); echo " - " ; echo tribe_get_end_date( $postId = null, $displayTime = '', $dateFormat = '' ); echo " | From " ; echo tribe_get_start_time(); echo " to " ; echo tribe_get_end_time(); ?>
into mytheme/tribe-events/single-event.php I created and it’s working just fine.
Question though: This is only changing the format in the detail of the event but not on the list view of the Calendar showing all the events.
Where do I change that for the listing of all the events located here:
http://waterfallarts.org/events/Let me know – thank you.
Best regards,
Thierry
May 8, 2015 at 7:20 am #961450GeoffMemberYeah, absolutely–you’ll want to make that similar change in any template where those date instances pop up. For the main event list, will be in /views/list/single-event.php.
Our Themer’s Guide has a good breakdown of all the available templates to override, if you need a reference.
Cheers!
GeoffMay 22, 2015 at 10:08 am #964533GeoffMemberHey there, Thierry! This thread’s been quiet for a couple of weeks, so I’m going to go ahead and close it. Please feel free to hit us up with a new thread if you still have any questions here and we’d be happy to help. 🙂
Cheers!
Geoff -
AuthorPosts
- The topic ‘How to move Start and End Time of all events after both dates?’ is closed to new replies.