﻿
/*--------------*/
/* CALENDAR     */
/*--------------*/



function popupEvent(content, date_) {

    //load the content
    var parentPopupContainer = $("#popup-event-content", window.parent.document);


    //hide single dates but leave multi-day events showing the date range
    content = content.replace(/<div class=\"singleDay\"/g, "<div style='display:none;'");

    //IE
    content = content.replace(/<DIV class=singleDay/g, "<div style='display:none;'");
    
    //place the day of the event at the top as the title
    var displayDate = dateFormatLong(yyyymmddToDate(date_));

    content = "<h1 class='event-date'>" + displayDate + "</div>" + content;



    parentPopupContainer[0].innerHTML = content;

    //then pop it up
    parent.triggerPopup();
}
