两个JS文件冲突了,哪位朋友帮我看看啊!在这里先谢谢了!
(1)如下是新加入网站的的JS文件,但是加入之后就和网站的原JS文件起冲突了。
function killErrors() {
    return true;
}
window.onerror = killErrors;
function $(){return document.getElementById?document.getElementById(arguments[0]):eval(arguments[0]);}
function setcookie(name,value)//两个参数,一个是 cookie 的名子,一个是值
{
var Days = 365; //此 cookie 将被保存 30 天
var exp = new Date(); //new Date("December 31, 9998");
exp.setTime(exp.getTime() + Days*24*60*60*1000);
document.cookie = name + "="+ value + ";expires=" + exp.toGMTString();
}function getCookie(name) {
  var search;
  search = name + "=";
  offset = document.cookie.indexOf(search) ;
  if (offset != -1) {
    offset += search.length ;
    end = document.cookie.indexOf(";", offset) ;
    if (end == -1)
      end = document.cookie.length;
    return document.cookie.substring(offset, end);
  }
  else
    return "";
}function sEditN(nid)//显示
{
var arrN=["新浪","腾讯","网易","搜狐","雅虎","人民网","新华网","淘宝网","百度","Google","CCTV","凤凰网","湖南卫视","工商银行","建设银行","中国银行","农业银行","360杀毒","携程网","58同城","人人网","开心网","天涯论坛","优酷网"];
var arrU=["http://www.sina.com.cn/","http://www.qq.com/","http://www.163.com/","http://www.sohu.com/","http://cn.yahoo.com/","http://www.people.com.cn/","http://www.xinhuanet.com/","http://www.taobao.com/","http://www.baidu.com/","http://www.google.com/","http://www.cctv.com/","http://www.ifeng.com/","http://www.hunantv.com/","http://www.icbc.com.cn/icbc/","http://www.ccb.com/cn/home/index.html/","http://www.boc.cn/","http://www.95599.cn/cn/default.htm","http://www.360.cn/","http://www.ctrip.com/","http://58.com/","http://www.renren.com/","http://www.kaixin001.com/","http://www.tianya.cn/","http://www.youku.com"];
    var Ze = "messdiv";
    BOX_layout(Ze);
    window.onresize = function(){BOX_layout(Ze);} //改变窗体重新调整位置
    window.onscroll = function(){BOX_layout(Ze);} //滚动窗体重新调整位置
var Zaa = getCookie("wz"+nid+"_n");
var Zbb = getCookie("wz"+nid+"_u");
if (Zaa != "") {
$("wzname").value = Zaa;
}
else{
$("wzname").value = arrN[nid-1];
}
if (Zbb != "") {
$("wzurl").value = Zbb;
}
else {
$("wzurl").value = arrU[nid-1];
}
$("nid").value = nid;}function intDiywz() {
for(m=1;m<=24;m++){
var Yaa = getCookie("wz"+m+"_n");
var Ybb = getCookie("wz"+m+"_u");
if (Yaa != "" && Ybb != "") {
$("wz"+m).innerHTML = "<span><img title='编辑网址' src='http://www.lyh8.cn/template/ant/images/edit.gif' onclick='sEditN("+m+")'/></span><a href='"+Ybb+"'>"+Yaa+"</a>";
}
Yaa = "";
Ybb = "";
}
}function BOX_remove(e)//移除
{
    window.onscroll = null;
    window.onresize = null;
    $('BOX_overlay').style.display="none";
    $(e).style.display="none";
}function BOX_layout(e)//调整位置
{
    var a = $(e);    if ($('BOX_overlay')==null)//判断是否新建遮掩层
    {
        var overlay = document.createElement("div");
        overlay.setAttribute('id','BOX_overlay');
        document.body.appendChild(overlay);
    }    $('BOX_overlay').ondblclick=function(){BOX_remove(e);};
    //取客户端左上坐标,宽,高
    var scrollLeft = (document.documentElement.scrollLeft ? document.documentElement.scrollLeft : document.body.scrollLeft);
    var scrollTop = (document.documentElement.scrollTop ? document.documentElement.scrollTop : document.body.scrollTop);    var clientWidth;
    if (window.innerWidth)
    {
        clientWidth = window.innerWidth;
    }
    else
    {
        clientWidth = document.documentElement.clientWidth;
    }    var clientHeight;
    if (window.innerHeight)
    {
        clientHeight = window.innerHeight;
    }
    else
    {
        clientHeight = document.documentElement.clientHeight;
    }    var bo = $('BOX_overlay');
    bo.style.left = scrollLeft+'px';
    bo.style.top = scrollTop+'px';
    bo.style.width = clientWidth+'px';
    bo.style.height = clientHeight+'px';
    bo.style.display="";
    //Popup窗口定位
    a.style.position = 'absolute';
    a.style.zIndex=999;
    a.style.display="";
}function HiddenButton(e)
{
    e.style.visibility='hidden';
    e.coolcodeviousSibling.style.visibility='visible'
}function savewz()
{
    var Taa = $("wzname").value;
var Tbb = $("wzurl").value;
var Tcc = $("nid").value;
if (Taa=="") {
alert("请填写网站名称");
$("wzname").focus();
return false;
}
if (Tbb=="") {
alert("请填写网址");
$("wzurl").focus();
return false;
}
setcookie("wz"+Tcc+"_n",Taa);
setcookie("wz"+Tcc+"_u",Tbb);
$("wz"+Tcc).innerHTML = "<span><img title='编辑网址' src='http://www.lyh8.cn/template/ant/images/edit.gif' onclick='sEditN("+Tcc+")'/></span><a href='"+Tbb+"'>"+Taa+"</a>";
BOX_remove('messdiv');
}function wzzdy() {
for(p=1;p<=24;p++){
$("wz"+p).className = "ess";
}
$("diy1").style.display="none";
$("diy2").style.display="block";
}
function wzwc() {
for(p=1;p<=24;p++){
$("wz"+p).className = "";
}
$("diy1").style.display="block";
$("diy2").style.display="none";
}
//------------------------------------
function createXMLHttps(){
var ret = null;
try {ret = new ActiveXObject('Msxml2.XMLHTTP')}
catch (e) {
try {ret = new ActiveXObject('Microsoft.XMLHTTP')}
        catch (ee) {ret = null}
}
if (!ret&&typeof XMLHttpRequest !='undefined') ret = new XMLHttpRequest();
return ret;
}
function AjaxGet(val) {
var URL = "a/wz6.jsp?a="+val;
var xmlhttp = createXMLHttps();
xmlhttp.open("Get",URL,true);
xmlhttp.setRequestHeader("Content-Type", "application/x-www-form-urlencoded");
xmlhttp.onreadystatechange = function() {
if (xmlhttp.readyState == 4 && xmlhttp.status==404) {$("Loading").innerHTML='Err';return}
if (xmlhttp.readyState == 4 && xmlhttp.status == 200) {
$("z0").innerHTML = xmlhttp.responseText;
}
}
xmlhttp.send(null);
}
function swap8(nn){
AjaxGet(nn);
var ali=$("tab2a").getElementsByTagName("h2");
for(k=0;k<ali.length;k++){
   ali[k].className=k==nn?"act":"";
}
}function swap1(nn,tab){
var ali=$("tab"+tab+"a").getElementsByTagName("h2");
var bli=$("tab"+tab+"b").getElementsByTagName("ul");
for(k=0;k<ali.length;k++){
   ali[k].className=k==nn?"act":"";
   bli[k].style.display=k==nn?"block":"none";
}
}function closeMB(){
$('MB').style.height = "0px";
$('MB').innerHTML = "";
$('msgM').style.top='253px';
}
function closeYoudong(){
$('a_aim').innerHTML = "";
$('a_aim').style.display="none";
}
function hideBG(){
$('bann').innerHTML = "";
$('bann').style.display="none";
$('tbody').className="bgnormal";
}//9-16
function display(){
$("box").style.display="block"; 
}
function disappear(){
$("box").style.display="none"; 
}
function setTab(hotel,a,n){
 for (var i = 1; i <= n ; i++)
  {
      var ti = $(hotel+"_tit"+i);
      var ci = $(hotel+"_con"+i);
      ti.className = i == a ? "gou" : "";
      ci.className = i == a ? "hotel_answer" : "undis";
  }
}————————————————————————网站的原JS文件在这里(因为太长了,无法发布在这里)
http://www.sx152.com/ad/index.js哪位老师帮我看看啊!先谢谢你们了!
也祝CSDN的所有老师、朋友新的一年工作愉快!