Use case:
In a local community website, there is one calendar for exhibitions and another one for community events. Calendar contents should not overlap: exhibitions should not be displayed in community events calendar and vice-versa.
Both calendars have a direct link in the menu that opens the calendar view with today "selected".
Attempt to implement this:
I've installed and enabled the Event module, and created two different content types: exhibitions and communityevents. I've specified "Show in event calendar: Only in views for this type".
Problem:
How can I create direct links to views that show only events of a specified type?
Something in the lines of /event/exhibitions (opens event calendar view that shows only exhibitions) and /event/communityevents (opens event calendar view that shows only community events).
Comments
I'm looking to do the same
I'm looking to do the same thing; but can't find the solution.
Also, when viewing the calendar (i've called mine "events"); so my url is /event
When I browse by a filter (selecting a specific category), when viewing the event detail, clicking on "calendar" brings me back to /event and the dropdown is selected "ALL", instead of staying refined to the original selection.
---
Back to your original inquiry, it currently seems impossible to directly link to a pre-selection because the URL uses the day/month today; which means if you create a hard link, it'll be out of date in a month, etc
Workaround
As a workaround, do the following for every separate event type (designated as xyz in the following):
1. create a page
2. choose a title, e.g. "Redirect to xyz"
3. paste the following to body:
drupal_goto('event/' . strftime('%Y/%m/%d') . '/month/xyz');4. choose php input format
5. assign it to a menu or use it via a short path alias like goto_xyz
Et voila, you have the behaviour we both need :)
how to create the second calendar?
How did you create two calendars cause i can't seem to figure that out.
I have the event calendar. And i see a calendar on the rightside. I added some text on certain dates.
So now i have ONE calendar that is working but how exactly do i create a second one.
I read something about creating views but i dont know how to do that for a event calendar.
Actually these two calendars represents two places(restaurants) and as content it contains the menu's that will be served just to give you an idea to what i want to accomplish. But it has to be two seperate calendars.
Thanks in advance for any help or ideas.
G.
--I'm not a native english speaker so be gentle :p
@gosasan
Hi gosasan,
Actually, you don't create a second calendar.
Make a new content type.. just like the 'Event' content type except name it whatever you want the second calendar events to be... Say you want a practice schedule for a hockey team. So create a new Content Type.. Name it 'Practice Schedule', set the type to 'practice' and then at the bottom where it says 'Show in event calendar:', select 'all views'.
Now, simply make a new page with that PHP code snippet state above, replacing xyz with your content type name, therefore in this case it would be 'practice'.
Now, when you go to the page, it will redirect you to the Event calendar except only showing events that have the content type name, 'practice'.
So really, you only have one calendar, but when you use the PHP snippet, it will only show what you want instead of everything on the calendar.
Hope this helps!
Thanks for the solution.
Thanks for the solution. This works great for directly accessing the extra content type.
But, it seems to break the cron.php script. When I comment this out, cron runs fine. I guess the drupal_goto() function is skipping out of the cron script mid-way through. Anyone else have this problem?
Cron broken too
The error message I get is "Cron run exceeded the time limit and was aborted". I really need the separate calendar. Any suggestions?
Update: If I unpublish the php page, cron runs successfully.
Drupal 5.8, Apache/2.2.9, PHP 5.2.6, MySQL 5.0.45
Last update: I removed an extra line at the end of devel.module (5.x-0.4) and cron runs fine now. No idea why that would matter.
Two calendars that aggregate to one?
This thread has been extremely helpful for me, but I'm beating my head against the wall about one thing. Here it is: my client wants multiple calendars, which, from the looks of it, with this approach and I can certainly deliver that product...however...they also want a master calendar, i.e. one that shows all the events from all the calendars on it.....and I can't seem to find a way to do that.
Any ideas?
this can be configured per
this can be configured per content type (content types that are enabled as event). you can set in which calenders these content types are shown.
Joris
Use lighter blue background for days on which events are present
Hi,
I am using event module in drupal 5 and i want to Use lighter blue background for days on which events are present in right block of calender.
I have spent on this many time now i need solution for that ....
Any one help me how can i do this......
Thanks ,
--
Azhar uddin
Technical Lead
email : engr.azharuddin@gmail.com
skype : computer_jin