Home › Forums › Calendar Products › Events Calendar PRO › How do I remove the start and end times?
- This topic has 10 replies, 3 voices, and was last updated 13 years ago by
Barry.
-
AuthorPosts
-
April 7, 2013 at 4:49 pm #45136
jtmrochem
ParticipantI want to be clear, I am not referring to the customization window that expands open under “Appearances” > “Plugins”. I am trying to disable the entire star/end time so that it does not show. All I need are the dates of each event, no need for start/end times.
April 8, 2013 at 6:24 am #45171Barry
MemberHi there – so the first thing to do (if you haven’t already done so) is read up on theming The Events Calendar and template overrides.
You’ll want to copy across and modify list.php to your theme’s events folder. Then, locate these lines in your custom version of list.php and remove them.
That should remove the start/end date fields from the meta area on the upcoming events list page.
April 13, 2013 at 3:05 am #45750Steve
ParticipantHi Barry
Just wondering how I remove only the end time?
ThanksApril 13, 2013 at 3:16 am #45751Steve
Participantand not necessarily just for list.php. Probably plugin wide, so for gridview, single.php, community events etc etc.
Want to do a similar thing with the year.
CheersApril 15, 2013 at 3:25 pm #45896Barry
MemberHi Steve!
Just wondering how I remove only the end time?
So in the snippet I shared last time there are basically three blocks, each starting with <tr> and ending with </tr> – in this case you could try removing the middle block.
and not necessarily just for list.php. Probably plugin wide, so for gridview, single.php, community events etc etc.
So going back to the previous example, note that that middle block contains a bit of code reading echo tribe_get_end_date(); – that is your clue that it relates to the end date.
While we can’t really guide you through making this change in each individual template the process is basically the same and so once again I’d recommend reading up on the same resources I provided in my initial post and taking things from there.
Thanks!
April 15, 2013 at 7:38 pm #45918jtmrochem
ParticipantWhere can I find list.php after I log in to the ftp?
April 15, 2013 at 8:32 pm #45922Barry
MemberYou should be able to find the original in wp-content/plugins/the-events-calendar/views. It’s worth bookmarking our Themer’s Guide – this section for instance summarizes the different folders you should look in and the role of the various different templates 🙂
April 18, 2013 at 3:25 am #46196Steve
Participant“So in the snippet I shared last time there are basically three blocks, each starting with and ending with – in this case you could try removing the middle block.”
This refers to the entire end date (incl time), not just the specific time itself.
Is there a way to just remove the time?
ThanksApril 18, 2013 at 6:00 am #46208Barry
MemberHi Steve,
There certainly is – if you can find the following piece of code (and the same pattern basically applies to tribe_get_start_date(), too):
echo tribe_get_end_date()Then you just need to modify it slightly:
echo tribe_get_end_date(null, false)And that should remove the time.
April 18, 2013 at 7:29 am #46220Steve
ParticipantGreat, thanks barry.
Done it for all i.e. single , list and single venue. However, want to get rid of it too in the pop up in gridview.
Thanks a lotApril 18, 2013 at 9:21 am #46234 -
AuthorPosts
- The topic ‘How do I remove the start and end times?’ is closed to new replies.
