P
paul
HI! I have being to add the following as part of a function but it just will
not work as is but I don't know why, can someone point out why.
This opens up a popup window for a popup detection and is works in the head
of a page..
<script type="text/JavaScript" language="JavaScript">
var mine =
window.open('','','width=1,height=1,left=0,top=0,scrollbars=no');
if(mine)
var popUpsBlocked = false
else
var popUpsBlocked = true
mine.close()
</script>
This part displays an alert to the user if the window fails to open, this
part can be placed in the body and also works in a function.
<script type="text/JavaScript" language="JavaScript">
if(popUpsBlocked)
alert("We have detected that you are using popup blocking
software.\nPlease Disable it for this site or some features may not work
correctly.\n\nNOTE: If you are using Norton Internet Security you might have
to disable spam blocking\nor our menu system may or may not work
correctly.");
</script>
I can put it as part of a function like this.
function checkblockandpop(){
if(popUpsBlocked)
alert("We have detected that you are using popup blocking
software.\nPlease Disable it for this site or some features may not work
correctly.\n\nNOTE: If you are using Norton Internet Security you might have
to disable spam blocking\nor our menu system may or may not work
correctly.");
}
and call it with
<script type="text/javascript">
checkblockandpop();
</script>
But I want to put both together so I can use it as part of a detect function
and then set a cookie so that it displays only once to the user so it does
not annoy the user. but I don't know how to make them together.
Paul
not work as is but I don't know why, can someone point out why.
This opens up a popup window for a popup detection and is works in the head
of a page..
<script type="text/JavaScript" language="JavaScript">
var mine =
window.open('','','width=1,height=1,left=0,top=0,scrollbars=no');
if(mine)
var popUpsBlocked = false
else
var popUpsBlocked = true
mine.close()
</script>
This part displays an alert to the user if the window fails to open, this
part can be placed in the body and also works in a function.
<script type="text/JavaScript" language="JavaScript">
if(popUpsBlocked)
alert("We have detected that you are using popup blocking
software.\nPlease Disable it for this site or some features may not work
correctly.\n\nNOTE: If you are using Norton Internet Security you might have
to disable spam blocking\nor our menu system may or may not work
correctly.");
</script>
I can put it as part of a function like this.
function checkblockandpop(){
if(popUpsBlocked)
alert("We have detected that you are using popup blocking
software.\nPlease Disable it for this site or some features may not work
correctly.\n\nNOTE: If you are using Norton Internet Security you might have
to disable spam blocking\nor our menu system may or may not work
correctly.");
}
and call it with
<script type="text/javascript">
checkblockandpop();
</script>
But I want to put both together so I can use it as part of a detect function
and then set a cookie so that it displays only once to the user so it does
not annoy the user. but I don't know how to make them together.
Paul