Click to See Complete Forum and Search --> : Refreshing window on re-size not working in firefox


PK246
08-09-2005, 12:36 PM
Dear friends,

I want window to be refreshed whenever it's re-sized. The following code works in IE but it does not work in firefox.

Here is the code:


<script type="text/javascript">
window.onresize = new Function("location.reload();");
</script>


How do I make it work in firefox browser also?

I'll appreciate your help.

Thank you.

rigadon
08-09-2005, 12:53 PM
from looking on the web shouldn't this be:

window.onresize=new Function("window.location.reload()");
:confused:

arto
08-09-2005, 02:46 PM
I don't know why reload() ain't working, but you can try this little hack instead: window.onresize = new Function("window.location=window.location.href;");Works in my FF.

Arto

PK246
08-09-2005, 03:02 PM
Thanks a lot Arto for the code. Your code is working perfectly on FF.

I really appreciate your help.

Thank you so much.