//Examine the browser 检测浏览器的函数
var userAgent = navigator.userAgent.toLowerCase();
var is_opera = (userAgent.indexOf('opera') != -1);
var is_saf = ((userAgent.indexOf('applewebkit') != -1) || (navigator.vendor == 'Apple Computer, Inc.'));
var is_webtv = (userAgent.indexOf('webtv') != -1);
var is_ie = ((userAgent.indexOf('msie') != -1) && (!is_opera) && (!is_saf) && (!is_webtv));
var is_ie4 = ((is_ie) && (userAgent.indexOf('msie 4.') != -1));
var is_moz = ((navigator.product == 'Gecko') && (!is_saf));
var is_kon = (userAgent.indexOf('konqueror') != -1);
var is_ns = ((userAgent.indexOf('compatible') == -1) && (userAgent.indexOf('mozilla') != -1) && (!is_opera) && (!is_webtv) && (!is_saf));
var is_ns4 = ((is_ns) && (parseInt(navigator.appVersion) == 4));
var is_mac = (userAgent.indexOf('mac') != -1);
//Global registers
var currentblogid;
var currentstarid;
var currentcommentid;
var switchcomandmes;
var securitycodejs=null;
var onetimecounter=1;
//Get absolute path, fix bug of IE when base path is set
var gotourl = location.href;
var absbaseurl;
var abspath;
var r_identifier=gotourl.lastIndexOf("/read.php/");
var r_identifier2=gotourl.lastIndexOf("/post/");
var r_identifier3=gotourl.lastIndexOf("/tag/");
if (r_identifier==-1) {
r_identifier=r_identifier2;
}
if (r_identifier==-1) {
r_identifier=r_identifier3;
}
if (r_identifier!=-1) {
absbaseurl = gotourl.substr(0, r_identifier)+"/";
var simplegotourl=absbaseurl.replace("http://", '');
r_identifier2=simplegotourl.indexOf("/");
abspath=simplegotourl.substr(r_identifier2+1);
} else {
absbaseurl='';
abspath=null;
}
//Is Ajax supported?
if ((is_ie & !is_ie4) || is_moz || is_saf || is_opera) var shutajax=0;
else var shutajax=1;
//For firefox, tell Firefox not to display the content you input in last session
if (is_moz) {
var tmp_c=document.getElementById('v_content');
if (tmp_c) tmp_c.value='';
}
//Show/Hide a DIV
function showhidediv(id){
try{
var panel=document.getElementById(id);
if(panel){
if(panel.style.display=='none'){
panel.style.display='block';
}else{
panel.style.display='none';
}
}
}catch(e){}
}
function addhtml (id, htmlcode, uniqueid) {
var panel=document.getElementById(id);
var hiddenpannel=document.getElementById(uniqueid);
if(panel){
hiddenpannel.value='';
hiddenpannel.value=panel.innerHTML;
panel.innerHTML=hiddenpannel.value+htmlcode;
hiddenpannel.value+=htmlcode;
}
}
function showadminreply (divid) {
switchcomandmes='reply';
var cleanid=divid.replace('com_', '');
var inputcontent="<form action='"+absbaseurl+"admin.php?go=reply_addadminreply_"+cleanid+"' method='post' id='formadminreply"+cleanid+"'>";
inputcontent+=jslang[0]+"<br/><textarea cols='66' rows='3' name='adminreplycontent' id='adminreplycontent"+cleanid+"'></textarea><br/>";
inputcontent+="<input type='button' onclick=\"ajax_adminreply('"+cleanid+"'); return false;\" value='"+jslang[1]+"' class='button'/> <input type='reset' value='"+jslang[2]+"' class='button'/> <input type='button' value='"+jslang[3]+"' onclick=\"hideadminreply('"+divid+"');\" class='button'/></form>";
document.getElementById(divid).innerHTML=inputcontent;
document.getElementById(divid).style.display='block';
}
function showadminreplyformessage (divid) {
switchcomandmes='message';
var cleanid=divid.replace('com_', '');
var inputcontent="<form action='"+absbaseurl+"admin.php?go=message_addadminreply_"+cleanid+"' method='post' id='formadminreply"+cleanid+"'>";
inputcontent+=jslang[0]+"<br/><textarea cols='66' rows='3' name='adminreplycontent' id='adminreplycontent"+cleanid+"'></textarea><br/>";
inputcontent+="<input type='button' onclick=\"ajax_adminreply('"+cleanid+"'); return false;\" value='"+jslang[1]+"' class='button'/> <input type='reset' value='"+jslang[2]+"' class='button'/> <input type='button' value='"+jslang[3]+"' onclick=\"hideadminreply('"+divid+"');\" class='button'/></form>";
document.getElementById(divid).innerHTML=inputcontent;
document.getElementById(divid).style.display='block';
}
function hideadminreply (divid) {
document.getElementById(divid).innerHTML='';
document.getElementById(divid).style.display='none';
}
function showdelblog(blogid) {
var urldel=absbaseurl+"admin.php?go=entry_deleteblog_"+blogid+'';
if(confirm(jslang[4])){
window.location=urldel;
}
else {
return;
}
}
function comfirmurl(urldel) {
if(confirm(jslang[5])){
window.location=absbaseurl+urldel;
}
else {
return;
}
}
function showdeladminreply(repid) {
var urldel=absbaseurl+"admin.php?go=reply_deladminreply_"+repid+'';
if(confirm(jslang[6])){
if (shutajax==1) window.location=urldel;
else {
urldel+="&ajax=on";
currentcommentid=repid;
makeRequest(urldel, 'quickdeladminreply', 'GET', null);
}
}
else {
return;
}
}
function showdeladminreplyformessage(repid) {
var urldel=absbaseurl+"admin.php?go=message_deladminreply_"+repid+'';
if(confirm(jslang[7])){
if (shutajax==1) window.location=urldel;
else {
urldel+="&ajax=on";
currentcommentid=repid;
makeRequest(urldel, 'quickdeladminreply', 'GET', null);
}
}
else {
return;
}
}
function showdelreply(repid, blogid) {
var urldel=absbaseurl+"admin.php?go=reply_delreply_"+repid+'-'+blogid;
if(confirm(jslang[8])){
if (shutajax==1) window.location=urldel;
else {
urldel+="&ajax=on";
currentcommentid=repid;
makeRequest(urldel, 'quickdelreply', 'GET', null);
}
}
else {
return;
}
}
function showdelreplyformessage(repid) {
var urldel=absbaseurl+"admin.php?go=message_delreply_"+repid;
if(confirm(jslang[9])){
if (shutajax==1) window.location=urldel;
else {
urldel+="&ajax=on";
currentcommentid=repid;
makeRequest(urldel, 'quickdelreply', 'GET', null);
}
}
else {
return;
}
}
function showblockreply(repid, blogid) {
var urldel=absbaseurl+"admin.php?go=reply_block_"+repid+'-'+blogid;
if (shutajax==1) window.location=urldel;
else {
urldel+="&ajax=on";
currentcommentid=repid;
makeRequest(urldel, 'quickdelreply', 'GET', null);
}
}
function showblockmessage(repid) {
var urldel=absbaseurl+"admin.php?go=message_block_"+repid;
if (shutajax==1) window.location=urldel;
else {
urldel+="&ajax=on";
currentcommentid=repid;
makeRequest(urldel, 'quickdelreply', 'GET', null);
}
}
/* -- AJAX RELATED FUNCTIONS -- */
//Starring
function dostar(blogid) {
if (shutajax==0) {
gourl=absbaseurl+"admin.php?go=star&ajax=on&blogid="+blogid;
currentblogid=blogid;
currentstarid="starid"+blogid;
makeRequest(gourl, 'starblog', 'GET', null);
} else {
gourl=absbaseurl+"admin.php?go=star&ajax=off&blogid="+blogid;
window.location=gourl;
}
}
//Comment and Message
function ajax_submit (job) {
var stat_html = document.getElementById('stat_html').checked ? 1 : 0;
var stat_ubb = document.getElementById('stat_ubb').checked ? 1 : 0;
var stat_emot = document.getElementById('stat_emot').checked ? 1 : 0;
var stat_property = document.getElementById('stat_property').checked ? 1 : 0;
var v_replier = document.getElementById('v_replier').value+' ';
var v_repurl = document.getElementById('v_repurl').value;
var v_repemail = document.getElementById('v_repemail').value;
var v_content = document.getElementById('v_content').value+' ';
var v_password = document.getElementById('v_password').value;
var v_id = document.getElementById('v_id').value;
var v_reppsw = (document.getElementById('v_reppsw')) ? document.getElementById('v_reppsw').value : '';
var v_security_plus;
if (document.getElementById('v_security')) {
var v_security = document.getElementById('v_security').value;
if (v_security=='') {
alert(jslang[10]);
return false;
}
v_security_plus="&v_security="+v_security;
} else {
v_security_plus='';
}
if (v_replier=='' || v_content==''|| v_replier==' ' || v_content==' ' ) {
alert(jslang[11]);
return false;
}
document.getElementById('btnSubmit').value=jslang[12];
document.getElementById('btnSubmit').disabled='disabled';
if (shutajax==0) { //Currently for IE, Safari, Mozilla and Opera
v_replier = blogencode(v_replier);
v_repurl = blogencode(v_repurl);
v_repemail = blogencode(v_repemail);
v_content = blogencode(v_content);
v_password = blogencode(v_password);
v_id = blogencode(v_id);
v_reppsw = blogencode(v_reppsw);
var postData = "unuse=unuse&onetimecounter="+onetimecounter+"&v_id="+v_id+"&v_replier="+v_replier+"&v_password="+v_password+"&v_repurl="+v_repurl+"&v_repemail="+v_repemail+"&v_content="+v_content+"&stat_html="+stat_html+"&stat_ubb="+stat_ubb+"&stat_emot="+stat_emot+"&v_reppsw="+v_reppsw+"&stat_property="+stat_property+v_security_plus;
var gourl=absbaseurl+"visit.php?ajax=on&job="+job;
makeRequest(gourl, 'quickreply', 'POST', postData);
} else {
document.getElementById('visitorinput').submit();
}
}
//Ctrl+Enter key submitting (Textarea)
function ctrlenterkey (eventobject){
if(eventobject.ctrlKey && eventobject.keyCode==13) {
document.getElementById("btnSubmit").click();
}
}
//Admin reply
function ajax_adminreply (commentid) {
if (shutajax==0) {
var admid='adminreplycontent'+commentid;
var adminreplycontent = blogencode(document.getElementById(admid).value);
var postData = "unuse=unuse&adminreplycontent="+adminreplycontent;
var gourl=absbaseurl+"admin.php?ajax=on&go="+switchcomandmes+"_addadminreply_"+commentid;
currentcommentid=commentid;
makeRequest(gourl, 'quickadminreply', 'POST', postData);
} else {
var admid='formadminreply'+commentid;
document.getElementById(admid).submit();
}
}
function ajax_adminreply_edit (commentid, rptype) {
switchcomandmes=rptype;
ajax_adminreply(commentid);
}
12下一页阅读全文
var userAgent = navigator.userAgent.toLowerCase();
var is_opera = (userAgent.indexOf('opera') != -1);
var is_saf = ((userAgent.indexOf('applewebkit') != -1) || (navigator.vendor == 'Apple Computer, Inc.'));
var is_webtv = (userAgent.indexOf('webtv') != -1);
var is_ie = ((userAgent.indexOf('msie') != -1) && (!is_opera) && (!is_saf) && (!is_webtv));
var is_ie4 = ((is_ie) && (userAgent.indexOf('msie 4.') != -1));
var is_moz = ((navigator.product == 'Gecko') && (!is_saf));
var is_kon = (userAgent.indexOf('konqueror') != -1);
var is_ns = ((userAgent.indexOf('compatible') == -1) && (userAgent.indexOf('mozilla') != -1) && (!is_opera) && (!is_webtv) && (!is_saf));
var is_ns4 = ((is_ns) && (parseInt(navigator.appVersion) == 4));
var is_mac = (userAgent.indexOf('mac') != -1);
//Global registers
var currentblogid;
var currentstarid;
var currentcommentid;
var switchcomandmes;
var securitycodejs=null;
var onetimecounter=1;
//Get absolute path, fix bug of IE when base path is set
var gotourl = location.href;
var absbaseurl;
var abspath;
var r_identifier=gotourl.lastIndexOf("/read.php/");
var r_identifier2=gotourl.lastIndexOf("/post/");
var r_identifier3=gotourl.lastIndexOf("/tag/");
if (r_identifier==-1) {
r_identifier=r_identifier2;
}
if (r_identifier==-1) {
r_identifier=r_identifier3;
}
if (r_identifier!=-1) {
absbaseurl = gotourl.substr(0, r_identifier)+"/";
var simplegotourl=absbaseurl.replace("http://", '');
r_identifier2=simplegotourl.indexOf("/");
abspath=simplegotourl.substr(r_identifier2+1);
} else {
absbaseurl='';
abspath=null;
}
//Is Ajax supported?
if ((is_ie & !is_ie4) || is_moz || is_saf || is_opera) var shutajax=0;
else var shutajax=1;
//For firefox, tell Firefox not to display the content you input in last session
if (is_moz) {
var tmp_c=document.getElementById('v_content');
if (tmp_c) tmp_c.value='';
}
//Show/Hide a DIV
function showhidediv(id){
try{
var panel=document.getElementById(id);
if(panel){
if(panel.style.display=='none'){
panel.style.display='block';
}else{
panel.style.display='none';
}
}
}catch(e){}
}
function addhtml (id, htmlcode, uniqueid) {
var panel=document.getElementById(id);
var hiddenpannel=document.getElementById(uniqueid);
if(panel){
hiddenpannel.value='';
hiddenpannel.value=panel.innerHTML;
panel.innerHTML=hiddenpannel.value+htmlcode;
hiddenpannel.value+=htmlcode;
}
}
function showadminreply (divid) {
switchcomandmes='reply';
var cleanid=divid.replace('com_', '');
var inputcontent="<form action='"+absbaseurl+"admin.php?go=reply_addadminreply_"+cleanid+"' method='post' id='formadminreply"+cleanid+"'>";
inputcontent+=jslang[0]+"<br/><textarea cols='66' rows='3' name='adminreplycontent' id='adminreplycontent"+cleanid+"'></textarea><br/>";
inputcontent+="<input type='button' onclick=\"ajax_adminreply('"+cleanid+"'); return false;\" value='"+jslang[1]+"' class='button'/> <input type='reset' value='"+jslang[2]+"' class='button'/> <input type='button' value='"+jslang[3]+"' onclick=\"hideadminreply('"+divid+"');\" class='button'/></form>";
document.getElementById(divid).innerHTML=inputcontent;
document.getElementById(divid).style.display='block';
}
function showadminreplyformessage (divid) {
switchcomandmes='message';
var cleanid=divid.replace('com_', '');
var inputcontent="<form action='"+absbaseurl+"admin.php?go=message_addadminreply_"+cleanid+"' method='post' id='formadminreply"+cleanid+"'>";
inputcontent+=jslang[0]+"<br/><textarea cols='66' rows='3' name='adminreplycontent' id='adminreplycontent"+cleanid+"'></textarea><br/>";
inputcontent+="<input type='button' onclick=\"ajax_adminreply('"+cleanid+"'); return false;\" value='"+jslang[1]+"' class='button'/> <input type='reset' value='"+jslang[2]+"' class='button'/> <input type='button' value='"+jslang[3]+"' onclick=\"hideadminreply('"+divid+"');\" class='button'/></form>";
document.getElementById(divid).innerHTML=inputcontent;
document.getElementById(divid).style.display='block';
}
function hideadminreply (divid) {
document.getElementById(divid).innerHTML='';
document.getElementById(divid).style.display='none';
}
function showdelblog(blogid) {
var urldel=absbaseurl+"admin.php?go=entry_deleteblog_"+blogid+'';
if(confirm(jslang[4])){
window.location=urldel;
}
else {
return;
}
}
function comfirmurl(urldel) {
if(confirm(jslang[5])){
window.location=absbaseurl+urldel;
}
else {
return;
}
}
function showdeladminreply(repid) {
var urldel=absbaseurl+"admin.php?go=reply_deladminreply_"+repid+'';
if(confirm(jslang[6])){
if (shutajax==1) window.location=urldel;
else {
urldel+="&ajax=on";
currentcommentid=repid;
makeRequest(urldel, 'quickdeladminreply', 'GET', null);
}
}
else {
return;
}
}
function showdeladminreplyformessage(repid) {
var urldel=absbaseurl+"admin.php?go=message_deladminreply_"+repid+'';
if(confirm(jslang[7])){
if (shutajax==1) window.location=urldel;
else {
urldel+="&ajax=on";
currentcommentid=repid;
makeRequest(urldel, 'quickdeladminreply', 'GET', null);
}
}
else {
return;
}
}
function showdelreply(repid, blogid) {
var urldel=absbaseurl+"admin.php?go=reply_delreply_"+repid+'-'+blogid;
if(confirm(jslang[8])){
if (shutajax==1) window.location=urldel;
else {
urldel+="&ajax=on";
currentcommentid=repid;
makeRequest(urldel, 'quickdelreply', 'GET', null);
}
}
else {
return;
}
}
function showdelreplyformessage(repid) {
var urldel=absbaseurl+"admin.php?go=message_delreply_"+repid;
if(confirm(jslang[9])){
if (shutajax==1) window.location=urldel;
else {
urldel+="&ajax=on";
currentcommentid=repid;
makeRequest(urldel, 'quickdelreply', 'GET', null);
}
}
else {
return;
}
}
function showblockreply(repid, blogid) {
var urldel=absbaseurl+"admin.php?go=reply_block_"+repid+'-'+blogid;
if (shutajax==1) window.location=urldel;
else {
urldel+="&ajax=on";
currentcommentid=repid;
makeRequest(urldel, 'quickdelreply', 'GET', null);
}
}
function showblockmessage(repid) {
var urldel=absbaseurl+"admin.php?go=message_block_"+repid;
if (shutajax==1) window.location=urldel;
else {
urldel+="&ajax=on";
currentcommentid=repid;
makeRequest(urldel, 'quickdelreply', 'GET', null);
}
}
/* -- AJAX RELATED FUNCTIONS -- */
//Starring
function dostar(blogid) {
if (shutajax==0) {
gourl=absbaseurl+"admin.php?go=star&ajax=on&blogid="+blogid;
currentblogid=blogid;
currentstarid="starid"+blogid;
makeRequest(gourl, 'starblog', 'GET', null);
} else {
gourl=absbaseurl+"admin.php?go=star&ajax=off&blogid="+blogid;
window.location=gourl;
}
}
//Comment and Message
function ajax_submit (job) {
var stat_html = document.getElementById('stat_html').checked ? 1 : 0;
var stat_ubb = document.getElementById('stat_ubb').checked ? 1 : 0;
var stat_emot = document.getElementById('stat_emot').checked ? 1 : 0;
var stat_property = document.getElementById('stat_property').checked ? 1 : 0;
var v_replier = document.getElementById('v_replier').value+' ';
var v_repurl = document.getElementById('v_repurl').value;
var v_repemail = document.getElementById('v_repemail').value;
var v_content = document.getElementById('v_content').value+' ';
var v_password = document.getElementById('v_password').value;
var v_id = document.getElementById('v_id').value;
var v_reppsw = (document.getElementById('v_reppsw')) ? document.getElementById('v_reppsw').value : '';
var v_security_plus;
if (document.getElementById('v_security')) {
var v_security = document.getElementById('v_security').value;
if (v_security=='') {
alert(jslang[10]);
return false;
}
v_security_plus="&v_security="+v_security;
} else {
v_security_plus='';
}
if (v_replier=='' || v_content==''|| v_replier==' ' || v_content==' ' ) {
alert(jslang[11]);
return false;
}
document.getElementById('btnSubmit').value=jslang[12];
document.getElementById('btnSubmit').disabled='disabled';
if (shutajax==0) { //Currently for IE, Safari, Mozilla and Opera
v_replier = blogencode(v_replier);
v_repurl = blogencode(v_repurl);
v_repemail = blogencode(v_repemail);
v_content = blogencode(v_content);
v_password = blogencode(v_password);
v_id = blogencode(v_id);
v_reppsw = blogencode(v_reppsw);
var postData = "unuse=unuse&onetimecounter="+onetimecounter+"&v_id="+v_id+"&v_replier="+v_replier+"&v_password="+v_password+"&v_repurl="+v_repurl+"&v_repemail="+v_repemail+"&v_content="+v_content+"&stat_html="+stat_html+"&stat_ubb="+stat_ubb+"&stat_emot="+stat_emot+"&v_reppsw="+v_reppsw+"&stat_property="+stat_property+v_security_plus;
var gourl=absbaseurl+"visit.php?ajax=on&job="+job;
makeRequest(gourl, 'quickreply', 'POST', postData);
} else {
document.getElementById('visitorinput').submit();
}
}
//Ctrl+Enter key submitting (Textarea)
function ctrlenterkey (eventobject){
if(eventobject.ctrlKey && eventobject.keyCode==13) {
document.getElementById("btnSubmit").click();
}
}
//Admin reply
function ajax_adminreply (commentid) {
if (shutajax==0) {
var admid='adminreplycontent'+commentid;
var adminreplycontent = blogencode(document.getElementById(admid).value);
var postData = "unuse=unuse&adminreplycontent="+adminreplycontent;
var gourl=absbaseurl+"admin.php?ajax=on&go="+switchcomandmes+"_addadminreply_"+commentid;
currentcommentid=commentid;
makeRequest(gourl, 'quickadminreply', 'POST', postData);
} else {
var admid='formadminreply'+commentid;
document.getElementById(admid).submit();
}
}
function ajax_adminreply_edit (commentid, rptype) {
switchcomandmes=rptype;
ajax_adminreply(commentid);
}
12下一页阅读全文
免责声明:本站文章均来自网站采集或用户投稿,网站不提供任何软件下载或自行开发的软件!
如有用户或公司发现本站内容信息存在侵权行为,请邮件告知! 858582#qq.com
暂无“一个不错的可以检测多中浏览器的函数和其它功能第1/2页”评论...
P70系列延期,华为新旗舰将在下月发布
3月20日消息,近期博主@数码闲聊站 透露,原定三月份发布的华为新旗舰P70系列延期发布,预计4月份上市。
而博主@定焦数码 爆料,华为的P70系列在定位上已经超过了Mate60,成为了重要的旗舰系列之一。它肩负着重返影像领域顶尖的使命。那么这次P70会带来哪些令人惊艳的创新呢?
根据目前爆料的消息来看,华为P70系列将推出三个版本,其中P70和P70 Pro采用了三角形的摄像头模组设计,而P70 Art则采用了与上一代P60 Art相似的不规则形状设计。这样的外观是否好看见仁见智,但辨识度绝对拉满。
更新动态
2024年11月14日
2024年11月14日
- 黑鸭子2003《聆听柔情HQCD》[日本版][WAV+CUE]
- 群星《奔赴!万人现场 第5期》[FLAC/分轨][587.07MB]
- 关大洲《国家宝藏 第四季原声音乐 关大洲作品》[320K/MP3][109.49MB]
- 关大洲《国家宝藏 第四季原声音乐 关大洲作品》[FLAC/分轨][527.23MB]
- LOL双城之战大乱斗什么时候更新 双城大乱斗上线更新时间介绍
- s14全球总决赛冠军皮肤有什么 2024T1冠军皮肤选择一览
- faker加里奥s14决赛什么出装 faker加里奥s14决赛出装介绍
- 《马里奥与路易吉RPG:兄弟齐航》Fami通34分:路易吉存在感拉满
- 数据挖掘者新发现:NS继任机型或支持4K分辨率
- 宫本茂谈任天堂未来:研发费用增加但注重创意与传承
- 陈小云.2000-餐厅综艺金榜【海丽唱片】【WAV+CUE】
- 卓文萱.2008-翻滚吧!蛋炒饭电视原声带【滚石】【FLAC分轨】
- 顺子.2001-AND.MUSICS.THERE【EMI百代】【WAV+CUE】
- 《三国志8重置版》劝降机制介绍
- 《欢欣森活》最新官方配置要求一览