Home › Forums › Calendar Products › Events Calendar PRO › Customizing Template Views
- This topic has 4 replies, 2 voices, and was last updated 12 years ago by
Barry.
-
AuthorPosts
-
March 22, 2014 at 7:19 pm #122140
latiuscia
ParticipantHi,
I’m trying to customizing the views because I need to adapt them to my theme, expecially list, map and photo. May I ask you which files I should editing? views files are not enough right?
here there are my questions (I’m so sorry):
> How can I get the category event or start date, I mean something like :
get_post_meta($post->ID, category, ‘true’)
I know this code is not working but could you please let me know how get the these informations?>In list view I would like move the title before the Tribe Bar. I tried editing events-calendar/views/list.php but the Title is inside the content Main Events Content. How can I extrat the Title end echo before the Tribe Bar?
>In photo view is it possible to add the Month / Year Headers??
>I would like to have a default view per kind page, I mean if page is category=photo view, if page is homepage=map view or if it is all events page=list. Where can I edit the code to do that? I think I’m going to getting and checking the kind of url to create an if, but where I can set the default view?
> In your pro version there is ad “add your event form”. Can I implement those form with the pro version???
Thanks a lot and sorry for these many questions.
(Site’s URL is a dev site)
March 24, 2014 at 7:41 pm #122724Barry
MemberHi – that’s a lot of questions! Let’s deal with your query about template overrides here and if you can post separate threads for the remaining issues that would be awesome – it helps us to provide faster responses (more than one team member can work with you) and helps avoid confusion.
I’m trying to customizing the views because I need to adapt them to my theme, expecially list, map and photo. May I ask you which files I should editing? views files are not enough right?
This is summarized in our Themer’s Guide – the essence of it though is that you would set up a new directory called tribe-events within your existing theme directory, something like this:
wp-content/plugins/themes/twentyfourteen/tribe-events
Of course, unless you are indeed using the Twenty Fourteen default theme that will be slightly different in your case. If you then want to override a template such as the list/content.php template, which is normally found at:
wp-content/plugins/the-events-calendar/views/list/content.php
You would copy that and place it in your new tribe-events directory, for example:
wp-content/plugins/themes/twentyfourteen/tribe-events/list/content.php
Does that clarify things?
March 25, 2014 at 6:15 am #122876latiuscia
ParticipantThanks you so much.
I understand that I have to override the file in theme folder as you told me. But in that case I can change just some elements. What I meant to do is for example:
> change the div class using my theme classes
> removing some elements like <div> or <p>Which files “calls” views/list/content.php ?
Thanks
LatiusciaMarch 25, 2014 at 9:15 am #122973Barry
Memberviews/list/content.php is pulled in by the views/list.php template – does that help at all?
April 8, 2014 at 9:17 am #129535Barry
MemberThis thread’s not seen much activity for the last couple of weeks so I’ll go ahead and close it. Of course if you still need help with this or any other issue please don’t hesitate to create a new thread (or threads) and one of the team will be only too happy to help. Thanks!
-
AuthorPosts
- The topic ‘Customizing Template Views’ is closed to new replies.
