Home › Forums › Calendar Products › Events Calendar PRO › Setting Calendar to one month
- This topic has 14 replies, 5 voices, and was last updated 10 years, 9 months ago by
Support Droid.
-
AuthorPosts
-
July 29, 2013 at 4:58 am #57527
Simon
ParticipantCan I set the Calendar to just show October 2013? I have a festival that just covers this time period.
Cheers
SimonAugust 1, 2013 at 10:37 am #58289Rob
MemberHi there Simon. It seems to me the easiest way to do this (without modifying the code) would be to just target your links on the calendar to the October view. So rather than linking to siteurl.com/events, you’d link to siteurl.com/events/2013-10/ ? Are you looking to actively eliminate access to all other months/views?
August 1, 2013 at 3:11 pm #58395Simon
ParticipantRob,
Thanks for that – do I change the Event URL slug in Event Settings/General to this or via another route? I could do with freezing the widget on the site to October and yes, eliminate access to all other months.August 6, 2013 at 6:37 pm #59203Rob
MemberYo Simon! Basically the way I was thinking you’d do it would be to just change your menus under Appearance -> Menus to target /events/2013-10 instead of just /events. But that wouldn’t eliminate access to other months; it would just start users who clicked there on the month you specified (rather than starting them on the main calendar for the current month and allowing them to navigate around as they saw fit).
Removing access to the other months entirely is a substantially broader effort, unfortunately. It’d require some hacking at the code and customization that is admittedly outside the scope of what we can help on (and because it’d require modifying core plugin files, your changes would be lost whenever you update the plugin).
Knowing this: does the month targeting solution work as a stopgap?
August 7, 2013 at 4:27 am #59241Graeme
ParticipantHi Simom / Rob – I have a similar request, relating specifically to the min calendar (you can see my post here: https://theeventscalendar.com/support/forums/topic/mini-calendar-display-month-of-next-upcoming-event/)
I’m happy with hacking the plugin files (I can restore what I need after an upgrade), but could just use a gentle nudge in the right direction. Any suggestions Rob?
Thanks,
Graeme.August 7, 2013 at 10:34 am #59333Rob
MemberHi there Graeme. Good question; while this is outside my area of expertise, it doesn’t seem particularly unreasonable. Let me see if Barry or another member of the team can point you in the right direction here.
August 7, 2013 at 10:42 am #59334Graeme
ParticipantThanks Rob.
August 7, 2013 at 2:30 pm #59392Graeme
ParticipantSimon – a solution for you has been suggested here: https://theeventscalendar.com/support/forums/topic/mini-calendar-display-month-of-next-upcoming-event/
It works fine for me mate, so good luck.
To pass a specific month (rather than just next upcoming event month), just edit the last line call the function with a date param, so:
FROM:
new Tribe_Advance_Minical();
TO:
new Tribe_Advance_Minical(‘2013-10’);
Good luck.
August 7, 2013 at 3:49 pm #59415Simon
ParticipantGraeme; thanks for your input, much appreciated. Is this solution a theme Function in function.php or a file in the Event Calender plug-in php files. Just got lost with all the connected threads.
So put this where?
new Tribe_Advance_Minical(’2013-10′);Cheers
SimonAugust 7, 2013 at 4:00 pm #59417Graeme
ParticipantStick it in the theme’s functions.php, but you need to include all the code Barry placed on pastbin, not just that function call.
Good luck
August 8, 2013 at 8:38 am #59487Simon
ParticipantGraeme/Rob,
Thanks for all your help. Will go down the route you advised. Just one quick note though (to Rob and Tribe) I would have that thought this would be a simple function included in the plug-in as it’s a pretty common occurrence at an event/festival to have the events over one or two months or a weekend.
Again thanks.
SimonAugust 8, 2013 at 3:36 pm #59577Barry
MemberHi Simon, to go back to your original question first of all:
Can I set the Calendar to just show October 2013?
You could try adding this snippet to your functions.php file – with that in place and assuming you’ve set the default view to Month View then it should go straight to October 2013.
It won’t stop users from navigating forwards/backwards once they arrive on that page, but if that was necessary there are a number of ways you could do it.
Does that snippet basically get you closer to what you want (with the main events view)?
August 13, 2013 at 11:19 am #60231Rob
MemberHey Simon! Just wanted to follow-up here as per Barry’s last note. Can you let us know if you need anything else, or if this thread can indeed be closed? Thanks in advance.
August 20, 2013 at 4:39 pm #62122Rob
MemberGoing to close this one out. Simon, if you need further help please let us know by opening a new thread and we’ll do what we can to assist.
July 7, 2015 at 6:27 am #980188Support Droid
KeymasterThis 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 ‘Setting Calendar to one month’ is closed to new replies.
