I want to open a pop up window automatically (when I open my website) after a particular date that I mention in the function.
How can I assign date function? I want this window to be opened automatically on 27/07/2011 and after that whenever I open the website. Please suggest
<script type="text/javascript">
function newPopup(url) {
popupWindow = window.open(
url,'popUpWindow','height=600,width=605,left=4,top=4,resizable=no,scrollbars=no,toolbar=no,menubar=no,location=no,directories=no,status=yes')
}
</script>
Make note that popup blockers will automatically block this window.
Most popup blockers only allow popups if they are triggered by the user, for example by a click.
Triggering the popup using on click event:
when the user click on the link, the function newPopup is triggered and your popup opens.