iCal Feed - Add Individual Events to External Calendars

Creating an iCal feed for your full calendar, but you might want to allow site visitors to add individual events to their calendar. To do this, you must add contextual filters to the view and another display to create the link for each event. 

Creating the Contextual Filter

Create a Contextual Filter for the NodeID

  1. On the view from the previous instructions, set a Contextual Filter to Node ID.
    Contextual Filter to NodeID
  2. Provide default value of Content ID from URL. 
    Add Filters to node id
  3. Create a Block display in the View and set the Contextual Filter to be the same as the one above.
  4. Remove all the fields from the Field listing and add a Global: Text field.
    Global text field
  5. Enter the following text in the field (click on image to view larger image)

    <a href=”/calendar/ical/!1/calendar.ics” class=”ican-icon” title=”Add to your calendar”>Add to your calendar</a>

    Global text field

  6. Go to your blocks listing and assign the block to the Content regions; restricting the display to only show on Events pages.