Jump to content

[SOLVED] append child a div element not working?


sayedsohail

Recommended Posts

Hi i am trying to append a div inside the document, but its not working in IE and firefox. Here is my simple code.

 

function buildDimmerDiv()
{
z=document.body.appendChild(document.createElement("div"));
    z.id = "dimmer";
    z.style.width = window.screen.width+'px';
   z.style.height = window.screen.height+'px';
    
   
}

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.