Home › Forums › Calendar Products › Events Calendar PRO › Custom Sidebars for each event
- This topic has 5 replies, 2 voices, and was last updated 8 years, 9 months ago by
Virginia Jackson.
-
AuthorPosts
-
July 21, 2017 at 4:34 am #1324267
Virginia Jackson
ParticipantHello,
Our site is currently laid out to have a main content area and two sidebars on the right using the Good News Theme. However when viewing an event the requirements state that there should be the main content area and then only one sidebar on the right that is customized to that specific event. Is it possible to do this within the product and if so how? We have tried to achieve this by modifying the settings -> display -> default stylesheets used for events template and event template options but can only get the two default sidebars for the site to show or none at all. We also tried creating a page which gives us the option to modify the sidebars and then adding the slug to the page but the full details of the event don’t show up(only title, dates, location, description). We have also tried the [tribe_event_inline id=”xxxx”] option but it still doesn’t show us everything we want for the event.
July 22, 2017 at 9:14 pm #1325010Jennifer
KeymasterHi Virginia,
Thanks for reaching out! I’ll be happy to help you with this.
You can add in just the one sidebar by modifying the template for events pages, which can be found at wp-content/plugins/the-events-calendar/src/views/single-event.php (see these instructions on modifying templates). You can add in the sidebar you want to display by using the get_sidebar function (with the name of sidebar between the parentheses like this: ‘sidebar-name’). You will likely need to add a little bit of styling to it as well.
As far as customizing the sidebar to the specific event, this could be a bit trickier if that sidebar is not already set up to be customized to the page it is displaying on. If you could provide a little bit more information on how you would like this to work (and if possible, send me a link to a page that has the sidebars on it currently), I’ll be happy to see what I can recommend!
Thanks,
Jennifer
July 23, 2017 at 5:18 pm #1325164Virginia Jackson
ParticipantThis reply is private.
July 26, 2017 at 1:30 am #1326237Jennifer
KeymasterHi Virginia,
Thanks for sharing those links.
I think your best bet is to add a custom sidebar directly into the single-event.php template (although as I mentioned before, you will likely need to adjust the styling).
The difficult part here is going to be getting the sidebars to display information dynamically based on the current event. For example, the countdown clock widget requires you to select a specific event. Getting it to automatically use the event it’s placed on would require customizing the code for the widget. For last year’s winner, sponsor, and lodging info, it looks like these might be custom fields you created with the Advanced Custom Fields plugin? If this is the case (or if you are using the Additional Fields that come with Pro), you could add those fields into a custom sidebar and display the information based on the current event ID for the page the sidebar is being displayed on. I’d recommend taking a look at this guide for more information on displaying meta data in sidebars.
You may also try a custom sidebar plugin (such as Custom Sidebars or Content Aware Sidebars for example), possibly with ACF shortcodes.
I want to point out that per our forum guidelines, we are a bit limited in the amount of support we can provide for customizations. Our themer’s guide has some great info on customizing our plugins if you’d like to give it a shot (we’ll be happy to answer questions and help point you in the right direction if you get stuck)! We also have a list of recommended developers if you’d like to get help with the code.
I’m sorry I don’t have a simpler solution for you, but I hope this is helpful! Please let me know if you have any questions!
Thanks,
Jennifer
August 17, 2017 at 9:35 am #1336843Support Droid
KeymasterHey there! This thread has been pretty quiet for the last three weeks, so we’re going to go ahead and close it to avoid confusion with other topics. If you’re still looking for help with this, please do open a new thread, reference this one and we’d be more than happy to continue the conversation over there.
Thanks so much!
The Events Calendar Support Team -
AuthorPosts
- The topic ‘Custom Sidebars for each event’ is closed to new replies.
