M
mbasil7
Hi at all.
Is there a way to detect with javascript the scrolling bar with of the
browser?
My problem is that the the following script assing to the pos
variable the browser window size but only internet explorer substracts
the scrolling bar with from the result.
<script language="JavaScript" type="text/JavaScript">
<!--
var pos;
if (window.innerWidth)
{
pos =window.innerWidth;
}
else if (document.documentElement &&
document.documentElement.clientWidth)
{
pos= document.documentElement.clientWidth;
}
else if (document.body)
{
pos= document.body.clientWidth;
}
//-->
</script>
At least i want to ask if there is a script that return exactly the
width of the browser's window that i have to output any text or
graphic?
Thanks in advance.
Is there a way to detect with javascript the scrolling bar with of the
browser?
My problem is that the the following script assing to the pos
variable the browser window size but only internet explorer substracts
the scrolling bar with from the result.
<script language="JavaScript" type="text/JavaScript">
<!--
var pos;
if (window.innerWidth)
{
pos =window.innerWidth;
}
else if (document.documentElement &&
document.documentElement.clientWidth)
{
pos= document.documentElement.clientWidth;
}
else if (document.body)
{
pos= document.body.clientWidth;
}
//-->
</script>
At least i want to ask if there is a script that return exactly the
width of the browser's window that i have to output any text or
graphic?
Thanks in advance.