Home › Forums › Calendar Products › Events Calendar PRO › Creating a new List view
- This topic has 6 replies, 3 voices, and was last updated 7 years, 11 months ago by Support Droid.
-
AuthorPosts
-
April 17, 2016 at 7:13 am #1103564John PaulParticipant
Hi, is it possible for me to create a completely new page view based on the List View?
I would like to create a View called ‘Courses at a glance’ which would be essentially the List view but with the image and content excerpt removed. I would achieve the view by using CSS to target the parts I dont want and remove and then use CSS to reformat the information that is to remain.
I am thinking that I would recreate the List folder in my child theme and call it List1 and then provide a link to it.
Am I barking up the right tree here? am desperate for some guidance on this as my client is rather persistent (against my advice) to have this additional view.Do you guys provide any custom devt services?? in case I need a quote.
April 18, 2016 at 7:58 am #1103774GeoffMemberHowdy John and thanks for getting in touch!
Yes, it’s absolutely possible to create a new page template and base it off the calendar’s List View. You can find the course code for List View here:
/wp-content/plugins/the-events-calendar/src/views/list.php
And within that template, you will notice references to other includes files which are located in:
/wp-content/plugins/the-events-calendar/src/views/list/
We also have the tribe_get_events() function which can be used to construct your own query of events and then build the markup for your page from there. Here’s a nice little article that outlines the function in much more detail.
I’m afraid we do not support custom development here in the forums. However, we do have a list of freelancers who wouldn’t hesitate to recommend for that level of support.
Will this help you get started? Please let me know. 🙂
Cheers!
GeoffApril 18, 2016 at 8:34 am #1103789John PaulParticipantThanks Geoff,
I am definitely having a go at this to improve my chops…
I will start by just duplicating what is in the /wp-content/plugins/the-events-calendar/src/views/list.php
and renaming it to list1.php and placing in my child theme..
can you advise what the child structure would look like please?
best
April 18, 2016 at 9:37 am #1103818GeoffMemberI actually think it would be much easier to create a new page template and drop tribe_get_events() in there with you own markup. That will prevent you from having to build and import more templates into the theme.
April 18, 2016 at 9:43 am #1103821John PaulParticipantgood advice geoff
excuse my ignorance (you must think me a real numpty 😉 )
but can you tell me where in the file structure I should place it to ensure it doesnt get over written on updates..
cheers
April 18, 2016 at 12:54 pm #1103901GeoffMemberOh, good question for sure! Glad you asked. 🙂
I would create a child theme and drop the new template file directly in that directory in the top level. No other levels should be needed from there.
Cheers!
GeoffMay 3, 2016 at 9:35 am #1110083Support DroidKeymasterThis topic has not been active for quite some time and will now be closed.
If you still need assistance please simply open a new topic (linking to this one if necessary)
and one of the team will be only too happy to help. -
AuthorPosts
- The topic ‘Creating a new List view’ is closed to new replies.