
var SPLITTER_RECORD		= "{\\r\\r*\\r\\r}";
var SPLITTER_FIELD		= "{\\r*\\r}";


/////////////////////////////////////////字符串操作///////////////////////////
String.prototype.trim= function()  
{  
    // 用正则表达式将前后空格  
    // 用空字符串替代。  
    return this.replace(/(^\s*)|(\s*$)/g, "");  
}

//定义一个字符stringbuilder类
function StringBuilder()
        {
            this.arrStr = new Array();
        }
        StringBuilder.prototype.Append = function(strVelue)
        {
            this.arrStr.push(strVelue);
        }
        
        StringBuilder.prototype.toString = function()
        {
               
             return this.arrStr.join("");

         }
         //html编码////////////
         function HtmlEncode(text) {
             return text.replace(/&/g, '&amp').replace(/\"/g, '&quot;').replace(/</g, '&lt;').replace(/>/g, '&gt;');
         }
         //html解码
         function HtmlDecode(text) {
             
             return text.replace(/&amp;/g, '&').replace(/&quot;/g, '\"').replace(/&lt;/g, '<').replace(/&gt;/g, '>').replace(/\n/g, '<br>').replace(/\t/g, '<br>').replace(/\r/g, '');
             
         }
         
         function GetJsPram(jsid, strArg) {
             var str = document.getElementById(jsid).src;
             var _url = str + "&";
             var regex = new RegExp("(\\?|\\&)" + strArg + "=([^\\&\\?]*)\\&", "gi");
             if (!regex.test(_url)) return "";
             var arr = regex.exec(_url);
             return (RegExp.$2);
         }
         //获取url?号后的参数
         function GetUrlParams(ParamName)
         {
            var URLParams = new Object() ;
            var aParams = document.location.search.substr(1).split('&') ;
            for (i=0 ; i < aParams.length ; i++)
            {
	            var aParam = aParams[i].split('=') ;
	            URLParams[aParam[0]] = aParam[1] ;
            }
            
            return URLParams[ParamName];
         }

         function cut_string(strString, nLength) {
             var nTheLength = 0;
             for (var nIndex = 0; nIndex < strString.length; nIndex++) {
                 if (strString.charCodeAt(nIndex) > 255)
                     nTheLength += 2;
                 else
                     nTheLength += 1;
                 if (nTheLength >= nLength)
                     break;
             }
             var strResult = strString.substr(0, nIndex);
             if (strResult.length < strString.length)
                 strResult = strResult + "...";
             return strResult;
         }
         function cut_str_mid(strString, iLength) {
             if (strString.length > iLength) {
                 var iLength2 = parseInt(iLength / 2);
                 var strtemp1 = strString.substr(0, iLength2);
                 var strtemp2 = strString.substr(strString.length - iLength2);
                 strString = "";
                 strString = strtemp1 + "  ...  " + strtemp2;
             }
             return strString;
         }
         //从url中获取文件类型
         function get_type_of_url(sUrl) {
             var strType = "";
             if (sUrl != "") {
                 var iLastIndex = sUrl.lastIndexOf(".") + 1;
                 strType = sUrl.substring(iLastIndex, sUrl.length);

             }
             if (strType.length > 5) return "";
             return strType;
         }
         //复制文本
         function CopyObText(thisobj) {
             var rng = document.body.createTextRange();
             rng.moveToElementText(thisobj);
             rng.scrollIntoView();
             rng.select();
             clipboardData.setData('text', thisobj.innerText);
             alert("复制成功!!");
         }
         function JsonToObj(sJson)
        { 
            
            return eval("({"+sJson+"})");  
        }
        
//////////////////////////////////数组操作///////////////////////
        
//为数组添加一个删除指定索引项  
    Array.prototype.removecount = 0;     
     Array.prototype.removedAt = function(index)
        {
            if(isNaN(index)||index<0)
            {
                return ;
            }
            if(index<this.length)
            {
                this.splice(index,1);
                this.removecount++;
            }            
            
        }
//为数组添加一个新办法:删除重复数组项。
Array.prototype.unique = function()
{
   var tempArray=this.slice(0);//复制数组到临时数组
     for(var i=0;i<tempArray.length;i++)
     {
          for(var j=i+1;j<tempArray.length;)
          {
           if(tempArray[j].toString()==tempArray[i].toString())
           //后面的元素若和待比较的相同，则删除并计数；
           //删除后，后面的元素会自动提前，所以指针j不移动
           {
            tempArray.splice(j,1);
           }
           else
           {
            j++;
           }
           //不同，则指针移动
      }
     }
 return tempArray;
}


//从指定值获取数组索引,如有重复值，只取第一个索引
Array.prototype.GetIndex = function(obj)
        {
           var tempArray=this.slice(0);//复制数组到临时数组
           var iIndex = 0;
             for(var i=0;i<tempArray.length;i++)
             {              
               if(tempArray[i].Equals(obj))
               {   
                   iIndex = i;
                   break;
               }
             }
            
           return iIndex;
        }
  //为数组添加一个新办法:转换成JSON代码,iarr为数组维数,只支持1,2维。
  Array.prototype.toJson = function(iarr)
        {
            var strJson = "";
            var sbJson = new StringBuilder();
            if(iarr==1)
            {
                strJson = this.join("\",\""); 
                 strJson = "[\""+strJson+"\"]";
            }
            else if(iarr==2)
            {
                for(var i=0;i<this.length;i++)
                {
                    
                    sbJson.append("\"],[\""+this[i].join("\",\""));
                }
                
                strJson = sbJson.toString();
                strJson = strJson.replace("\"],","["); 
                strJson = strJson+"\"]]";
            }
          
          return strJson;
          
        }


//table 常用操作,iTop为保留顶项

function clear_table_rows(obTable,iTop)
{
	  var delRows=obTable.rows.length;	  
	 for(i=iTop;i<delRows;i++)	obTable.deleteRow(1); 
  }

//////////////////////////////////////ajax操作////////////////
//GET办法运行异步http请求
function run_ajax_async(url,postdata,backfun)
{
				
				$.ajax({
				  type: "get",
				  url: url,
				  data: postdata,   
				  dataType: "html",
				  success: function(msg)
				  {		
				  	if(backfun!=null)backfun(msg);
					
				  },
				  async: true
				})	
}
//GET/post办法运行异步http请求
function run_ajax_async_type(url,postdata,backfun,type)
{
				$.ajax({
				  type: type,
				  url: url,
				  data: postdata,   
				  dataType: "html",
				  success: function(msg)
				  {		
				  	if(backfun!=null)backfun(msg);
					
				  },
				  async: true
				})	
}
//运行同步http请求
function run_ajax_unasync(url)
{
	var html = $.ajax({
				 url: url,
				 async: false
				}).responseText;
	
	return html;
}
//GET办法运行异步http请求 javascript
function run_ajax_async_js(url,postdata,backfun)
{
				
				$.ajax({
				  type: "get",
				  url: url,
				  data: postdata,   
				  dataType: "script",
				  success: function(msg)
				  {		
				  	if(backfun!=null)backfun(msg);
					
				  },
				  async: true
				})	
}
//获取json数据sPath为文件名称与路径
function get_json(sPath,fun)
{
     $.getJSON(sPath, 
                fun
        );
}

function JsonToObj(sJson)
{ 
    
    return eval("({"+sJson+"})");  
}
//批量操作----------------------------------------

//全选
function on_checkall(ob)
{    
   $(ob).find("input[@type='checkbox']").each(		
		function(i)
		{
			this.checked = true;
		}
		);
}
//反向选取
function on_checkback(ob)
{
  $(ob).find("input[@type='checkbox']").each(		
		function(i)
		{
			if(this.checked)
			{
				this.checked = false;
			}
			else
			{
				this.checked = true;
			}
		}
		);
}

//反向选取
function on_check(ob,obchk)
{
  $(ob).find("input[@type='checkbox']").each(		
		function(i)
		{
			this.checked = obchk.checked;
		}
		);
}

  //获取选择的radio值
 function get_checkedradio_value(radios)
 {
	 for(var i=0;i<=radios.length;i++)
	 {
		 if(radios[i].checked) return radios[i].value ;
	 }
	 return null;
 }

 //获取下拉列表项
 function get_selected_value(ob)
 {
	 
	return ob.options[ob.selectedIndex].value;
}
//设计一个通用的Tags类
function CustomTags()
{
    //tags列表的上一级元素名称
    this.ParentObjName = "";
    this.SubObj = "";
    this.CurrentClassName = "";
    this.ClassName = "";
    this.fun = null;
    this.BoxList = [];
    if (typeof CustomTags._initialized == "undefined") 
    {
        CustomTags.prototype.InitOnclickInTags = function() 
        {
            var tags = this.GetTags();
            
            if(tags!=null&&tags.length>0)
            {   
                for(var i =0;i<tags.length;i++)
                {
                    tags[i].onclick = this.fun;//function(){ };
                    if(tags[i].name!=undefined&&tags[i].name!=null)
                        this.BoxList.push(tags[i].name);
                }
            }
        }
        CustomTags.prototype.OnclickTags = function(obj) 
        {
            
            var tags = this.GetTags();
            
            if(tags!=null&&tags.length>0)
            {   
                for(var i =0;i<tags.length;i++)
                { 
                    
                  if(tags[i]!=obj)
                  {
                    tags[i].className = this.ClassName;
                  }
                }
             }
             obj.className=this.CurrentClassName;
             
             if(this.BoxList.length>0)
             {
                for(var i =0;i<tags.length;i++)
                { 
                    
                  if(this.BoxList[i]!=null)
                  {
                      $("#"+this.BoxList[i]).hide();
                  }
                }
               $("#"+obj.name).show(); 
                
                
             }
        }
        CustomTags.prototype.InitOnclick = function(index)
        {
            var tags = this.GetTags();
            var obj = tags[index];
            if(obj=="undefined"||obj==null)
            {
                alert("没有找到对应的Tag");
                return;
            }
            $(obj).click(); 
            
            
        }
        CustomTags.prototype.GetTags = function() 
        {
        
             var Tags = [];
                $("#"+this.ParentObjName).find(this.SubObj).each(
                
                    function(i)
		            {
		               Tags.push(this);
		            }
                );
               return Tags; 
        }
    }
    CustomTags._initialized = true;
    
}
 // 实现一个类似委托特性的类(js里面function可以相当于一个类)，add方法相当于运算符"+"重载,run相当执行委托链上所有的回调函数

function delegate(func){
    this.arr = new Array(); // 回调函数数组
    this.add = function(func){
        this.arr[this.arr.length] = func;
    };
    this.run = function(){
        for(var i=0;i<this.arr.length;i++){
            var func = this.arr[i];
            if(typeof func == "function"){
                func(); // 遍历所有方法以及调用
            }
        }
    }
    this.add(func);
}

  
//窗口操作----------------------------------------------
function OpenBrowse(obid,pram,listtype)
{
    var result = ShowDialog(IISPath+"FileManager/filelist.aspx?t="+listtype+"&uppram="+pram.trim(), window,600,500);
	if ((result) && (result != ""))
	{
	    document.getElementById(obid).value = result;
		
	}
}
//打开上传对话框
function OpenUpload(obid, pram) {
   
    var result = ShowDialog(IISPath+"FileManager/UploadSingle.aspx?ut=1&pram="+pram.trim(), window,390,130);
	if ((result) && (result != ""))
	{
	    document.getElementById(obid).value = result;
		
	}
    //ShowLessDialog("/FileManager/UploadSingle.aspx?ucid="+obid+"&pram="+pram,380, 110);
}
// 显示无模式对话框
function ShowDialog(url, object, width, height) {	
	
	var cursor = document.body.style.cursor;
	document.body.style.cursor = "wait";
	var result = window.showModalDialog(url, object, "status:no; center:yes; help:no; minimize:no; maximize:no; scroll:no; border:thin; statusbar:no; dialogWidth:" + width + "px; dialogHeight:" + height + "px");
	document.body.style.cursor = cursor;
	return result;
	
}


// 显示模式对话框
function ShowLessDialog(url, width, height) {
	
	var result = showModelessDialog(url, window, "dialogWidth:" + width + "px;dialogHeight:" + height + "px;help:no;scroll:no;status:no");
	if ((result) && (result != ""))
	{
	    alert(result)
	}
}

function getposition(obj)
{
	var r = new Array();
	r['x'] = obj.offsetLeft;
	r['y'] = obj.offsetTop;
	while(obj = obj.offsetParent)
	{
		r['x'] += obj.offsetLeft;
		r['y'] += obj.offsetTop;
	}
	return r;
}

//显示提示层
function showhintinfo(obj, objleftoffset,objtopoffset, title, info , objheight, showtype ,objtopfirefoxoffset)
{
   
    var p = getposition(obj);
   
   if((showtype==null)||(showtype =="")) 
   {
       showtype =="up";
   }
   
   document.getElementById('hintiframe'+showtype).style.height= objheight + "px";
   document.getElementById('hintinfo'+showtype).innerHTML = info;
   document.getElementById('hintdiv'+showtype).style.display='block';
   
   
   
   if(objtopfirefoxoffset != null && objtopfirefoxoffset !=0 && !isie())
   {
        document.getElementById('hintdiv'+showtype).style.top=p['y']+parseInt(objtopfirefoxoffset)+"px";
   }
   else
   {
        if(objtopoffset == 0)
        { 
			if(showtype=="up")
			{
				 document.getElementById('hintdiv'+showtype).style.top=p['y']-document.getElementById('hintinfo'+showtype).offsetHeight-40+"px";
			}
			else
			{
				 document.getElementById('hintdiv'+showtype).style.top=p['y']+obj.offsetHeight+5+"px";
			}
        }
        else
        {
			document.getElementById('hintdiv'+showtype).style.top=p['y']+objtopoffset+"px";
        }
   }
   document.getElementById('hintdiv'+showtype).style.left=p['x']+objleftoffset+"px";
}



//隐藏提示层
function hidehintinfo()
{
    document.getElementById('hintdivup').style.display='none';
    document.getElementById('hintdivdown').style.display='none';
}

//重定向到播放页面
function redirect_play(id)
{
    window.location.href = "../"+id;
}
function wo(url, w, h, m, s) {
    var left = (screen.width - w) / 2;
    var top = m ? (screen.height - h) / 2 : 0;
    return window.open(url, 'player', 'width=' + w + ',height=' + h + ',top=' + top + ',left=' + left + ',scrollbars=0,resizable=0,status=' + s);

}
function woshowbar(url, w, h, m, s) {
    var left = (screen.width - w) / 2;
    var top = m ? (screen.height - h) / 2 : 0;
    return window.open(url, '', 'width=' + w + ',height=' + h + ',top=' + top + ',left=' + left + ',scrollbars=1,resizable=0,status=' + s);

}
function OpenWinCenter(url,w,h) {
    woshowbar(url, w, h, 1, 1);
}
function wo_href(url, w, h, m, s, name) {
    var left = (screen.width - w) / 2;
    var top = m ? (screen.height - h) / 2 : 0;
    window.open(url, name, 'width=' + w + ',height=' + h + ',top=' + top + ',left=' + left + ',scrollbars=0,resizable=0,status=' + s);
    return false;
}
function win_open_box(musidID) {
    wo("player.aspx?mid=" + musidID, "750", "600", 1, 1);
    //window.open('player.aspx?id=' + musidID, 'newwindow', 'height=470, width=350, top=0, left=0, toolbar=no, menubar=no, scrollbars=no, resizable=no,location=no, status=no')
}

//需要引入BlockUIPlugin
function open_loading()
{
    $.blockUI('<img src="/Images/loading.gif" /> 正在请求数据...'); 
}
function OpenPanelWindow(ob,windowname,widowid,iFrameUrl,width,height) {

    
    var sIframe = '<iframe src="'+iFrameUrl+'"  frameborder="0" width="'+width+'" height="'+height+'" scrolling="no"  ></iframe>';
    var sHtml = '<div class="window " id="'+widowid+'">';
        sHtml += '<div class="title">'+windowname+'<span class="buttons"><span class="close"></span></span></div>';
        sHtml += '<div  style="height:'+height+'px;" class="content">';
        sHtml += sIframe; 
        sHtml += '</div><div  class="status"><span class="resize"></span></div></div>';



        $(ob).html(sHtml);
        
    $("#"+widowid).jWindowOpen({
				modal:true,
				center:false,
				drag : false,
				close:"#"+widowid+" .close",
				closeHoverClass:"hover"
			});
}
function OpenWindowOnBorder(ob, widowid, iFrameUrl, width, height) {
    var sIframe = '<iframe src="'+iFrameUrl+'"  frameborder="0" width="'+width+'" height="'+height+'" scrolling="no"  ></iframe>';
    var sHtml = '<div onclick="closePaneWin(\'loginwindow\')" style="width:auto"  class="window " id="' + widowid + '">';
    sHtml += '<div   class="content">';
    sHtml += sIframe;
    sHtml += '</div><div  class="status"><span class="resize"></span></div></div>';

    $(ob).html(sHtml);
    $("#" + widowid).jWindowOpen({
        modal: true,
        center: false,
        drag: false,
        close: "#" + widowid + " .close",
        closeHoverClass: "hover"
    });
}
function OpenImgWindow(ob, widowid, imgurl, width) {
    var sIframe = '<img title="点击图片关闭" onclick=\'closePaneWin("' + widowid + '")\' src="' + imgurl + '"   border=0 ></img>';
    var sHtml = '<div style="width:auto"  class="window " id="' + widowid + '">';
    // sHtml += '<div class="title">图片展示<span class="buttons"><span class="close"></span></span></div>';
    sHtml += '<div   class="content">';
    sHtml += sIframe;
    sHtml += '</div><div  class="status"><span class="resize"></span></div></div>';



    $(ob).html(sHtml);
    $("#" + widowid).jWindowOpen({
        modal: true,
        center: false,
        drag: false,
        close: "#" + widowid + " .close",
        closeHoverClass: "hover"
    });
}
function closePaneWin(winid) {
    
    jWindow.close($("#" + winid));
}
//以post方式打开窗口
function postwinopen(strUrl,postdata)
{  
    
    var contrlos = postdata.split("&");
    var form = document.createElement("form"); 
    for(var i=0;i<contrlos.length;i++)
    {
        
        var strPram = contrlos[i]; 
       
        var cotrlosname = strPram.substring(0,strPram.indexOf("="));
        var sValue = strPram.substring(strPram.indexOf("=")+1,strPram.length);
        
        var input = document.createElement("input");        
        input.setAttribute("type","text");
         input.setAttribute("style","display:none");
         input.name = cotrlosname;
         input.value = sValue; 
         
         form.appendChild(input);
    }
     
     document.body.appendChild(form);
        form.target="_blank"; 
        form.method="post";
        form.action = strUrl;        
        form.submit();
    document.body.removeChild(form);
}


//关闭一个距于页面中间的提示框
function CloseTipsToCenter() {

    document.getElementById('CenterWindow').style.display = 'none';
}
//打开一个距于页面中间的提示框
function OpenTipsToCenter(stitle, msg, iWidth, iHeight, titlecolor, backgcolor) {

    var str = "";

    str += '<div id="CenterWindow" style="position:absolute;z-index:300;height:120px;width:' + (iWidth+14) + 'px;left:50%;top:50%;margin-left:-150px;margin-top:-80px;">';
    str += '<div id="Layer2" style="position:absolute;z-index:300;width:' + iWidth + 'px;height:' + iHeight + 'px;background-color: ' + backgcolor + ';border:solid ' + titlecolor + ' 1px;font-size:14px;">';
    str += '<div id="Layer4" style="height:26px;background:' + titlecolor + ';line-height:26px;padding:0px 3px 0px 3px;font-weight:bolder;color:#fff ">';
    str += stitle;
    str += '</div>';
    str += '<div id="Layer5" style="height:' + (iHeight-10) + 'px;line-height:150%;padding:0px 3px 0px 3px;" align="center">';
    str += '<br />' + msg + '';
    str += '</div>';
    str += '</div>';
    str += '<div id="Layer3" style="position:absolute;width:' + iWidth + 'px;height:' + iHeight + 'px;z-index:299;left:4px;top:5px;background-color: #cccccc;"></div>';
    str += '</div>';

    var span = document.createElement("span");
    span.innerHTML = str;

    document.body.appendChild(span);
}


//提示操作类--------

var cpopup = null; 		//气球提示窗口对象
var popuptt; 			//气球提示窗口定时器
var QI_ALERT_T = 1000;
var popupW = 180; 	//气球提示窗口宽度
var popupH = 30; 	//气球提示窗口高度
function newpopup() {
    cpopup = window.createPopup();
    var CCbody = cpopup.document.body;
    with (CCbody.style) {
        backgroundColor = "#E6F2FF";
        border = "#78B9FF 2px solid";
        color = "#FFFFFF";
        fontSize = "9pt";
        padding = 4;
    }
    CCbody.innerHTML = '<div id="txt" style="text-align:center;color:#FF0000"></div>';

}

function popuprun(s)		//气球提示窗口出现过程
{
    clearTimeout(popuptt);
    var ph = popupH * (ph = 1 - Math.abs(s) / 5);
    cpopup.show((screen.width - popupW) * 0.5, (screen.height - ph) * 0.5, popupW, ph);
    if (s > -4)
        popuptt = setTimeout("popuprun(" + (s - 1) + ")", (s == 0) ? QI_ALERT_T : 50);
    else
        cpopup.hide();
}

function popupopen() {
    if (QI_ALERT_T == 0)
        cpopup.show(screen.width - popupW, screen.height - popupH, popupW, popupH);
    else
        popuprun(4);
}
function showpop(strMSG) {
    newpopup();
    cpopup.document.all.txt.innerText = strMSG;
    popupopen();
}
function showpop_of_laod(strMSG) {
    newpopup();
    cpopup.document.all.txt.innerText = strMSG;
    cpopup.show((screen.width - popupW) * 0.5, (screen.height - popupH) * 0.5, popupW, popupH);
}
//窗口操作结束
function searchsubmit(ob)
{
	if(ob.q.value=="")return false;
}



/////////////////////////////////////////////////////打印操作/////////////////////////////////////
function doPrint(ob)
{
	var adBegin="";
	var adEnd="";
	var body;
	var css;
	var str;
	str += "<style media=print>.Noprint{display:none;}.PageNext{page-break-after: always;}</style>";
	str = "\n<script type='text/javascript'>\r\nfunction doPrint(){window.print();}\r\n</script>\r\n";
	str += "<center class='Noprint'><p><object id='WebBrowser'  classid='CLSID:8856F961-340A-11D0-A96B-00C04FD705A2'  height='0'  width='0'></object>";
	str += "<input type='button' value='打印' onclick='document.all.WebBrowser.ExecWB(6,1)'> ";
	str += "<input type='button' value='直接打印' onclick='document.all.WebBrowser.ExecWB(6,6)'> ";
	str += "<input  type='button' value='页面设置' onclick='document.all.WebBrowser.ExecWB(8,1)'> ";
	str += "</p><p><input type='button' value='打印预览' onclick='document.all.WebBrowser.ExecWB(7,1)'> ";
	str += "[字体：<input type='button' value='大' onclick='javascript:ContentSize(16,txtword)'> <input type='button' value='中' onclick='javascript:ContentSize(14,txtword)'> <input type='button' value='小' onclick='javascript:ContentSize(12,txtword)'>]";
	str += "</p><hr align='center' width='90%' size='1' noshade='noshade'></center>";
	str += "<div id=\"con\" contenteditable='true'>";
	body= ob.innerHTML;
	//去掉广告
	if (body.indexOf(adBegin)>=0)
	{
		str+=body.substr(0,body.indexOf(adBegin));
		str+=body.substr(body.indexOf(adEnd)+adEnd.length,body.length);
	}else{
		str+=body;
	}
	str +="</div>";
	str += "<span>(中国音乐网www.cnmusic.com)</span>";
	str += "</p><p><input type='button' value='返回' href='javascript:void(null)' onclick='window.location.reload()'>";
	document.body.innerHTML=str;
}
// 内容样式用户定义
function ContentSize(size,obj)
{
	//var obj=document.getElementById("txtword");
	obj.style.fontSize=size>0 ? size+"px" : "";
//	if (arguments.length==1){
//		setCookie("iwmsFontSize",size,size==0?-1:1);
//	}
}
function InitOrderSum() {

    $("#dayhitssum").html("载入中...");
    run_ajax_async("/Ajax/HitsSum.ashx", "", InitOrderSum_Comp)

}
function InitOrderSum_Comp(msg) {
    
    $("#dayhitssum").html(msg);
}

function initContentHits(sid) {
    $("#dayhits").html("载入中...");
    $("#allhits").html("载入中...");

    run_ajax_async_type(IISPath+"/Ajax/ContentHits.ashx", "id=" + sid, initContentHits_comp, "post");
}
function initContentHits_comp(msg) {
    if (msg != null && msg != '') {

        var aHitsInfo = msg.split(SPLITTER_FIELD);
        if (aHitsInfo.length == 2) {
            $("#dayhits").html(aHitsInfo[1]);
            $("#allhits").html(aHitsInfo[0]);
        }
    }
}
