# Javascript

**URL:** <https://forum.kirupa.com/t/javascript/156519>\
**Category:** Uncategorized\
**Created:** [July 26, 2005, 12:54pm UTC](https://forum.kirupa.com/t/javascript/156519 "2005-07-26T12:54:55Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Breen](https://avatars.discourse-cdn.com/v4/letter/b/e79b87/32.png) [@Breen](https://forum.kirupa.com/u/Breen)\
**Post date:** [July 26, 2005, 12:54pm UTC](https://forum.kirupa.com/t/javascript/156519/1 "2005-07-26T12:54:55Z")

</div>

```auto
<script>
function adjustWH(value){
  Height = window.innerHeight || document.body.offsetHeight
  target = value/Height * 100
  if (target < 100) {
  target = 100
  }
  document.getElementById("main").height = (Math.floor(target))+"%"
}
</script>

```

I need to get the previous script to work in firefox (its allready working in IE) is there anything i should pay attention to?
