基于脚本Tieba Advanced的贴吧回复小尾巴模版

作者: 扬帆大海 分类: 技术文章 发布时间: 2018-04-28 11:44

基于脚本Tieba Advanced的贴吧回复小尾巴模版


贴吧小黄历
function random(dayseed, indexseed){
var n=dayseed%11117;for(var i=0;i<100+indexseed;i++){n=n*n;n=n%11117;}return n;}
var today=new Date();var iday=today.getFullYear()*10000+(today.getMonth()+1)*100+today.getDate();
var good="",bad="";var weeks=["日","一","二","三","四","五","六"];
var directions=["北方","东北方","东方","东南方","南方","西南方","西方","西北方"];
var activities=[
{name:"收拾桌子",good:"整洁的书桌有利于工作效率",bad:"你会发现原来很好的东西找不到了"},
{name:"洗澡", good:"你几天没洗澡了?",bad:"会导致脑子进水",weekend:true},
{name:"锻炼一下身体",good:"",bad:"能量没消耗多少,吃得却更多",weekend:true},
{name:"抽烟",good:"抽烟有利于提神,增加思维敏捷",bad:"除非你活够了,死得早点没关系",weekend:true},
{name:"白天上线",good:"今天白天上线是安全的",bad:"可能导致灾难性后果"},
{name:"表白",good:"成功率很高",bad:"你很有可能会陷入泥潭"},
{name:"使用回帖小尾巴",good:"你看起来更有品位",bad:"别人会觉得你在装逼"},
{name:"和BOSS据理力争",good:"该出手时就出手",bad:"你不想混了?"},
{name:"恋爱",good:"你俩的关系会更进一步",bad:"你会犯下惹她生气的错误"},
{name:"面试",good:"面试官今天心情很好",bad:"面试官不爽,会拿你出气"},
{name:"乘坐公共交通工具",good:"今天人少,有座",bad:"今天地铁的大姨夫来了"},
{name:"申请加薪",good:"老板今天心情很好",bad:"公司正在考虑裁员"},
{name:"晚上加班",good:"晚上是你精神最好的时候",bad:"",weekend:true},
{name:"在妹子面前吹牛",good:"改善你矮穷挫的形象",bad:"会被识破",weekend:true},
{name:"撸管",good:"避免缓冲区溢出",bad:"强撸灰飞烟灭",weekend:true},
{name:"浏览苍老师等人的大作",good:"重拾对生活的信心",bad:"你会心神不宁",weekend:true},
{name:"照顾小师妹", good:"萌萌的妹子(☆_☆)",bad:"其实学弟才是你的真爱"},
{name:"关怀小师弟",good:"师弟才是我的菜",bad:""},
{name:"提交成果",good:"遇到问题的几率是最低的",bad:"你遇到的一大堆问题会让你觉得自己是不是时间穿越了"},
{name:"检查自己的成果",good:"满足感大大增强",bad:"怎么觉得自己最近一件人事都没做,白白浪费时间"},
{name:"开会",good:"写工作之余放松一下打个盹,有益健康",bad:"小心被扣屎盆子背黑锅"},
{name:"打LOL",good:"你将有如神助",bad:"你会被虐的很惨",weekend:true},
{name:"晚上上线",good:"晚上是程序员精神最好的时候",bad:"你白天已经筋疲力尽了"},
{name:"修复BUG",good:"你今天对BUG的嗅觉大大提高",bad:"新产生的BUG将比修复的更多"},
{name:"穿新衣服",good:"会被暗恋的人注意哦~",bad:"吃饭时绝对会把东西掉到上边"},
{name:"化妆",good:"",bad:""},
{name:"上微博",good:"今天发生的事不能错过",bad:"今天的微博充满负能量",weekend:true},
{name:"上AB站",good:"还需要理由吗?",bad:"满屏的兄贵我会说出来?",weekend:true}];
var specials=[];
var tools=["Eclipse写日记","MSOffice写日记","记事本写日记","Windows8","Linux","MacOS","IE","Android设备","iOS设备"];
var varNames=["jieguo","huodong","pay","expire","zhangdan","every","free","i1","a","virtual","ad","spider","mima","pass","ui"];
var drinks=["水","茶","红茶","绿茶","咖啡","奶茶","可乐","牛奶","豆奶","果汁","果味汽水","苏打水","运动饮料","酸奶","酒"];
function getTodayString(){
return "今天是"+today.getFullYear()+"年"+(today.getMonth()+1)+"月"+today.getDate()+"日 星期"+weeks[today.getDay()];}
function star(num){var result="";var i=0;while(i<num){result+="★";i++;}
while(i<5){result+="☆";i++;}return result;}
function pickTodaysLuck(){
var _activities=filter(activities);
var numGood = random(iday,98)%3+2;
var numBad=random(iday,87)%3+2;
var eventArr=pickRandomActivity(_activities,numGood+numBad);
var specialSize=pickSpecials();
for(var i=0;i<numGood;i++){addToGood(eventArr[i]);}
for(var i=0;i<numBad;i++){addToBad(eventArr[numGood+i]);}}
function filter(activities){var result=[];
if(isWeekend()){for(var i=0;i<activities.length;i++){if(activities[i].weekend){result.push(activities[i]);}}return result;}return activities;}function isWeekend(){return today.getDay()== 0||today.getDay()==6;}function pickSpecials(){var specialSize=[0,0];for(var i=0;i<specials.length;i++){var special=specials[i];if(iday==special.date){if(special.type=='good'){specialSize[0]++;addToGood({name: special.name, good: special.description});} else{specialSize[1]++;addToBad({name:special.name,bad:special.description});}}}return specialSize;}function pickRandomActivity(activities, size){var picked_events=pickRandom(activities, size);for(var i=0;i<picked_events.length;i++){picked_events[i]=parse(picked_events[i]);}return picked_events;}function pickRandom(array, size){var result=[];for(var i=0;i<array.length;i++){result.push(array[i]);}for(var j=0;j<array.length-size;j++){var index=random(iday,j)%result.length;result.splice(index,1);}return result;}function parse(event){var result={name:event.name,good:event.good,bad:event.bad};if(result.name.indexOf('%v')!=-1){result.name=result.name.replace('%v',varNames[random(iday,12)%varNames.length]);}if(result.name.indexOf('%t')!=-1){result.name=result.name.replace('%t',tools[random(iday,11)%tools.length]);}if (result.name.indexOf('%l')!=-1){result.name=result.name.replace('%l',(random(iday,12)%247+30).toString());}return result;}function addToGood(event){if(event.good)good=good+event.name+"("+event.good+');';else good=good+event.name+";";}function addToBad(event){if(event.bad)bad=bad+event.name+"("+event.bad+');';else bad=bad+event.name+";";}var out,date=getTodayString(),direction_value=directions[random(iday,2)%directions.length],drink_value=pickRandom(drinks,2).join(','),goddes_value=star(random(iday,6)%5+1);pickTodaysLuck();
Date.prototype.pattern=function(fmt) {
var o = {
"M+" : this.getMonth()+1, //月份
"d+" : this.getDate(), //日
"h+" : this.getHours(), //24小时制
"H+" : this.getHours(), //小时
"m+" : this.getMinutes(), //分
"s+" : this.getSeconds(), //秒
"q+" : Math.floor((this.getMonth()+3)/3), //季度
"S" : this.getMilliseconds() //毫秒
};
var week = {
"0" : "天",
"1" : "一",
"2" : "二",
"3" : "三",
"4" : "四",
"5" : "五",
"6" : "六"
};
if(/(y+)/.test(fmt)){
fmt=fmt.replace(RegExp.$1, (this.getFullYear()+"").substr(4 - RegExp.$1.length));
}
if(/(E+)/.test(fmt)){
fmt=fmt.replace(RegExp.$1, ((RegExp.$1.length>1) ? (RegExp.$1.length>2 ? "星期" : "周") : "")+week[this.getDay()+""]);
}
for(var k in o){
if(new RegExp("("+ k +")").test(fmt)){
fmt = fmt.replace(RegExp.$1, (RegExp.$1.length==1) ? (o[k]) : (("00"+ o[k]).substr((""+ o[k]).length)));
}
}
return fmt;
}
var time =new Date().pattern("今天是:yyyy年MM月dd日 EE ");
var CalendarData = new Array(100);
var madd = new Array(12);
var tgString = "甲乙丙丁戊己庚辛壬癸";
var dzString = "子丑寅卯辰巳午未申酉戌亥";
var numString = "一二三四五六七八九十";
var monString = "正二三四五六七八九十冬腊";
var weekString = "日一二三四五六";
var sx = "鼠牛虎兔龙蛇马羊猴鸡狗猪";
var cYear, cMonth, cDay, TheDate;
CalendarData = new Array(0xA4B, 0x5164B, 0x6A5, 0x6D4, 0x415B5,
0x2B6, 0x957, 0x2092F, 0x497, 0x60C96, 0xD4A, 0xEA5, 0x50DA9, 0x5AD,
0x2B6, 0x3126E, 0x92E, 0x7192D, 0xC95, 0xD4A, 0x61B4A, 0xB55, 0x56A,
0x4155B, 0x25D, 0x92D, 0x2192B, 0xA95, 0x71695, 0x6CA, 0xB55, 0x50AB5,
0x4DA, 0xA5B, 0x30A57, 0x52B, 0x8152A, 0xE95, 0x6AA, 0x615AA, 0xAB5,
0x4B6, 0x414AE, 0xA57, 0x526, 0x31D26, 0xD95, 0x70B55, 0x56A, 0x96D,
0x5095D, 0x4AD, 0xA4D, 0x41A4D, 0xD25, 0x81AA5, 0xB54, 0xB6A, 0x612DA,
0x95B, 0x49B, 0x41497, 0xA4B, 0xA164B, 0x6A5, 0x6D4, 0x615B4, 0xAB6,
0x957, 0x5092F, 0x497, 0x64B, 0x30D4A, 0xEA5, 0x80D65, 0x5AC, 0xAB6,
0x5126D, 0x92E, 0xC96, 0x41A95, 0xD4A, 0xDA5, 0x20B55, 0x56A, 0x7155B,
0x25D, 0x92D, 0x5192B, 0xA95, 0xB4A, 0x416AA, 0xAD5, 0x90AB5, 0x4BA,
0xA5B, 0x60A57, 0x52B, 0xA93, 0x40E95);
madd[0] = 0;
madd[1] = 31;
madd[2] = 59;
madd[3] = 90;
madd[4] = 120;
madd[5] = 151;
madd[6] = 181;
madd[7] = 212;
madd[8] = 243;
madd[9] = 273;
madd[10] = 304;
madd[11] = 334;
function GetBit(m, n) {
return (m >> n) & 1;
}
function e2c() {
TheDate = (arguments.length != 3) ? new Date() : new Date(arguments[0], arguments[1], arguments[2]);
var total, m, n, k;
var isEnd = false;
var tmp = TheDate.getYear();
if (tmp < 1900) {
tmp += 1900;
}
total = (tmp - 1921) * 365 + Math.floor((tmp - 1921) / 4) + madd[TheDate.getMonth()] + TheDate.getDate() - 38;
if (TheDate.getYear() % 4 == 0 && TheDate.getMonth() > 1) {
total++;
}
for (m = 0; ; m++) {
k = (CalendarData[m] < 0xfff) ? 11 : 12;
for (n = k; n >= 0; n--) {
if (total <= 29 + GetBit(CalendarData[m], n)) {
isEnd = true; break;
}
total = total - 29 - GetBit(CalendarData[m], n);
}
if (isEnd) break;
}
cYear = 1921 + m;
cMonth = k - n + 1;
cDay = total;
if (k == 12) {
if (cMonth == Math.floor(CalendarData[m] / 0x10000) + 1) {
cMonth = 1 - cMonth;
}
if (cMonth > Math.floor(CalendarData[m] / 0x10000) + 1) {
cMonth--;
}
}
}
function GetcDateString() {
var tmp = "";
tmp += tgString.charAt((cYear - 4) % 10);
tmp += dzString.charAt((cYear - 4) % 12);
tmp += "(";
tmp += sx.charAt((cYear - 4) % 12);
tmp += ")年 ";
if (cMonth < 1) {
tmp += "(闰)";
tmp += monString.charAt(-cMonth - 1);
} else {
tmp += monString.charAt(cMonth - 1);
}
tmp += "月";
tmp += (cDay < 11) ? "初" : ((cDay < 20) ? "十" : (cDay < 21) ? "二十" : ((cDay < 30) ? "廿" : "三十"));
if (cDay % 10 != 0 || cDay == 10) {
tmp += numString.charAt((cDay - 1) % 10);
}
return tmp;
}
function GetLunarDay(solarYear, solarMonth, solarDay) {
//solarYear = solarYear<1900?(1900+solarYear):solarYear;
if (solarYear < 1921 || solarYear > 2020) {
return "";
} else {
solarMonth = (parseInt(solarMonth) > 0) ? (solarMonth - 1) : 11;
e2c(solarYear, solarMonth, solarDay);
return GetcDateString();
}
}
var D = new Date();
var yy = D.getFullYear();
var mm = D.getMonth() + 1;
var dd = D.getDate();
var ww = D.getDay();
var ss = parseInt(D.getTime() / 1000);
if (yy < 100) yy = "19" + yy;
function GetCNDate() {
return GetLunarDay(yy, mm, dd);
}
var time = time + GetCNDate();
function red(t){return'<font color="#e10602">'+t+'</font>'}
function bold(t){return'<b>'+t+'</b>'}
e=PageData.user.user_name;
var huangli ="<b>"+red(e)+"的贴吧小黄历:<br></b>"+time+"。<br>宜:"+good+"<br>不宜:"+bad+"<br>座位朝向:面向"+direction_value+",打游戏,赢最多。<br>今日宜饮:"+drink_value+"。女神亲近指数:"+goddes_value;
huangli;
贴吧小黄历mini
//
/*
* 注意:本程序中的“随机”都是伪随机概念,以当前的天为种子。
*/
function random(dayseed, indexseed) {
var n = dayseed % 11117;
for (var i = 0; i < 100 + indexseed; i++) {
n = n * n;
n = n % 11117; // 11117 是个质数
}
return n;
}
var today = new Date();
var iday = today.getFullYear() * 10000 + (today.getMonth() + 1) * 100 + today.getDate();
var weeks = ["日","一","二","三","四","五","六"];
var directions = ["北方","东北方","东方","东南方","南方","西南方","西方","西北方"];
var drinks = ["水","茶","红茶","绿茶","咖啡","奶茶","可乐","牛奶","豆奶","果汁","果味汽水","苏打水","运动饮料","酸奶","酒"];
function getTodayString() {
return "今天是" + today.getFullYear() + "年" + (today.getMonth() + 1) + "月" + today.getDate() + "日 星期" + weeks[today.getDay()];
}
function star(num) {
var result = "";
var i = 0;
while (i < num) {
result += "★";
i++;
}
while(i < 5) {
result += "☆";
i++;
}
return result;
}
// 从数组中随机挑选 size 个
function pickRandom(array, size) {
var result = [];
for (var i = 0; i < array.length; i++) {
result.push(array[i]);
}
for (var j = 0; j < array.length - size; j++) {
var index = random(iday, j) % result.length;
result.splice(index, 1);
}
return result;
}
var out, date = getTodayString(), direction_value = directions[random(iday, 2) % directions.length], drink_value = pickRandom(drinks,2).join(','), goddes_value = star(random(iday, 6) % 5 + 1);
Date.prototype.pattern=function(fmt) {
var o = {
"M+" : this.getMonth()+1, //月份
"d+" : this.getDate(), //日
"h+" : this.getHours(), //24小时制
"H+" : this.getHours(), //小时
"m+" : this.getMinutes(), //分
"s+" : this.getSeconds(), //秒
"q+" : Math.floor((this.getMonth()+3)/3), //季度
"S" : this.getMilliseconds() //毫秒
};
var week = {
"0" : "天",
"1" : "一",
"2" : "二",
"3" : "三",
"4" : "四",
"5" : "五",
"6" : "六"
};
if(/(y+)/.test(fmt)){
fmt=fmt.replace(RegExp.$1, (this.getFullYear()+"").substr(4 - RegExp.$1.length));
}
if(/(E+)/.test(fmt)){
fmt=fmt.replace(RegExp.$1, ((RegExp.$1.length>1) ? (RegExp.$1.length>2 ? "星期" : "周") : "")+week[this.getDay()+""]);
}
for(var k in o){
if(new RegExp("("+ k +")").test(fmt)){
fmt = fmt.replace(RegExp.$1, (RegExp.$1.length==1) ? (o[k]) : (("00"+ o[k]).substr((""+ o[k]).length)));
}
}
return fmt;
}
var data =new Date().pattern("今天是yyyy年MM月dd日 EEE");
var time =new Date().pattern("hh时mm分ss秒S毫秒");
var CalendarData = new Array(100);
var madd = new Array(12);
var tgString = "甲乙丙丁戊己庚辛壬癸";
var dzString = "子丑寅卯辰巳午未申酉戌亥";
var numString = "一二三四五六七八九十";
var monString = "正二三四五六七八九十冬腊";
var weekString = "日一二三四五六";
var sx = "鼠牛虎兔龙蛇马羊猴鸡狗猪";
var cYear, cMonth, cDay, TheDate;
CalendarData = new Array(0xA4B, 0x5164B, 0x6A5, 0x6D4, 0x415B5,
0x2B6, 0x957, 0x2092F, 0x497, 0x60C96, 0xD4A, 0xEA5, 0x50DA9, 0x5AD,
0x2B6, 0x3126E, 0x92E, 0x7192D, 0xC95, 0xD4A, 0x61B4A, 0xB55, 0x56A,
0x4155B, 0x25D, 0x92D, 0x2192B, 0xA95, 0x71695, 0x6CA, 0xB55, 0x50AB5,
0x4DA, 0xA5B, 0x30A57, 0x52B, 0x8152A, 0xE95, 0x6AA, 0x615AA, 0xAB5,
0x4B6, 0x414AE, 0xA57, 0x526, 0x31D26, 0xD95, 0x70B55, 0x56A, 0x96D,
0x5095D, 0x4AD, 0xA4D, 0x41A4D, 0xD25, 0x81AA5, 0xB54, 0xB6A, 0x612DA,
0x95B, 0x49B, 0x41497, 0xA4B, 0xA164B, 0x6A5, 0x6D4, 0x615B4, 0xAB6,
0x957, 0x5092F, 0x497, 0x64B, 0x30D4A, 0xEA5, 0x80D65, 0x5AC, 0xAB6,
0x5126D, 0x92E, 0xC96, 0x41A95, 0xD4A, 0xDA5, 0x20B55, 0x56A, 0x7155B,
0x25D, 0x92D, 0x5192B, 0xA95, 0xB4A, 0x416AA, 0xAD5, 0x90AB5, 0x4BA,
0xA5B, 0x60A57, 0x52B, 0xA93, 0x40E95);
madd[0] = 0;
madd[1] = 31;
madd[2] = 59;
madd[3] = 90;
madd[4] = 120;
madd[5] = 151;
madd[6] = 181;
madd[7] = 212;
madd[8] = 243;
madd[9] = 273;
madd[10] = 304;
madd[11] = 334;
function GetBit(m, n) {
return (m >> n) & 1;
}
function e2c() {
TheDate = (arguments.length != 3) ? new Date() : new Date(arguments[0], arguments[1], arguments[2]);
var total, m, n, k;
var isEnd = false;
var tmp = TheDate.getYear();
if (tmp < 1900) {
tmp += 1900;
}
total = (tmp - 1921) * 365 + Math.floor((tmp - 1921) / 4) + madd[TheDate.getMonth()] + TheDate.getDate() - 38;
if (TheDate.getYear() % 4 == 0 && TheDate.getMonth() > 1) {
total++;
}
for (m = 0; ; m++) {
k = (CalendarData[m] < 0xfff) ? 11 : 12;
for (n = k; n >= 0; n--) {
if (total <= 29 + GetBit(CalendarData[m], n)) {
isEnd = true; break;
}
total = total - 29 - GetBit(CalendarData[m], n);
}
if (isEnd) break;
}
cYear = 1921 + m;
cMonth = k - n + 1;
cDay = total;
if (k == 12) {
if (cMonth == Math.floor(CalendarData[m] / 0x10000) + 1) {
cMonth = 1 - cMonth;
}
if (cMonth > Math.floor(CalendarData[m] / 0x10000) + 1) {
cMonth--;
}
}
}
function GetcDateString() {
var tmp = "";
tmp += tgString.charAt((cYear - 4) % 10);
tmp += dzString.charAt((cYear - 4) % 12);
tmp += "(";
tmp += sx.charAt((cYear - 4) % 12);
tmp += ")年 ";
if (cMonth < 1) {
tmp += "(闰)";
tmp += monString.charAt(-cMonth - 1);
} else {
tmp += monString.charAt(cMonth - 1);
}
tmp += "月";
tmp += (cDay < 11) ? "初" : ((cDay < 20) ? "十" : (cDay < 21) ? "二十" : ((cDay < 30) ? "廿" : "三十"));
if (cDay % 10 != 0 || cDay == 10) {
tmp += numString.charAt((cDay - 1) % 10);
}
return tmp;
}
function GetLunarDay(solarYear, solarMonth, solarDay) {
//solarYear = solarYear<1900?(1900+solarYear):solarYear;
if (solarYear < 1921 || solarYear > 2020) {
return "";
} else {
solarMonth = (parseInt(solarMonth) > 0) ? (solarMonth - 1) : 11;
e2c(solarYear, solarMonth, solarDay);
return GetcDateString();
}
}
//调用
var D = new Date();
var yy = D.getFullYear();
var mm = D.getMonth() + 1;
var dd = D.getDate();
var ww = D.getDay();
var ss = parseInt(D.getTime() / 1000);
if (yy < 100) yy = "19" + yy;
function GetCNDate() {
return GetLunarDay(yy, mm, dd);
}
var data = data + GetCNDate();
e=PageData.user.user_name;
function red(t){return'<font color="#e10602">'+t+'</font>'}
function bold(t){return'<b>'+t+'</b>'}
out = "<b>"+red(e)+"的贴吧小黄历:</b><br>" +data + "。<br>座位朝向:面向" + direction_value + "玩游戏,赢最多。<br>今日宜饮:" + drink_value + "。<br>女神亲近指数:" + goddes_value+"<br>于"+time+"发布"+"<br>";
楼上侦测
Date.prototype.pattern=function(fmt) {
var o = {
"M+" : this.getMonth()+1, //月份
"d+" : this.getDate(), //日
//"h+" : this.getHours()%12 == 0 ? 12 : this.getHours()%12, //12小时制
"h+" : this.getHours(), //24小时制
"H+" : this.getHours(), //小时
"m+" : this.getMinutes(), //分
"s+" : this.getSeconds(), //秒
"q+" : Math.floor((this.getMonth()+3)/3), //季度
"S" : this.getMilliseconds() //毫秒
};
var week = {
"0" : "天",
"1" : "一",
"2" : "二",
"3" : "三",
"4" : "四",
"5" : "五",
"6" : "六"
};
if(/(y+)/.test(fmt)){
fmt=fmt.replace(RegExp.$1, (this.getFullYear()+"").substr(4 - RegExp.$1.length));
}
if(/(E+)/.test(fmt)){
fmt=fmt.replace(RegExp.$1, ((RegExp.$1.length>1) ? (RegExp.$1.length>2 ? "星期" : "周") : "")+week[this.getDay()+""]);
}
for(var k in o){
if(new RegExp("("+ k +")").test(fmt)){
fmt = fmt.replace(RegExp.$1, (RegExp.$1.length==1) ? (o[k]) : (("00"+ o[k]).substr((""+ o[k]).length)));
}
}
return fmt;
}
var time =new Date().pattern("yyyy年MM月dd日 hh时mm分ss秒");
var a=$('.l_post'),x;
if(a[0])
{var b=a.data('field').author.user_name,
c=a.last().data('field').author.user_name,
d=$('.tP')[0],
e=PageData.user.user_name;
x=d?"居然不是首页,都怪楼上的【<font color=\"#e10602\"><b>" + c + "</b></font>】!不开心…(╯°Д°)╯(┻━┻<br>【<font color=\"#e10602\"><b>"+e+"</b></font>】于:"+time+"回复本帖"+"<br>":
b==e?"楼主【<font color=\"#e10602\"><b>" + b + "</b></font>】的帖子写得真好,不愧是我自己的帖子<br>✎------在"+time+"为自己顶帖"+"<br>":
//这里的-----可以配合自己的ID长度增减一下以备排版整齐
c==e?"刚才我在楼上的话没说完,我再补充几句吧<br>【<font color=\"#e10602\"><b>"+e+"</b></font>】于:"+time+"回复本帖"+"<br>":
(a.length>1?("楼主【<font color=\"#e10602\"><b>" +b+ " </b></font>】又来水经验了,"+(b==c?"居然还在楼上自挽了一下_(:зゝ∠)_<br>【<font color=\"#e10602\"><b>"+e+"</b></font>】在"+time+"为楼主【<font color=\"#e10602\"><b>"+b+"</b></font>】顶帖"+"<br>":
(c==PageData.user.name?"那么我还是送他一点经验吧o( ̄ˇ ̄)o【<br><font color=\"#e10602\"><b>"+e+"</b></font>】在"+time+"为楼主【<font color=\"#e10602\"><b>"+b+"</b></font>】顶帖"+"<br>":
"楼上这个【<font color=\"#e10602\"><b>" + c + " </b></font> 】居然还帮他水了一贴!<br>【<font color=\"#e10602\"><b>"+e+"</b></font>】于:"+time+"为楼主【<font color=\"#e10602\"><b>"+b+"</b></font>】顶帖"+"<br>"))):
"难道我是二楼哎?楼主【<font color=\"#e10602\"><b>" + b + "</b></font> 】要谢谢我哦!( ̄▽ ̄)<br>✎-----【<font color=\"#e10602\"><b>"+e+"</b></font>】在"+time+"为楼主【<font color=\"#e10602\"><b>"+b+"</b></font>】顶帖"+"<br>")}
else x='俺妥妥的水了一贴<br>';
英文基本信息
"——时间:"+Date()+"<br>——系统:"+navigator.userAgent+"<br/>——地址:"+location.href
吧务侦测
var out,a={},w=[],c,p,u=PageData.user.name,un='我自己_(:зゝ∠)_';
if(PageData.thread){
$('.l_post').each(function(){
c=$(this).data('field').author;
if(!a[c.user_name]&&c.bawu){a[c.user_name]=c.ucer_name;w.push(c.user_name==u?un:c.user_name)}
});
p=PageData.pager.total_page>1?('第'+PageData.pager.cur_page+'页'):'楼上';
out=!w.length?(p+'暂未发现吧务,大家可以放心水贴(੭ु≥▽≤)੭ु'):(p+'共侦测到吧务'+w.length+'只,'+(w.length==1?'TA':'TA们')+'是<b><font color="#e10602"> '+w.join('、')+' </font> </b>想要水贴的注意哦~');
}
else out='假装吧务不在,俺先光明正大地水一贴再说╮( ̄▽ ̄")╭';
Date.prototype.pattern=function(fmt) {
var o = {
"M+" : this.getMonth()+1, //月份
"d+" : this.getDate(), //日
//"h+" : this.getHours()%12 == 0 ? 12 : this.getHours()%12, //12小时制
"h+" : this.getHours(), //24小时制
"H+" : this.getHours(), //小时
"m+" : this.getMinutes(), //分
"s+" : this.getSeconds(), //秒
"q+" : Math.floor((this.getMonth()+3)/3), //季度
"S" : this.getMilliseconds() //毫秒
};
var week = {
"0" : "天",
"1" : "一",
"2" : "二",
"3" : "三",
"4" : "四",
"5" : "五",
"6" : "六"
};
if(/(y+)/.test(fmt)){
fmt=fmt.replace(RegExp.$1, (this.getFullYear()+"").substr(4 - RegExp.$1.length));
}
if(/(E+)/.test(fmt)){
fmt=fmt.replace(RegExp.$1, ((RegExp.$1.length>1) ? (RegExp.$1.length>2 ? "星期" : "周") : "")+week[this.getDay()+""]);
}
for(var k in o){
if(new RegExp("("+ k +")").test(fmt)){
fmt = fmt.replace(RegExp.$1, (RegExp.$1.length==1) ? (o[k]) : (("00"+ o[k]).substr((""+ o[k]).length)));
}
}
return fmt;
}
var time =new Date().pattern("yyyy年MM月dd日 hh时mm分ss秒");
out='截止到'+time+'<br>'+out;
肉味尾巴
Date.prototype.pattern=function(fmt) {
var o = {
"M+" : this.getMonth()+1, //月份
"d+" : this.getDate(), //日
//"h+" : this.getHours()%12 == 0 ? 12 : this.getHours()%12, //12小时制
"h+" : this.getHours(), //24小时制
"H+" : this.getHours(), //小时
"m+" : this.getMinutes(), //分
"s+" : this.getSeconds(), //秒
"q+" : Math.floor((this.getMonth()+3)/3), //季度
"S" : this.getMilliseconds() //毫秒
};
var week = {
"0" : "天",
"1" : "一",
"2" : "二",
"3" : "三",
"4" : "四",
"5" : "五",
"6" : "六"
};
if(/(y+)/.test(fmt)){
fmt=fmt.replace(RegExp.$1, (this.getFullYear()+"").substr(4 - RegExp.$1.length));
}
if(/(E+)/.test(fmt)){
fmt=fmt.replace(RegExp.$1, ((RegExp.$1.length>1) ? (RegExp.$1.length>2 ? "星期" : "周") : "")+week[this.getDay()+""]);
}
for(var k in o){
if(new RegExp("("+ k +")").test(fmt)){
fmt = fmt.replace(RegExp.$1, (RegExp.$1.length==1) ? (o[k]) : (("00"+ o[k]).substr((""+ o[k]).length)));
}
}
return fmt;
}
var time =new Date().pattern("yyyy年MM月dd日 hh时mm分ss秒");
var a,b,c,d;if(a=$('.tP')[0])b='第'+a.innerHTML+'页';else b='楼上';a=$('.l_post');var v={};b+='都是纯天然的,有:';for(var i=0;i<a.length;i++){c=a.find('.p_author_name')[i].text.substr(0,2);if(v[c]!=1){b+=c+'肉味、';v[c]=1;}}b=b.substr(0,b.length-1);b='(^U^)ノ~'+b+',各种嘎嘣脆';
var e=$('.l_post'),x;
if(a[0])
{var e=a.data('field').author.user_name;}
b+'<br><b><font color=\"#e10602\">'+PageData.user.user_name+'</font></b> 于'+time+' 为楼主 <b><font color=\"#e10602\">'+e+'</font></b> 顶贴';
系统信息侦测
userAgent=window.navigator.userAgent.toLowerCase();
if(userAgent.indexOf("windows nt 10")>=1){var S=" Windows 10";}
else
if(userAgent.indexOf("windows nt 6.4")>=1){var S=" Windows 10预览版";}
else
if(userAgent.indexOf("windows nt 6.3")>=1){var S=" Windows 8.1";}
else
if(userAgent.indexOf("windows nt 6.2")>=1){var S=" Windows 8";}
else
if(userAgent.indexOf("windows nt 6.1")>=1){var S=" Windows 7";}
else
if(userAgent.indexOf("windows nt 6.0")>=1){var S=" Windows Vista";}
else
if(userAgent.indexOf("windows nt 5.1")>=1){var S=" Windows XP";}
else
if(userAgent.indexOf("windows nt 5.2")>=1){var S=" Windows 2003";}
else
if(userAgent.indexOf("linux")>=1){var S=" Linux";}
else
if(userAgent.indexOf("mac")>=1){var S=" MacOS";}
else
var S=" 非主流";
var OS =S+'系统';
var weblogo="";
var fxlogo='<img class="BDE_Image" src="http://imgsa.baidu.com/forum/w%3D580/sign=a94be94c4a166d223877159c76220945/c4a83887e950352a3aec4b8f5a43fbf2b3118b00.jpg" width="32" height="32"></img>';
var chlogo='<img class="BDE_Image" src="http://imgsa.baidu.com/forum/w%3D580/sign=19866130e050352ab16125006342fb1a/476399504fc2d562a640be6aee1190ef77c66c4c.jpg" width="32" height="32"></img>';
var ielogo='<img class="BDE_Image" src="http://imgsa.baidu.com/forum/w%3D580/sign=e1294b8f5a43fbf2c52ca62b807fca1e/7b6ee7dde71190ef51b3fc58c71b9d16fcfa604c.jpg" width="32" height="32"></img>';
var oplogo='<img class="BDE_Image" src="http://imgsa.baidu.com/forum/w%3D580/sign=aa81bca699ef76c6d0d2fb23ad17fdf6/cda1808ba61ea8d3b2431a839e0a304e241f58ab.jpg" width="32" height="32"></img>';
if ((userAgent.indexOf('msie') >= 0) && (navigator.userAgent.indexOf('microsoft internet explorer') < 0)){
weblogo=ielogo;
var Findex=userAgent.indexOf("msie");
var versionName=userAgent.substr(Findex+"msie ".length,4);
var Browser=" 简洁华丽的 MSIE "+versionName+" 浏览器"+weblogo;
}
else
if (userAgent.indexOf('firefox') >= 0){
weblogo=fxlogo;
var Findex=userAgent.indexOf("firefox/");
var versionName=userAgent.substr(Findex+"firefox/".length,4);
var Browser=" “耐操”的 Firefox"+versionName+" 浏览器"+weblogo;
}
else
if (userAgent.indexOf('opera') >= 0){
weblogo=oplogo;
var Findex=userAgent.indexOf("opera ");
var versionName=userAgent.substr(Findex+"opera ".length,4);
var Browser="“廉颇老矣”的 Opera"+versionName+" 浏览器"+weblogo;
}
else
if (userAgent.indexOf('chrome') >= 0){
weblogo=chlogo;
var Findex=userAgent.indexOf("chrome/");
var versionName=userAgent.substr(Findex+"chrome/".length,4);
var Browser="“简便之至”的 Chrome"+versionName+" 浏览器"+weblogo;
}
else
{var Browser=" “非主流”浏览器";}
Browser='<b>'+Browser+'</b>'
" <br>本消息通过<b>"+OS+"</b>上"+Browser+"发送"

发表回复

您的电子邮箱地址不会被公开。 必填项已用*标注

此站点使用Akismet来减少垃圾评论。了解我们如何处理您的评论数据