problem with Multiple Iframe

Discussion in 'HTML and CSS' started by sweetsen, Jun 11, 2007.

  1. sweetsen

    sweetsen

    Joined:
    Jun 11, 2007
    Messages:
    1
    Likes Received:
    0
    Hi , I have a problem with multiple Iframe in a web page.
    When i click the SaveAll button , It should save the reports generated on the particular Date.

    It works fine in Firefox, But in IE it saves only the first file.

    Code:
    function makeIFrame(i)
    {
    var iframe = document.createElement("iframe");
    iframe.setAttribute("id", "downloader_"+i);
    iframe.setAttribute("height", "0");
    iframe.setAttribute("width", "0");
    document.body.appendChild(iframe);
    }

    function saveAll(completed_Date)
    {
    var i = 0;
    var tempArray =new Array();
    var j=0;
    <xsl:for-each select="/xml/reports_completed">
    if('<xsl:value-of select="completed_dts"/>'.substring(0,8) == completed_Dts.substring(0,8))
    {
    makeIFrame(i+1);
    var el=document.getElementById('downloader_'+ (i+1));
    tempArray[j] = '<xsl:value-of select="report_id"/>';

    if (!el)
    {
    alert("Cannot download report because the IFRAME has disappeared");
    }
    else
    {
    el.src="reports_scheduling.do?report_id=" +tempArray[j];

    }
    i+=1;
    j++;
    }
    </xsl:for-each>
    }

    I dont know why its not working in IE.Plz help me!

    Thanks in Advance,

    Regards,
    Senthil
     
    sweetsen, Jun 11, 2007
    #1
    1. Advertisements

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.