熱點推薦:
您现在的位置: 電腦知識網 >> 編程 >> Java編程 >> Javascript >> 正文

用js實現“只彈出一次網頁窗口”的源代碼

2022-06-13   來源: Javascript 
<SCRIPT language=javascript>
function defaultwin(){
var exitwinurlownwin;
url = ;
exitwin = windowopen(urlnowexitwin);}
function get_cookie(Name) {
var search = Name + =
var returnvalue = ;
if (okielength > ) {
offset = okieindexOf(search)
if (offset != ) {
offset += searchlength
end = okieindexOf(; offset);
if (end == )
end = okielength;
returnvalue=unescape(okiesubstring(offset end))
}
}
return returnvalue;
}

function loadpopup(){
if (get_cookie(popped)==){
defaultwin()
okie=popped=yes
}
}
windowonload=loadpopup;
</SCRIPT>
From:http://tw.wingwit.com/Article/program/Java/Javascript/201311/25430.html
    推薦文章
    Copyright © 2005-2022 電腦知識網 Computer Knowledge   All rights reserved.