Click to See Complete Forum and Search --> : how to close TripodShowPopup()


nohack
07-21-2003, 08:15 AM
ermm..hope anybody here can teach me how to close Tripod Popup when someone entered by website. I've got this script when i saved one of my website page in my hard disk drive!!

<script language="JavaScript">
<!--
function TripodShowPopup()
{
var bName=navigator.appName;
var bVer=parseInt(navigator.appVersion);
var now = new Date();
var popupURL = "/adm/popup/roadmap.shtml?"+"member_name=spyder.edu&path=download.html&client_ip=210.186.48.49&ts=1058791436&ad_type=POPUP&id=fc70ae7332ef6d47e7deca3039df543d";
var popupName = "TripodPopup";
if (bName=="Netscape" && bVer<=3)
{
var popupWin = window.open("", popupName,'toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=0,resizable=0,width=755, height=200');
popupWin.blur();
}
else
{
var popupWin = window.open("", popupName,'toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=0,resizable=0,width=745, height=185');
popupWin.blur();
}
popupWin.location = popupURL;
}
TripodShowPopup();
// -->
</script>
<script language="JavaScript1.2">
<!--
function changeOpenFunction()
{
var original_window_open = window.open;
function new_open_function(url, name, features, replace)
{
if(name != "TripodPopup")
return original_window_open(url, name, features, replace);
}
window.open = new_open_function;
}
var bName = navigator.appName;

if(bName != "Netscape")
changeOpenFunction();
// -->
</script>
<!--insite and popunder-->
<script language="javascript" type="text/javascript">
function showUnder(scale) {
var expdate = new Date ();
var surveyCookieName = "TRIPODPOPUNDER";
var percentOfferedSurvey = 100;
var surveyLocation = "/adm/popunder/tripod_popunder.html?"+"member_name=spyder.edu&path=download.html&client_ip=210.186.48.49&ts=1058791436&ad_type=POPUP&id=fc70ae7332ef6d47e7deca3039df543d";
var popupNewWindow = true;

expdate.setTime (expdate.getTime() + (12 * 60 * 60 * 1000));
var stored_value = GetCookie(surveyCookieName);
if (stored_value == null){
SetCookie(surveyCookieName, "under", expdate, "/", ".tripod.com");
trUnder = window.open(surveyLocation,'under','height=300,width=720,toolbar=no,directories=no,status=no,menubar =no,scrollbars=no,resizable=no');
trUnder.blur();
}
}
function showInsite(){
var expdate = new Date ();
var surveyCookieName = "TRIPODINSITE";
var percentOfferedSurvey = 100;
var surveyLocation = "http://www.lycos.com/redir.asp?r=tp";
var popupNewWindow = true;

expdate.setTime (expdate.getTime() + (24 * 60 * 60 * 1000));
var stored_value = GetCookie(surveyCookieName);
if (stored_value == null){
SetCookie(surveyCookieName, "insite", expdate, "/", ".tripod.com");
trInsite = window.open(surveyLocation,'insite','height=340,width=790,toolbar=no,directories=no,status=no,menuba r=no,scrollbars=yes,resizable=yes');
trInsite.blur();
}
}


function SetCookie (name,value,expires,path,domain,secure){
document.cookie = name + "=" + escape (value) +
((expires) ? "; expires=" + expires.toGMTString() : "") +
((path) ? "; path=" + path : "") +
((domain) ? "; domain=" + domain : "") +
((secure) ? "; secure" : "");
}

function getCookieVal (offset){
var endstr = document.cookie.indexOf (";", offset);
if (endstr == -1)
endstr = document.cookie.length;
return unescape(document.cookie.substring(offset, endstr));
}

function GetCookie (name){
var arg = name + "=";
var alen = arg.length;
var clen = document.cookie.length;
if( (document.cookie == null) || (document.cookie.length == null)){
return null;
}
var i = 0;
while (i < clen){
var j = i + alen;
if (document.cookie.substring(i, j) == arg)
return getCookieVal (j);
i = document.cookie.indexOf(" ", i) + 1;
if (i == 0) break;
}
return null;
}
showUnder();

</script>
<BODY>

* it is easy to solve my problem.Tripod is very clever?

FMaz
07-21-2003, 08:19 AM
I'm totally not sure, but try:

window.TripodPopup.close()

nohack
07-21-2003, 08:38 AM
where should i put that script?

nohack
07-21-2003, 08:44 AM
or do you know script to minimize all kind of ad/popup? i mean when someone open my website, and some popup appear ..this script will automaticly minimize them!!

FMaz
07-21-2003, 03:00 PM
in the body tag:

<body OnLoad="window.TripodPopup.close()">