Creating a new List view

Home Forums Calendar Products Events Calendar PRO Creating a new List view

Viewing 7 posts - 1 through 7 (of 7 total)
  • Author
    Posts
  • #1103564
    John Paul
    Participant

    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.

    #1103774
    Geoff
    Member

    Howdy 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!
    Geoff

    #1103789
    John Paul
    Participant

    Thanks 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

    #1103818
    Geoff
    Member

    I 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.

    #1103821
    John Paul
    Participant

    good 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

    #1103901
    Geoff
    Member

    Oh, 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!
    Geoff

    #1110083
    Support Droid
    Keymaster

    This 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.

Viewing 7 posts - 1 through 7 (of 7 total)
  • The topic ‘Creating a new List view’ is closed to new replies.