﻿function ObjectAD() {
    /* Define  Variables*/
    this.ADID = 0;
    this.ADType = 0;
    this.ADName = "";
    this.ImgUrl = "";
    this.ImgWidth = 0;
    this.ImgHeight = 0;
    this.FlashWmode = 0;
    this.LinkUrl = "";
    this.LinkTarget = 0;
    this.LinkAlt = "";
    this.Priority = 0;
    this.CountView = 0;
    this.CountClick = 0;
    this.InstallDir = "";
    this.ADDIR = "";
    this.OverdueDate = "";
}

function BannerZoneAD(_id) {
    /* Define Constants */
    this.adNum = 0;
    this.adDelay = 0;

    /* Define Common Variables*/
    this.ID = _id;
    this.ZoneID = 0;
    this.ZoneName = "";
    this.ZoneWidth = 0;
    this.ZoneHeight = 0;
    this.ShowType = 1;
    this.DivName = "";
    this.Div = null;

    /* Define Unique Variables*/

    /* Define Objects */
    this.AllAD = new Array();
    this.ShowAD = null;

    /* Define Functions */
    this.AddAD = BannerZoneAD_AddAD;
    this.Show = BannerZoneAD_Show;

}

function BannerZoneAD_AddAD(_AD) {
    var date = new Date();
    var getdate = date.getFullYear() + "/" + (date.getMonth() + 1) + "/" + date.getDate();
    var today = new Date(getdate);
    var overdueDate = new Date(_AD.OverdueDate);
    if (today <= overdueDate) {
        this.AllAD[this.AllAD.length] = _AD;
    }
}

function BannerZoneAD_Show() {
    var swf_width = this.ZoneWidth;
    var swf_height = this.ZoneHeight;
    var swf_path = "/images/";
    var config = '0xFFFFFF|0x2|0099FF|15|0xFFFFFF|0x0099FF|0x000000|8|3|1|_blank';
    var files = '';
    var links = '';
    var texts = '';
    for (var ADID in this.AllAD) {
        if (ADID < this.AllAD.length - 1) {
            files += this.AllAD[ADID].ImgUrl + "|";
            links += this.AllAD[ADID].LinkUrl + "|";
            texts += "|";
        }
        else {
            files += this.AllAD[ADID].ImgUrl;
            links += this.AllAD[ADID].LinkUrl;
        }
    }
    document.write('<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0" width="' + swf_width + '" height="' + swf_height + '">');
    document.write('<param name="movie" value="' + swf_path + 'advFocus.swf">'); document.write('<param name="quality" value="high">'); document.write('<param name="menu" value="false">');
    document.write('<param name="wmode" value="opaque">'); document.write('<param name="FlashVars" value="bcastr_config=' + config + '&amp;bcastr_file=' + files + '&amp;bcastr_link=' + links + '&amp;bcastr_title=' + texts + '">');
    document.write('<embed src="' + swf_path + 'advFocus.swf" wmode="opaque" FlashVars="bcastr_config=' + config + '&amp;bcastr_file=' + files + '&amp;bcastr_link=' + links + '&amp;bcastr_title=' + texts + '" menu="false" quality="high" width="' + swf_width + '" height="' + swf_height + '" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer"></embed>');
    document.write('</object>');
}var ZoneAD_4=new BannerZoneAD("ZoneAD_4");var objAD = new ObjectAD();
objAD.ADID= 28;objAD.ADType= 1;objAD.ADName= "双优双满意";objAD.ImgUrl= "/UploadFiles/UploadADPic/2010625153649.jpg";objAD.ImgWidth       = 0;objAD.ImgHeight      = 0;objAD.FlashWmode     = 0;objAD.ADIntro ="";objAD.LinkUrl        = "http://www.wdsyzx.com/Category_2907/Index.aspx";objAD.LinkTarget     = 1;objAD.LinkAlt        = "";objAD.Priority       = 1;objAD.CountView      = false;objAD.CountClick     = false;objAD.OverdueDate    = "2110/05/16";objAD.InstallDir     = "/";objAD.ADDIR= "IAA";ZoneAD_4.AddAD(objAD);var objAD = new ObjectAD();
objAD.ADID= 9;objAD.ADType= 1;objAD.ADName= "三查三促三提高";objAD.ImgUrl= "/UploadFiles/UploadADPic/200992794452.gif";objAD.ImgWidth       = 976;objAD.ImgHeight      = 98;objAD.FlashWmode     = 0;objAD.ADIntro ="";objAD.LinkUrl        = "http://www.wdsyzx.com/XYXW/SCSCSTG/";objAD.LinkTarget     = 1;objAD.LinkAlt        = "";objAD.Priority       = 1;objAD.CountView      = false;objAD.CountClick     = false;objAD.OverdueDate    = "2019/10/27";objAD.InstallDir     = "/";objAD.ADDIR= "IAA";ZoneAD_4.AddAD(objAD);var objAD = new ObjectAD();
objAD.ADID= 6;objAD.ADType= 1;objAD.ADName= "科学发展观";objAD.ImgUrl= "/UploadFiles/UploadADPic/200982392918.gif";objAD.ImgWidth       = 976;objAD.ImgHeight      = 98;objAD.FlashWmode     = 0;objAD.ADIntro ="科学发展观";objAD.LinkUrl        = "http://www.wdsyzx.com/XYXW/XJXXX/";objAD.LinkTarget     = 0;objAD.LinkAlt        = "";objAD.Priority       = 3;objAD.CountView      = false;objAD.CountClick     = false;objAD.OverdueDate    = "2021/09/23";objAD.InstallDir     = "/";objAD.ADDIR= "IAA";ZoneAD_4.AddAD(objAD);ZoneAD_4.ZoneID=4;ZoneAD_4.ZoneWidth=976;ZoneAD_4.ZoneHeight=98;ZoneAD_4.ShowType=3;ZoneAD_4.Show();
