Home › Forums › Calendar Products › Events Calendar PRO › Adding a sidebar to the single events page
- This topic has 6 replies, 2 voices, and was last updated 11 years, 7 months ago by
Barry.
-
AuthorPosts
-
September 5, 2014 at 8:33 am #724693
Bob
ParticipantJust wanted to clarify I am on the right track, as I am not a developer, but don’t expect customizations here.
I am using WooThemes Canvas. I want to be able to have a sidebar on the single events page. Following your tuts I have created a custom template and put in in canvas/tribe-events/single-event.php. I did one minor edit (where I knew the site wouldn’t blow up) and it worked. Now my question, in order to add a sidebar into that template, I need to figure out the code that would go directly into it, right?
September 5, 2014 at 1:10 pm #725213Barry
MemberHi Bob,
Great question.
Essentially, if that’s where you want your sidebar to go, you would pull it in with a WordPress function such as dynamic_sidebar() – you may find you need to wrap it in additional divs or other markup for it to inherit the look and feel of your site (and, possibly, your theme may have its own wrapper function you can use instead).
Though this should all work and be possible, I do want to point out that single-event.php might not be the very best template in which to do this – though certainly give it a go and if it works well in the context of your theme that’s great. If you are using the default events template, though (you can check if this is the case by looking at the Events → Settings → Display admin screen), you may prefer to customize that template instead and add the sidebar in an appropriate place within there, instead, by using some code like this:
// If a single event post is being viewed, include a sidebar if ( is_singular() && tribe_is_event() ) { dynamic_sidebar( 'sidebar_name' ); }Does that help?
September 5, 2014 at 2:50 pm #725378Bob
ParticipantHey Barry, thanks, I gave that a try and put the customized default-template.php into the tribe-events folder, but nothing happened. Figure I am going to need to see if its using the funtion dynamic_sidebar() … may need to get some help on this 🙂 Thanks!
September 5, 2014 at 2:56 pm #725382Bob
ParticipantOkay, got it to pull it in, but obviously I will need to seek someone to help me with placement, cheers!
September 5, 2014 at 3:37 pm #725469Barry
MemberOK, great – so you don’t need any further assistance for the time being?
September 5, 2014 at 3:44 pm #725485Bob
ParticipantYeah, I think I may need to pay for some assistance on this one 🙂
September 5, 2014 at 4:44 pm #725641Barry
MemberOK – sometimes that is indeed the best and most sure-footed way forward. Certainly if you have any other issues relating to The Events Calendar/Events Calendar PRO (or even any further specific questions about this one on behalf of any designer/developer you hire) please don’t hesitate to create a new thread and ask.
We can’t always go into too much depth with customizations but we’re certainly happy to give a push in the right direction wherever possible.
Thanks again 🙂
-
AuthorPosts
- The topic ‘Adding a sidebar to the single events page’ is closed to new replies.
