Home » Archive

Articles tagged with: body onload

  Posted: May 12 | Filed under: General

If you want to create a popup window to inform people about something before they visit a site, then it’s clearly a good way to use body onload in combination with javascript.


Use this little snippet inside your tag:

<script type="text/javascript">
function poponload()
{
ewindow=window.open("http://yoururl.com","mywindow1",
"location=1,status=1,scrollbars=1,
width=800,height=800");ewindow.moveTo(0,0);
}
</script >

And call it via the body tag.

<body onload="poponload()">