Complying with the EU’s Electronic Privacy Directive

To comply with the EU Directive on Privacy and Electronic Communications, iMIS has added support for your organization to display a pop-up notification informing visitors that cookies are used on your site. This popup also includes a link to a longer sample privacy policy we have provided. You can find more information about this law on the ICO website.

Setting up cookie notifications requires that you edit your master page, review (and modify as needed) the privacy policy provided, and add a JavaScript file to iMIS.

Do the following to display cookie notification popups:

  1. Edit the master page of your website (by default located in C:\Program Files (x86)\ASI\iMIS\Net\Templates\MasterPages) to add the following items:
    1. Just under the <div id="masterWrapper">, add the following divs:
    2. Note: You can edit this content to change the look and feel of the popup to match the design of your site.

       <div id="EUCookieMessage" style="display: none;">
                      <div id="EUCookiewarningBack" style='z-index:999;
       position:absolute; width:100%;height:100%;background: rgb(0, 0, 0)
       transparent;background: rgba(0, 0, 0, 0.6);
      filter:progid:DXImageTransform.Microsoft.gradient(startColorstr=#99000000, endColorstr=#99000000);-ms-filter:
       \"progid:DXImageTransform.Microsoft.gradient(startColorstr=#99000000, endColorstr=#99000000)\"'>  
                      <div id="EUCookiewarning"
       style='margin:19%;padding:10px;width:62%;height:20%;background:white;color:black'>
                      <span id="EUCookiewarningtext"></span>
                      <a href="#" class="close-notify">Continue</a>
                      </div>
                      </div>
                      </div>
    3. At the bottom of the master page, just before the line <!-- Facebook API is loaded into here -->, add the following JavaScript reference:
    4. <script type="text/javascript" src="AsiCommon/Scripts/EUCookieWarning.js"></script>
  2. Review the sample privacy policy provided as a content record (@/iCore/Privacy_Policy) in RiSE > Page Builder > Manage content, and update it as needed for your organization.
  3. Note: If you need a privacy policy specific to your organization, copy the Privacy_Policy or create a new content record. Be sure to note the content folder where the content record is stored, as you will need to reference the content folder in the new JavaScript file (EUCookieWarning.js) shown in step 3.

  4. Create a JavaScript file named EUCookieWarning.js containing the following code, and add it to the Scripts folder (by default located in C:\Program Files (x86)\ASI\iMIS\Net\AsiCommon\Scripts).
  5. Note: The displayNotification function in this file contains the content of the pop-up notification displayed to users the first time they visit a page in your website. Be sure to update the privacy policy link in this message to point to the content record you want to display for this purpose. You can also edit the rest of the content for the needs of your organization.

    function getCookie(c_name)
    {
    var i,x,y,ARRcookies=document.cookie.split(";");
    for (i=0;i<ARRcookies.length;i++)
      {
      x=ARRcookies[i].substr(0,ARRcookies[i].indexOf("="));
      y=ARRcookies[i].substr(ARRcookies[i].indexOf("=")+1);
      x=x.replace(/^\s+|\s+$/g,"");
      if (x==c_name)
        {
        return unescape(y);
        }
      }
    }
     
    function displayNotification()
    {
    if (typeof jQuery('#EUCookieMessage' != 'undefined'))
    {
            jQuery('#EUCookieMessage').fadeIn("slow");
            if (typeof jQuery('##EUCookiewarning #EUCookiewarningtext' != 'undefined'))
            {
                    jQuery("#EUCookiewarning #EUCookiewarningtext").append
    ("In order for this site to work correctly we need to store a small file - called a cookie - on your computer.<br/>");
                    jQuery("#EUCookiewarning #EUCookiewarningtext").append
    ("<br/>");
                    jQuery("#EUCookiewarning #EUCookiewarningtext").append
    ("We use cookies to store information to make your visit to this site richer and to personalize information according<br/>");
                    jQuery("#EUCookiewarning #EUCookiewarningtext").append
    ("to your interests. See our <a href=\"@/iCore/Privacy_Policy.aspx\"
     target=\"_blank\">privacy policy</a> for more information on what cookies are, how we use them<br/>");
                    jQuery("#EUCookiewarning #EUCookiewarningtext").append
    ("and how to change your preferences.<br/>");
                    jQuery("#EUCookiewarning #EUCookiewarningtext").append
    ("<br/>");
                    jQuery("#EUCookiewarning #EUCookiewarningtext").append
    ("By continuing to use this site you are consenting to our use of cookies.<br/>");
                    jQuery("#EUCookiewarning #EUCookiewarningtext").append
    ("<br/>");
            }
            var closeBtn = jQuery('#EUCookieMessage a.close-notify');
            closeBtn.click(function() {
            setCookie("IMISEUCookieConfirm",null,3650);
            jQuery('#EUCookieMessage').fadeOut("slow");
            return false;
                    });
            }
    }
     
    function setCookie(c_name,value,exdays)
    {
    var exdate=new Date();
    exdate.setDate(exdate.getDate() + exdays);
    var c_value=escape(value) + ((exdays==null) ? "" : "; expires="+exdate.toUTCString());
    document.cookie=c_name + "=" + c_value;
    }
     
    function checkCookie()
    {
    var cookieName="IMISEUCookieConfirm";
    var cookieChk=getCookie(cookieName);
    if ( typeof cookieChk === "undefined")
      {
      displayNotification();        
      }
    }
     
    checkCookie();