//flash代码函数
function lg_flash(lg_url,lg_width,lg_height)
{
var lg_width
var lg_height
var lg_url
document.write('<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,29,0" width="'+lg_width+'" height="'+lg_height+'">');
document.write('<param name="movie" value="'+lg_url+'">')
document.write('<param name="quality" value="high">')
document.write('<param name="wmode" value="transparent">')
document.write('<embed src="'+lg_url+'" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" width="'+lg_width+'" height="'+lg_height+'">')
document.write('</embed>')
document.write('</object>')
}
//带数据的flash代码函数
function lg_flash_asp(focus_width,focus_height,text_height,pics,links,texts)//依此是 flash的宽，高，文字高，地址，链接，标题
{
var focus_width
var focus_height
var text_height
var swf_height = focus_height+text_height
var pics
var links
var texts
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="'+ focus_width +'" height="'+ swf_height +'">');
document.write('<param name="allowScriptAccess" value="sameDomain"><param name="movie" value="images/flash.swf"><param name="quality" value="high"><param name="bgcolor" value="#FFFFFF">');
document.write('<param name="menu" value="false"><param name=wmode value="opaque">');
document.write('<param name="FlashVars" value="pics='+pics+'&links='+links+'&texts='+texts+'&borderwidth='+focus_width+'&borderheight='+focus_height+'&textheight='+text_height+'">');
document.write('<embed src="images/flash.swf" wmode="opaque" FlashVars="pics='+pics+'&links='+links+'&texts='+texts+'&borderwidth='+focus_width+'&borderheight='+focus_height+'&textheight='+text_height+'" menu="false" bgcolor="#FFFFFF" quality="high" width="'+ focus_width +'" height="'+ focus_height +'" allowScriptAccess="sameDomain" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" />');
document.write('</object>');
}
//wmv播放器代码函数
function lg_wmv_asp(focus_width,focus_height,focus_url,bofang)//依此是 宽，高，地址，是否自动播放
{
var focus_width
var focus_height
var focus_url
var bofang
document.write('<object classid="CLSID:22d6f312-b0f6-11d0-94ab-0080c74c7e95" codebase="http://activex.microsoft.com/activex/controls/mplayer/en/nsmp2inf.cab#Version=6,4,5,715" type="application/x-oleobject" width="'+ focus_width +'" height="'+ focus_height +'" hspace="5" align="right" standby="Loading Microsoft Windows Media Player components..." class="vcd" id="NSPlay">');
document.write('<param name="AutoRewind" value=1>');
document.write('<param name="FileName" value="'+ focus_url +'">');
document.write('<param    NAME="AutoStart"    VALUE="'+ bofang +'">'); //是否自动播放
document.write('<param    NAME="Balance"    VALUE="0">'); //调整左右声道平衡,同上面旧播放器代码
document.write('<param    name="enabled"    value="-1">'); //播放器是否可人为控制
document.write('<param    NAME="EnableContextMenu"    VALUE="-1">'); //是否启用上下文菜单
document.write('<param    NAME="PlayCount"    VALUE="1">'); //播放次数控制,为整数
document.write('<param    name="rate"    value="1">'); //播放速率控制,1为正常,允许小数,1.0-2.0
document.write('<param    name="currentPosition"    value="0">'); //控件设置:当前位置
document.write('<param    name="currentMarker"    value="0">'); //控件设置:当前标记
document.write('<param    name="defaultFrame"    value="">'); //显示默认框架
document.write('<param    name="invokeURLs"    value="0">'); //脚本命令设置:是否调用URL
document.write('<param    name="baseURL"    value="">'); //脚本命令设置:被调用的URL
document.write('<param    name="stretchToFit"    value="0">');  // 是否按比例伸展
document.write('<param    name="volume"    value="50">');  //默认声音大小0%-100%,50则为50%
document.write('<param    name="mute"    value="0">');  //是否静音-
document.write('<param    name="uiMode"    value="None">');               //播放器显示模式:Full显示全部;mini最简化;None不显示播放控制,只显示视频窗口;invisible全部不显示
document.write('<param    name="windowlessVideo"    value="0">');  //如果是0可以允许全屏,否则只能在窗口中查看
document.write('<param    name="fullScreen"    value="0">');     //    开始播放是否自动全屏
document.write('<param    name="enableErrorDialogs"    value="-1">');  //是否启用错误提示报告
document.write('<param    name="SAMIStyle"    value>'); //SAMI样式
document.write('<param    name="SAMILang"    value>'); //SAMI语言
document.write('<param    name="SAMIFilename"    value>');  //字幕ID
document.write('</object>');
}
//连续滚动js代码函数
function lg_left_Move(demox,demoy,demoz,s)//依此是 
{
   var speed=s  //速度
  demoz.innerHTML=demoy.innerHTML  //第2个id层 demoy
  function Marquee(){
  if(demoz.offsetWidth-demox.scrollLeft<=0)
  demox.scrollLeft-=demoy.offsetWidth  //第1个id层 demox
  else{
  demox.scrollLeft++
  }
  }
  var MyMar=setInterval(Marquee,s)
  demox.onmouseover=function() {clearInterval(MyMar)}
  demox.onmouseout=function() {MyMar=setInterval(Marquee,speed)}
}

//连续滚动js代码函数
function lg_up_Move(demox,demoy,demoz,s)//依此是 
{
var speed=s;
demoz.innerHTML=demoy.innerHTML;
function Marquee(){
    if(demoz.offsetTop-demox.scrollTop<=0){
        demox.scrollTop-=demoy.offsetHeight;
    }
    else{
        demox.scrollTop++;
    }
}
var MyMar=setInterval(Marquee,speed);
demox.onmouseover=function() {clearInterval(MyMar)};
demox.onmouseout=function() {MyMar=setInterval(Marquee,speed)};
}
//生日函数
function lg_toDate()
{
 with(document.all)
 {
  vYear=parseInt(year.options[year.selectedIndex].text)
  vMonth=parseInt(month.options[month.selectedIndex].text)
  day.length=0;
  for(I=0;I<(new Date(vYear,vMonth,0)).getDate();I++)
  {
  day.options[day.length++].value=day.length;day.options[day.length-1].text=day.length;
  
  
  }

 }
//lg_toDay(lgYear,lgMonth);
}

//function lg_toDay()
//{
////var arr="日一二三四五六".split("")
//// vDay=parseInt(document.all.day.options[document.all.day.selectedIndex].value)
//document.all("weekday").value=document.getElementById("year").value
////document.all("weekday").value="星期"+arr[new Date(vYear,vMonth-1,vDay).getDay()]
//}
 //window.onload=lg_toDate;




//日期函数
 today=new Date();
 function initArray(){
   this.length=initArray.arguments.length
   for(var i=0;i<this.length;i++)
   this[i+1]=initArray.arguments[i]  }

 function lg_datetime(){
    var d=new initArray(
     "星期日",
     "星期一",
     "星期二",
     "星期三",
     "星期四",
     "星期五",
     "星期六"); 
 
document.write(
     "<font color=#fff style='font-size:9pt;font-family: 宋体'> ",
     today.getYear(),"年",
     today.getMonth()+1,"月",
     today.getDate(),"日&nbsp;",
     d[today.getDay()+1],
     "</font>" ); 
     }




