I am creating an events page for my website and would like a different sidebar that contains event related content.
I need to choose one of the page templates for my events page… but the only template available just has the default sidebar.
My understanding is I need to create a new page template with the specific sidebar that I want to use. Does anyone know how to create a new page template and change the sidebar?
Thank you!
Hello !
For creating specific sidebars on separate pages you will need to edit the page with the tagDiv Composer. Add a row, then edit the row and add a side column. And that’s how you will achieve a sidebar. After that add the elements you want in it.
Thank you !
Thank you for your resposne.
I understand that… but I am using an events plug-in that automatically generates an events page… and I need to choose the proper page template for that page that has my events sidebar connected to it.
The page template options its giving is
Default Events Template
Default Page Template
PageBuilder+last articles
Page Builder +page title
So essentially I need to duplicate one of these templates and add the sidebar I need to it.
I hope this makes more sense of what I need.
My website is http://www.local-pittsburgh.com
The events plug-in I am using is The Events Calendar by Modern Tribe
https://theeventscalendar.com/
You will see it automatically genereates the events page with the calendar. I need to try and edit the sidebar on that page it generates for me.
Thank you for your help on this
This is the events page that was generated by the plug-in.
https://local-pittsburgh.com/events/
If I use the “pagebuilder+sitetitle” template… would I be able to edit that template to include my events sidebar?
Hello !
I’ve searched the web a bit and found out this 2 links on how can you add the plugin to the sidebar: https://www.youtube.com/watch?v=0okrUs-xOq4 ; https://demo.eventcalendarnewsletter.com/the-events-calendar-shortcode/compact-design/
In order to get more information you will have to contact the plugin team because this is an untested plugin and we cannot offer support for it.
Thank you !
Hello, Thank you for looking into this for me but I believe you aren’t understanding my question correctly. I know how to add the widgets to the sidebar. I need to get a specific sidebar into a page template of the theme.
Here is a support post of someone trying to achieve the same thing and the instructions from The Events Calendar developers
https://theeventscalendar.com/support/forums/topic/change-the-sidebar-for-event/
“To control which sidebar shows on your events pages, you will need to select a template that has the code to output the sidebar. In Events > Settings > Events Template, you can choose between the default events template, the default theme page template, and any custom page templates you have created.
So, you will need to:
1) Create the custom template
2) Enable it in this setting
To create the template, I would start by making a copy of your theme’s default page template, and then modify it to use the sidebar of your choice. You can find more information about creating custom WordPress templates here: https://developer.wordpress.org/themes/template-files-section/page-template-files/
To learn more about adding a sidebar to your template, check out the documentation for adding sidebars: https://developer.wordpress.org/reference/functions/get_sidebar/”
Do you know how I can create the new template and add the proper sidebar to it?
Hi @localpittsburgh,
If I understand correctly, you want to edit the page template to show a certain sidebar on events page; in order to edit a page template you need to go in -> wp-content/themes/Newspaper/page-pagebuilder-latest.php
Hope this will help you!
Thanks.
Thank you for telling me which file I should edit.
do you happen to know where in the file I can assign the specific sidebar? I looked around the file a bit but nothing stuck out to me.
Hi,
For example if you want to set a page with “pagebuilder+sitetitle” you can go in wp-content/themes/Newspaper/page-pagebuilder-title.php and you need to look after get_sidebar -> https://www.screencast.com/t/RKSLQVbqd7n
Thank you!
So, If the sidebar I wanted to use was named “events” what should I change in the file? Would I just change “sidebar” to “events” ?
Thank you for working with me on this.
Hi,
You need to check this documentation for this -> https://developer.wordpress.org/reference/functions/get_sidebar/ also this is custom work, you need to do it yourself through the code and if you are not aware of the steps which are needed to take, in this case, please consider hiring a freelancer/developer to help you because we cannot provide custom work at the moment, sorry!
Thank you for your understanding!
Well this didnt help at all. Thanks for your time anyways