Unable to Embed Calender Report in Iframe

  • Profile Image
    J Meher
    Asked on October 13, 2018 at 04:41 AM

    Hi,

    I am trying to embed a Calendar Report in a website.   The height width is creating problem. Below  type of code is not available for iframe embeding. Please help. Thanks!

    My URL is :  https://www.jotform.com/calendar/82832101184045

    window.handleIFrameMessage = function(e) {

        var args = e.data.split(":");

            if (args.length > 2) { iframe = document.getElementById("JotFormIFrame-" + args[(args.length - 1)]); } else { iframe = document.getElementById("JotFormIFrame"); } 

    .....


    iframe.contentWindow.postMessage(JSON.stringify({"type":"urls","value":urls}), "*");

    t

    Screenshot
  • Profile Image
    Victoria_K
    Answered on October 13, 2018 at 07:00 AM

    Hello,

    We provide embed code when you create calendar report. Please check the following guide on how to get the code: How-to-Create-a-Calendar-Report

    153942844113-59-36.png

    We will gladly assist if you need any further help. 

  • Profile Image
    jmeher2
    Answered on October 13, 2018 at 08:51 AM

    Hi Victoria,

    Thanks for your quick reply. As mentioned by you I am  already using the embed code however This is not having proper width in mobile device. And also I need iframe.contentWindow should not be undefined. My specific requirement is cross origin frame access.  Could you please help me to generate the embed code containing like : "iframe.contentWindow.postMessage(JSON.stringify({"type":"urls","value":urls}), "*");"

    Not Like Below One (Currently Getting the Embed Code) : 

    <iframe src="https://www.jotform.com/calendar/82832101184045" frameborder="0" style="width: 100%; height: 100%; min-height: 500px; border:none;" scrolling="auto"></iframe>

    Thanks and Regards,

  • Profile Image
    Victoria_K
    Answered on October 13, 2018 at 09:52 AM

    This sounds like you need some sort of custom script attached to iframe code. Unfortunately, we do not have ready solution for that, but I assume you can take an idea of iframe embedding code for forms: Getting-the-Form-iFrame-Code

    Could we review your web page where your calendar is embedded?