Guys I wrote this function 'newWidthHeight' in javascript to dynamically capture the width and height of the screen and display the div ‘abc’. The code is working fine for controlling the width but its not working while controlling the height. Line no 3 and 4 not working could u help me guide whats wrong in the script.
function newWidthHeight()
{
var xWidth = document.body.clientWidth;
document.getElementById('abc').style.width = xWidth;
var xHeight = document.body.clientHeight;
document.getElementById('abc').style.height = xHeight;
}
Thanks - DZyNer!