[原创]百度访问统计柱状图表再次解密(5)(完结,全代码)
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>百度访问统计柱状图表</title>
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<meta name="Generator" content="EditPlus" />
<meta name="Author" content="天葵子" />
<meta name="Keywords" content="http://hi.baidu.com/xcb521,天葵子" />
<meta name="Description" content="http://hi.baidu.com/xcb521,天葵子" />
<style type="text/css">
<!--
/* 生成柱状图的CSS */
.stat td {
line-height:22px;
color:#333333;
font-size:14px
}
.chart {
position:relative;
margin:10px 0 30px 31px;
border:1px solid #B3B3DC
}
.chart div.bar, .chart div.barhl {
position:absolute;
background:#DCDCF4;
border:1px solid #B3B3DC;
line-height:0
}
.chart div.barhl {
background:#C2C2F4
}
.chart div.liney {
position:absolute;
border-top:1px dotted #B9B9B9;
line-height:0
}
.chart div.titx, .chart div.titxhl, .chart div.tity {
position:absolute;
color:#666;
font-size:9px;
font-family:Arial;
text-align:center;
white-space:nowrap
}
.chart div.titxhl {
color:#FF0000
}
.chart div.tity {
text-align:right
}
.chart div.hit {
position:absolute;
z-index:1000;
width:100px;
color:#666;
font-size:12px;
font-family:Arial
}
.stattop {
float:left;
margin-top:20px;
margin-right:14px;
padding:10px;
width:199px!important;
width:220px;
border:1px solid #CDCDCD
}
.stattop .list {
margin-top:6px
}
.stattop .list td {
height:20px
}
-->
</style>
<script language="javascript">
<!--
/*
eval(function(p, a, c, k, e, d)
{
e = function(c){return(c < a ? "" : e(parseInt(c / a))) + ((c = c % a) > 35 ? String.fromCharCode(c + 29) : c.toString(36))};
if( ! ''.replace(/^/, String))
{
while(c -- ) {d[e(c)] = k[c] || e(c)}
k = [function(e){return d[e]}];
e = function(){return'\\w+'};
c = 1
};
while(c -- )
{
if(k[c]){p = p.replace(new RegExp('\\b' + e(c) + '\\b', 'g'), k[c])}
}
return p
}('p w(E,D,A,C,B){5.R=8.14(E);5.o=D;5.d=A;5.r=(8.e)?C:(C-2);5.q=0;5.b=B+((8.e)?0:-2);5.x=5.d[0];5.O=5.d[5.d.c-1]}w.P.y=p(B){9 A=15.16(((B-5.x)*5.b/(5.O-5.x)))+((8.e)?2:0);s(A>5.b){A=5.b}17 A};w.P.18=p(){9 A=8.i("k");A.a="1a";A.6.z=5.b+"7";5.R.j(A);9 K=8.i("k");A.j(K);K.a="1b";9 J=0;Q(9 G=0;G<5.o.c;G+=2){9 B=5.y(5.o[G]);9 I=5.o[G+1];9 F=8.i("k");A.j(F);F.a="u";F.6.n=5.r+"7";F.6.z=B+"7";F.6.m=5.b-B-1+"7";F.6.g=(J-1)+"7";F.h="&v;";F.f=K;F.T=p(){5.a="V";5.f.6.L="";5.f.h=5.t.l(3,5.t.c);5.f.6.g=5.6.g;5.f.6.m=S(5.6.m)-S(5.f.19)+"7"};F.W=p(){5.a="u";5.f.6.L="Z"};9 E=8.i("k");A.j(E);E.6.n=5.r+"7";E.6.m=(8.e)?5.b:5.b+3+"7";9 C=I.10(".");F.t="u"+I.l(0,C)+"\\11"+I.l(C+1,I.c)+"\\12&v;&v;"+5.o[G];s(G%4==0){s((I.l(C+1,I.c)=="1"||I.l(C+1,I.c)=="2")){E.a="13";E.6.g=(J-4)+"7";E.h=I}N{E.a="M";E.6.g=(J-1)+"7";E.h=I.l(C+1,I.c)}}N{E.a="M";E.6.g=(J-1)+"7";E.h=""}J+=5.r+((8.e)?-1:1)}5.q=J+((8.e)?1:-1);A.6.n=5.q+"7";Q(9 G=0;G<5.d.c;G++){9 D=5.y(5.d[G]);s(G!=0&&G!=5.d.c-1){9 H=8.i("k");A.j(H);H.a="X";H.6.n=(5.q-((8.e)?1:-1))+"7";H.6.m=(5.b-D-1)+"7"}9 E=8.i("k");A.j(E);E.a="1c";E.6.n="Y";E.6.m=(5.b-D-2)+"7";E.6.g=-U+"7";E.h=5.d[G]}};', 62, 75, '|||||this|style|px|document|var|className|charth|length|yl|all|ohit|left|innerHTML|createElement|appendChild|div|substring|top|width|xl|function|chartw|barw|if|id|bar|nbsp|Chart|minpv|GetPVHeight|height||||||||||||display|titx|else|maxpv|prototype|for|parent|parseInt|onmouseover|42|barhl|onmouseout|liney|35px|none|indexOf|u6708|u65e5|titxhl|getElementById|Math|round|return|Create|offsetHeight|chart|hit|tity'.split('|'), 0,{})
);
下面是p参数格式化后的代码
p w(E, D, A, C, B)
{
5.R = 8.14(E);
5.o = D;
5.d = A;
5.r = (8.e) ? C : (C - 2);
5.q = 0;
5.b = B + ((8.e) ? 0 : - 2);
5.x = 5.d[0];
5.O = 5.d[5.d.c - 1]
}
w.P.y = p(B)
{
9 A = 15.16(((B - 5.x) * 5.b / (5.O - 5.x))) + ((8.e) ? 2 : 0);
s(A > 5.b)
{
A = 5.b
}
17 A
};
w.P.18 = p()
{
9 A = 8.i("k");
A.a = "1a";
A.6.z = 5.b + "7";
5.R.j(A);
9 K = 8.i("k");
A.j(K);
K.a = "1b";
9 J = 0;
Q(9 G = 0;
G < 5.o.c;
G += 2)
{
9 B = 5.y(5.o[G]);
9 I = 5.o[G + 1];
9 F = 8.i("k");
A.j(F);
F.a = "u";
F.6.n = 5.r + "7";
F.6.z = B + "7";
F.6.m = 5.b - B - 1 + "7";
F.6.g = (J - 1) + "7";
F.h = "&v;";
F.f = K;
F.T = p()
{
5.a = "V";
5.f.6.L = "";
5.f.h = 5.t.l(3, 5.t.c);
5.f.6.g = 5.6.g;
5.f.6.m = S(5.6.m) - S(5.f.19) + "7"
} ;
F.W = p()
{
5.a = "u";
5.f.6.L = "Z"
};
9 E = 8.i("k");
A.j(E);
E.6.n = 5.r + "7";
E.6.m = (8.e) ? 5.b : 5.b + 3 + "7";
9 C = I.10(".");
F.t = "u" + I.l(0, C) + "\\11" + I.l(C + 1, I.c) + "\\12&v;&v;" + 5.o[G];
s(G % 4 == 0)
{
s((I.l(C + 1, I.c) == "1" || I.l(C + 1, I.c) == "2"))
{
E.a = "13";
E.6.g = (J - 4) + "7";
E.h = I
}
N
{
E.a = "M";
E.6.g = (J - 1) + "7";
E.h = I.l(C + 1, I.c)
}
}
N
{
E.a = "M";
E.6.g = (J - 1) + "7";
E.h = ""
}
J += 5.r + ((8.e) ? - 1 : 1)
}
5.q = J + ((8.e) ? 1 : - 1);
A.6.n = 5.q + "7";
Q(9 G = 0;
G < 5.d.c;
G ++ )
{
9 D = 5.y(5.d[G]);
s(G != 0 && G != 5.d.c - 1)
{
9 H = 8.i("k");
A.j(H);
H.a = "X";
H.6.n = (5.q - ((8.e) ? 1 : - 1)) + "7";
H.6.m = (5.b - D - 1) + "7"
}
9 E = 8.i("k");
A.j(E);
E.a = "1c";
E.6.n = "Y";
E.6.m = (5.b - D - 2) + "7";
E.6.g = - U + "7";
E.h = 5.d[G]
}
};
*/
-->
</script>
<script type="text/javascript">
<!--
function Chart(E, D, A, C, B)
{
this.parent = document.getElementById(E);
this.xl = D;
this.yl = A;
this.barw = document.all ? C : C - 2;
this.chartw = 0;
this.charth = B + (document.all ? 0 : - 2);
this.minpv = this.yl[0];
this.maxpv = this.yl[this.yl.length - 1];
}
Chart.prototype.GetPVHeight = function (B)
{
var A = Math.round(((B - this.minpv) * this.charth / (this.maxpv - this.minpv))) + (document.all ? 2 : 0);
if (A > this.charth)
{
A = this.charth;
}
return A;
};
Chart.prototype.Create = function ()
{
var A = document.createElement("div");
A.className = "chart";
A.style.height = this.charth + "px";
this.parent.appendChild(A);
var K = document.createElement("div");
A.appendChild(K);
K.className = "hit";
var J = 0;
for (var G = 0; G < this.xl.length; G += 2)
{
var B = this.GetPVHeight(this.xl[G]);
var I = this.xl[G + 1];
var F = document.createElement("div");
A.appendChild(F);
F.className = "bar";
F.style.width = this.barw + "px";
F.style.height = B + "px";
F.style.top = this.charth - B - 1 + "px";
F.style.left = (J - 1) + "px";
F.innerHTML = " ";
F.ohit = K;
F.onmouseover = function ()
{
this.className = "barhl";
this.ohit.style.display = "";
this.ohit.innerHTML = this.id.substring(3, this.id.length);
this.ohit.style.left = this.style.left;
this.ohit.style.top = parseInt(this.style.top) - parseInt(this.ohit.offsetHeight) + "px";
};
F.onmouseout = function ()
{
this.className = "bar";
this.ohit.style.display = "none";
};
var E = document.createElement("div");
A.appendChild(E);
E.style.width = this.barw + "px";
E.style.top = document.all ? this.charth : this.charth + 3 + "px";
var C = I.indexOf(".");
F.id = "bar" + I.substring(0, C) + "\u6708" + I.substring(C + 1, I.length) + "\u65E5 " + this.xl[G];
if (G % 4 == 0)
{
if ((I.substring(C + 1, I.length) == "1" || I.substring(C + 1, I.length) == "2"))
{
E.className = "titxhl";
E.style.left = (J - 4) + "px";
E.innerHTML = I;
}
else
{
E.className = "titx";
E.style.left = (J - 1) + "px";
E.innerHTML = I.substring(C + 1, I.length);
}
}
else
{
E.className = "titx";
E.style.left = (J - 1) + "px";
E.innerHTML = "";
}
J += this.barw + (document.all ? - 1 : 1);
}
this.chartw = J + (document.all ? 1 : - 1);
A.style.width = this.chartw + "px";
for (var G = 0; G < this.yl.length; G ++ )
{
var D = this.GetPVHeight(this.yl[G]);
if (G != 0 && G != this.yl.length - 1)
{
var H = document.createElement("div");
A.appendChild(H);
H.className = "liney";
H.style.width = (this.chartw - (document.all ? 1 : - 1)) + "px";
H.style.top = (this.charth - D - 1) + "px";
}
var E = document.createElement("div");
A.appendChild(E);
E.className = "tity";
E.style.width = "35px";
E.style.top = (this.charth - D - 2) + "px";
E.style.left = "-42px";
E.innerHTML = this.yl[G];
}
};
-->
</script>
</head>
<body>
<div id="chart"></div>
<script type="text/javascript">
<!--
var k = [22,35,25,17,23,33,25,28,27,45,24,32,31,12,20,24,35,32,30,25,9,3,7,29,12,10,4,9,1,4,5,0,11,1,6,2,4,6,0,5,2,5,2,9,1,0,1,3,3,3,1,1,1,9,3,8,3,8,6,6,];
-->
</script>
<script>
<!--
try
{
if(k.length==0)
{
k=[0];
}
else
{
var f=k.toString();
if(f.charAt(f.length-1)==",")
{
f=f.substring(0,f.length-1);
}
k=f.split(",");//把f以","分解成数组!
}
}
catch(A)
{
}
if(k.length<60)
{
while(k.length<60)
{
k.push(0);//没有的变成0,设置60个的数组.以后的x.
}
}
var f=[];
for(var b=0;b<k.length;b++)
{
f[b]=k[b];//付值
}
f.sort(function(B,A)
{
return parseInt(B)-parseInt(A);//排序
}
);
var min=parseInt(f[0]);
var max=parseInt(f[f.length-1]);
var p=[];
var n=6;
var N=Math.ceil((max-min)/(n-1));
p[0]=min;
for(var b=1;b<n;b++)
{
p[b]=min+N*b;//大小排列六等分,以后的y做贮备
}
var _k="2007-4-25".split("-");//定义今天的日期
var q=new Date(parseInt(_k[0]),parseInt(_k[1])-1,parseInt(_k[2]));
var w=[];
for(var b=0;b<60;b++)
{
w.push((q.getMonth()+1)+"."+q.getDate());
q.setDate(q.getDate()-1);//计算日期,两个月60天
}
var x=[];
for(var b=60-1;b>=0;b--)
{
x.push(k[b]);//日期
x.push(w[b]);//数值
}
var y=p;
if(y.toString()==[0,0,0,0,0,0].toString())
{
y=[0,1,2,3,4,5];//y分六等从0到最高
}
new Chart("chart",x,y,10,152).Create();
//Chart(ID名,x轴,y轴,10,152)
-->
</script>
</body>
</html>
- 相关文章
- 查看评论:(0)
【已经有0位大神发现了看法】
- [原创]Plupload 中文插件(zh-cn.js简体语言),以及加载使用方法 2014-09-22
- [分享]Plupload多文件上传开发利器(部分中文注释) 2014-09-22
- [原创]关于飞飞cms2.0,飞飞播放器 Public/player/play.js破解问题 2013-03-21
- [原创]轻松解码类似eval(function(p,a,c,k,e,d){}))的JavaScript代码-eval破解 2013-03-21
- [原创]百度访问统计柱状图表再次解密(4)-eval破解 2013-03-21
- [原创]百度访问统计柱状图表再次解密(3)-eval破解 2013-03-21
- [原创]百度访问统计柱状图表再次解密(2)-eval破解 2013-03-21
- [原创]光线cms(gxcms)支持迅雷下载链接的修改 2012-08-25
- [原创]飞飞CMS(ppvod)播放页输出类似‘var pp_servername="百度影音$$$快播高清";’ 2012-08-18
- [原创]飞飞CMS(ppvod)播放页直接显示百度影音下载地址在html页面中 2012-08-18
发表评论: