
/* sticker_add_style - add a stylesheet to the current document.
 * Argument 'css' should be a URL to a stylesheet.
 */
function sticker_add_style(css) {
  var head        = document.getElementsByTagName("head")[0];
  var csslink     = document.createElement("link");
  var csslinkrel  = document.createAttribute("rel");
  csslinkrel.nodeValue = "stylesheet";
  csslink.setAttributeNode(csslinkrel);
  var csslinktype = document.createAttribute("type");
  csslinktype.nodeValue = "text/css";
  csslink.setAttributeNode(csslinktype);
  var csslinkhref = document.createAttribute("href");
  csslinkhref.nodeValue = css;
  csslink.setAttributeNode(csslinkhref);

  head.appendChild(csslink);
}


var eventful_css;
if (eventful_css) {
  sticker_add_style(eventful_css);
}


document.write("<a class='calendar-name' href='http://eventful.com/calendars/C0-001-000084552-7'>KenoCoMultiples - family events in the Chicago Area</a>");


var events = [
{
    'id': 'E0-001-027376839-6',
    'date_readable': '9 Feb 10',
    'date_iso8601': '20100209',
    'time_readable': '12 AM',
    'time_iso8601': 'T000000',
    'link': 'http://eventful.com/events/E0-001-027376839-6',
    'name': 'Gallery Talk: Heart and SoulÃ¢\"Art from Coretta Scott King Award Books, 2006Ã¢\"2009 (Exhibition Overview)',
    'description': 'Meet in Griffin CourtFree Mary Erbach, curator',
    'venue_link': 'http://eventful.com/venues/V0-001-000408893-5',
    'venue_name': 'Art Institute of Chicago',
  'venue_locality': 'Chicago, IL'
},
{
    'id': 'E0-001-027871574-2@2010020900',
    'date_readable': '9 Feb 10',
    'date_iso8601': '20100209',
    'time_readable': '12 AM',
    'time_iso8601': 'T000000',
    'link': 'http://eventful.com/events/E0-001-027871574-2@2010020900',
    'name': 'Toddler Time',
    'description': 'Start Time: 10:00 AM End Time: 11:00 AM  Stories, songs, and rhymes for children 20mos.-3 yrs. accompanied by an adult caregiver. The 7-week, 30-minute storytime is followed by an optional free-play period. MAP Location: Youth Services Program Room Presenter: Clara Status: We\'re sorry. This event is currently full.',
    'venue_link': 'http://eventful.com/venues/V0-001-000198291-3',
    'venue_name': 'Niles Public Library',
  'venue_locality': 'Niles, IL'
},
{
    'id': 'E0-001-027655857-8@2010020900',
    'date_readable': '9 Feb 10',
    'date_iso8601': '20100209',
    'time_readable': '12 AM',
    'time_iso8601': 'T000000',
    'link': 'http://eventful.com/events/E0-001-027655857-8@2010020900',
    'name': 'Toddler Time',
    'description': 'Start Time: 10:00 AM End Time: 11:00 AM  Stories, songs, and rhymes for children 20mos.-3 yrs. accompanied by an adult caregiver. The 7-week, 30-minute storytime is followed by an optional free-play period. MAP Location: Youth Services Program Room Presenter: Clara Status: We\'re sorry. This event is currently full.',
    'venue_link': 'http://eventful.com/venues/V0-001-000198291-3',
    'venue_name': 'Niles Public Library',
  'venue_locality': 'Niles, IL'
},
{
    'id': 'E0-001-028057337-0@2010020900',
    'date_readable': '9 Feb 10',
    'date_iso8601': '20100209',
    'time_readable': '12 AM',
    'time_iso8601': 'T000000',
    'link': 'http://eventful.com/events/E0-001-028057337-0@2010020900',
    'name': 'Black History Month – “Perseverance & Persistence: An Exhibition of Pride”',
    'description': 'Experience the successes of pop icon Michael Jackson as Navy Pier commemorates Black History Month with a specially-themed, month-long exhibit entitled, “Perseverance & Persistence: An Exhibition of Pride.”  The showcase is open to the public daily in February.  \n\nThis walk-through gallery experience, located at the Family Pavilion Stage North, highlights the achievements of notable African-Americans in various fields, including math, science, film, literature, politics, diplomacy,...',
    'venue_link': 'http://eventful.com/venues/V0-001-000112545-7',
    'venue_name': 'Navy Pier',
  'venue_locality': 'Chicago, IL'
},
{
    'id': 'E0-001-027046199-7@2010020900',
    'date_readable': '9 Feb 10',
    'date_iso8601': '20100209',
    'time_readable': '12 AM',
    'time_iso8601': 'T000000',
    'link': 'http://eventful.com/events/E0-001-027046199-7@2010020900',
    'name': 'HYATT REGENCY CHICAGO GIFTS CHICAGOLAND VISITORS THIS WINTER SEASON WITH SPECIAL SAVINGS',
    'description': 'Perfect winter offer features an exclusive savings for guests to enjoy Chicagoland festivities!\n\n\nChicago, IL– Chicago’s largest hotel, Hyatt Regency Chicago, 151 E. Wacker Drive, is featuring a special offer for guests to enjoy Chicago festivities over the winter season.  The city offers a multitude of activities and events for individuals and families.  Hyatt Regency Chicago’s winter special offer gives visitors 25% off the hotel’s best available rate, providing rates from $79. This...',
    'venue_link': 'http://eventful.com/venues/V0-001-000215626-9',
    'venue_name': 'Hyatt Regency Chicago',
  'venue_locality': 'Chicago, IL'
}];

var eventful_date;
var eventful_time;
var eventful_venue;
var eventful_venue_display;
var eventful_description;


document.write("<div class='vcalendar'>");

if (events.length < 1) {
  document.write("<div class='sticker-error'>No future events.</div>");
} else {
  for (e = 0; e < events.length; e++) {
    var event = events[e];
    document.write("<div class='vevent'>");
    if (eventful_date && eventful_time) {
      document.write("<abbr class='dtstart' title='" + event['date_iso8601']
          + "T" + event['time_iso8601'] + "'>"
          + event['date_readable'] + " " + event['time_readable'] + "</abbr>");
    } else if (eventful_date) {
      document.write("<abbr class='dtstart' title='" + event['date_iso8601'] + "'>"
          + event['date_readable'] + "</abbr>");
    } else if (eventful_time) {
      document.write("<abbr class='dtstart' title='" + event['time_iso8601'] + "'>"
          + event['time_readable'] + "</abbr>");
    }
    document.write(" <a class='url uid summary' href='" + event['link'] + "' title='" + event['name'] + "'>" + event['name'] + "</a>");
    if (eventful_venue) {
      if (eventful_venue_display == "city-state") {
        document.write(" in ");
        if (event['venue_link']) {
          document.write(" <a class='location' href='" + event['venue_link'] + "' title='" + event['venue_locality'] + "'>" + event['venue_locality'] + "</a>");
        } else {
          document.write(" <span class='location'>" + event['venue_locality'] + "</span>");
        }
      } else if (event['venue_name'] && (event['venue_name'] != ' ')) {
        document.write(" at ");
        if (event['venue_link']) {
          document.write(" <a class='location' href='" + event['venue_link'] + "' title='" + event['venue_name'] + "'>" + event['venue_name'] + "</a>");
        } else {
          document.write(" <span class='location'>" + event['venue_name'] + "</span>");
        }
      }
    }
    if (eventful_description) {
      document.write("<div class='summary'>" + event['description'] + "</div>");
    }
    document.write("</div>");
  }
}

document.write("</div>");

document.write("<div class='calendar-subs'>");
document.write("<div>\
<a href='http://eventful.com/rss/calendars/C0-001-000084552-7'>Subscribe</a>\
 <a href='http://eventful.com/rss/calendars/C0-001-000084552-7'><img src='http://eventful.com/images/skin/rss.gif' alt='Subscribe with RSS' title='Subscribe with RSS' width='36' height='14' /></a>\
</div>");
document.write("<div>\
<a href='webcal://eventful.com/ical/calendars/C0-001-000084552-7'>Subscribe</a>\
 <a href='webcal://eventful.com/ical/calendars/C0-001-000084552-7'><img src='http://eventful.com/images/skin/ical.gif' alt='Subscribe with iCalendar' title='Subscribe with iCalendar' width='36' height='14' /></a>\
</div>");
document.write("<div>\
<a href='http://eventful.com/ical/calendars/C0-001-000084552-7/C0-001-000084552-7.ics'>Download</a>\
 <a href='http://eventful.com/ical/calendars/C0-001-000084552-7/C0-001-000084552-7.ics'><img src='http://eventful.com/images/skin/ical.gif' alt='Subscribe with iCalendar' title='Download as iCalendar' width='36' height='14' /></a>\
</div>");
document.write("</div>");

document.write("<div class='calendar-footer'>");
document.write("powered by <a href='http://eventful.com/'>Eventful</a>");
document.write("</div>");