[JS]
<script type="text/javascript">
<!--
function getWinWidth() {
isNav = (document.all) ? false : true;
isIE = (document.all) ? true : false;
if (isNav && !isIE)
return(window.innerWidth);
else if (isIE && !isNav)
return(document.body.clientWidth);
else
return(100);
}
var width = getWinWidth();
alert("width=" . width);
document.writeln('<textarea rows="29" name="resume"
cols="108">');
//-->
</script>
[/JS]
This entire script fails in Mozilla Firefox, Konqueror and IE 6+ in
all instances. Customer has a simple request: they want me to produce
a textarea that is dynamic in width that fills the entire window
because the content itself is dynamic in width (people's resumes) and
I cannot think of any way to do this except Javascript.
I borrowed code thinking I could get the instance to work, to no
avail, I continually get "undefined" for the "width" variable when
using the function I borrowed.
How do you simply get the window's width?
Thanx
Phil