$(function(){
  var player
  switch (videoInfo['b'].toLowerCase()) 
  {
    case "qvod"://快播
	  player="<object classid=\"clsid:F3D0D36F-23F8-4682-A195-74C92B03D4AF\" width=\""+videoInfo["w"]+"\" height=\""+videoInfo["h"]+"\" onerror=\"Loadiframe('../js/qvod_install.html')\">\
	  <param name=\"URL\" value=\""+videoInfo["a"]+"\" />\
	  <param name=\"AutoPlay\" value=\"1\" />\
	  <param name=\"NextWebPage\" value=\""+videoInfo["NextWebPage"]+"\" />\
	  <param name=\"QvodAdUrl\" value=\"http://"+videoInfo["siteurl"]+"/js/loading.html\" />\
	  </object>"
      break;
	case "bdhd"://百度影音
	  player="<object classid=\"clsid:02E2D748-67F8-48B4-8AB4-0A085374BB99\" width=\""+videoInfo["w"]+"\" height=\""+videoInfo["h"]+"\" onerror=\"Loadiframe('http://player.baidu.com/lib/install/')\">\
	  <param name=\"URL\" value=\""+videoInfo["a"]+"\" />\
	  <param name=\"AutoPlay\" value=\"1\" />\
	  <param name=\"FullScreen\" value=\"0\" />\
	  <param name=\"LastWebPage\" value=\"\" />\
	  <param name=\"NextWebPage\" value=\""+videoInfo["NextWebPage"]+"\" />\
	  <param name=\"NextCacheURL\" value=\""+videoInfo["c"]+"\" />\
	  <param name=\"OnPause\" value=\"onPause\" />\
	  <param name=\"OnPlay\" value=\"onPlay\" />\
	  <param name=\"OnFirstBufferingStart\" value=\"OnFirstBufferingStart\" />\
	  <param name=\"OnFirstBufferingEnd\" value=\"OnFirstBufferingEnd\" />\
	  <param name=\"OnPlayBufferingStart\" value=\"OnPlayBufferingStart\" />\
	  <param name=\"OnPlayBufferingEnd\" value=\"OnPlayBufferingEnd\" />\
	  <param name=\"OnComplete\" value=\"OnComplete\" />\
	  <param name=\"ShowStartClient\" value=\"1\" />\
	  </object>"
	  break;
   case "hd_openv":
	  player="<object classid=\"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000\" width=\""+videoInfo["w"]+"\" height=\""+videoInfo["h"]+"\" codebase=\"http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,0\">\
	  <param name=\"allowScriptAccess\" value=\"always\" />\
	  <param name=\"quality\" value=\"high\" />\
	  <param name=\"allowNetworking\" value=\"internal\" />\
	  <param name=\"allowfullscreen\" value=\"true\" />\
	  <param name=\"movie\" value=\"http://img.openv.tv/hd/swf/hd_player.swf\" />\
	  <embed type=\"application/x-shockwave-flash\" src=\"http://img.openv.tv/hd/swf/hd_player.swf\" hasLeftBar=\"false\" pid=\""+videoInfo["a"]+"\" q=tv=0,vtype=1 hd=1 autostart=true showOverEvent=1 culatePlayerTimer=true playADstatu=true showLRmenu=false playNowTitle=\"\" pluginspage=\"http://www.macromedia.com/go/getflashplayer\"/>"
	  break;
   case "tudou"://土豆
	  player="<embed src=\"http://www.tudou.com/v/"+videoInfo["a"]+"/&autoPlay=true/v.swf\" type=\"application/x-shockwave-flash\" allowscriptaccess=\"always\" allowfullscreen=\"true\" wmode=\"opaque\" width=\""+videoInfo["w"]+"\" height=\""+videoInfo["h"]+"\"></embed>"
      break;
   case "hd_tudou"://土豆高清
	  player="<object classid=\"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000\" width=\""+videoInfo["w"]+"\" height=\""+videoInfo["h"]+"\">\
	  <param name=\"movie\" value=\"http://js.tudouui.com/bin/kili/player/TudouVideoPlayer_kili_4.swf\" />\
	  <param name=\"quality\" value=\"high\" />\
	  <param name=\"allowfullscreen\" value=\"true\" />\
	  <param name=\"allowscriptaccess\" value=\"always\" />\
	  <param name=\"wmode\" value=\"Opaque\" />\
      <embed type=\"application/x-shockwave-flash\" iid=\""+videoInfo["a"]+"&lid=0\"nextURL=\"javascript:onClipPlay(1, true)\" allow=1 default_skin=\"http://js.tudouui.com/bin/kili/player/Main_4.swf\" pluginspage=\"http://www.macromedia.com/go/getflashplayer\"/>"
     break;
   case "youku"://优酷
	  player="<object classid=\"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000\" width=\""+videoInfo["w"]+"\" height=\""+videoInfo["h"]+"\">\
	  <param name=\"movie\" value=\"http://static.youku.com/v1.0.0370/v/swf/qplayer.swf\" />\
	  <param name=\"quality\" value=\"high\" />\
	  <param name=\"allowfullscreen\" value=\"true\" />\
	  <param name=\"allowscriptaccess\" value=\"always\" />\
	  <param name=\"wmode\" value=\"Opaque\" />\
      <embed type=\"application/x-shockwave-flash\" isShowRelatedVideo=false&showAd=0&show_pre=1&show_next=1&isAutoPlay=true&isDebug=false&UserID=&winType=interior&playMovie=true&MMControl=false&MMout=false VideoIDS=\""+videoInfo["a"]+"\" pluginspage=\"http://www.macromedia.com/go/getflashplayer\"/>"
 	  break;
   case "qiyi":
	  player="<object classid=\"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000\" width=\""+videoInfo["w"]+"\" height=\""+videoInfo["h"]+"\">\
	  <param name=\"movie\" value=\"http://www.qiyi.com/player/20110218183154/qiyi_player.swf\" />\
	  <param name=\"quality\" value=\"high\" />\
	  <param name=\"allowfullscreen\" value=\"true\" />\
	  <param name=\"allowscriptaccess\" value=\"always\" />\
      <embed type=\"application/x-shockwave-flash\" flashVars=\"hideZoomBtn=0&webEventID=9839506651029862025&pid=55&ptype=2&albumId=104529&tvId=74088\" vid=\""+videoInfo["a"]+"\" src=\"http://www.qiyi.com/player/20110218183154/qiyi_player.swf\" quality=\"high\" name=\"adflash\" align=\"middle\" quality=\"high\" allowscriptaccess=\"always\" pluginspage=\"http://www.macromedia.com/go/getflashplayer\"/>"
      break;
   case "sohu":
	  player="<object classid=\"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000\" width=\""+videoInfo["w"]+"\" height=\""+videoInfo["h"]+"\" codebase=\"http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,115\" type=\"application/x-shockwave-flash\">\
	  <param name=\"movie\" value=\"http://tv.sohu.com/upload/swf/20110310/Main.swf\" />\
	  <param name=\"quality\" value=\"high\" />\
	  <param name=\"allowfullscreen\" value=\"true\" />\
	  <param name=\"allowscriptaccess\" value=\"always\" />\
	  <param name=\"bgcolor\" value=\"#000000\" />\
	  <param name=\"wmode\" value=\"always\" />\
	  <param name=\"allowscriptaccess\" value=\"Opaque\" />\
      <embed type=\"application/x-shockwave-flash\" flashVars=\"skin=0&soad=&oad=&ead=&pad=&fbarad=&flogoad=&ftitledelay=&tlogoad=&tlogodelay=&fbottomad=&fbottomdelay=&ftitlead=&flogodelay=&domain=inner&cover=http://photocdn.sohu.com/20110124/vrsb147277.jpg&pageurl=&nid=279063628&pid=262735630&sid=null&jump=0&shareBtn=1&historyBtn=1&cinemaBtn=1&bfBtn=1&playListId=1&autoplay=true\" vid=\""+videoInfo["a"]+"\"  pluginspage=\"http://www.macromedia.com/go/getflashplayer\"/>"
      break;
   case "ku6":
	  player="<object classid=\"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000\" width=\""+videoInfo["w"]+"\" height=\""+videoInfo["h"]+"\">\
	  <param name=\"movie\" value=\"http://img1.c0.ku6.cn/player/pV1.2.swf\" />\
	  <param name=\"quality\" value=\"high\" />\
	  <param name=\"allowfullscreen\" value=\"true\" />\
	  <param name=\"allowscriptaccess\" value=\"always\" />\
	  <param name=\"allowNetworking\" value=\"internal\" />\
	  <param name=\"wmode\" value=\"Opaque\" />\
      <embed type=\"application/x-shockwave-flash\" flashVars=\"ver=108&type=v&referer=&auto=1\" vid=\""+videoInfo["a"]+"\"  pluginspage=\"http://www.macromedia.com/go/getflashplayer\"/>"
      break;
   case "hd_iask":
	  player="<object classid=\"clsid:d27cdb6e-ae6d-11cf-96b8-444553540000\" width=\""+videoInfo["w"]+"\" height=\""+videoInfo["h"]+"\">\
	  <param name=\"_cx\" value=\"16933\" />\
	  <param name=\"_cy\" value=\"12700\" />\
	  <param name=\"Movie\" value=\"http://p.you.video.sina.com.cn/swf/tvPlayer20111228_V4_2_39_32.swf?d=Wed Jan 4 17:24:46 UTC+0800 2012\" />\
	  <param name=\"Src\" value=\"http://p.you.video.sina.com.cn/swf/tvPlayer20111228_V4_2_39_32.swf?d=Wed Jan 4 17:24:46 UTC+0800 2012\" />\
	  <param name=\"WMode\" value=\"Transparent\" />\
	  <param name=\"Play\" value=\"0\" />\
	  <param name=\"Loop\" value=\"-1\" />\
	  <param name=\"Quality\" value=\"High\" />\
	  <param name=\"SAlign\" value=\"LT\" />\
	  <param name=\"Menu\" value=\"-1\" />\
	  <param name=\"Base\" value=\"\" />\
	  <param name=\"AllowScriptAccess\" value=\"always\" />\
	  <param name=\"Scale\" value=\"NoScale\" />\
	  <param name=\"DeviceFont\" value=\"0\" />\
	  <param name=\"EmbedMovie\" value=\"0\" />\
	  <param name=\"BGColor\" value=\"000000\" />\
	  <param name=\"SWRemote\" value=\"\" />\
	  <param name=\"MovieData\" value=\"\" />\
	  <param name=\"SeamlessTabbing\" value=\"1\" />\
	  <param name=\"Profile\" value=\"0\" />\
	  <param name=\"ProfileAddress\" value=\"\" />\
	  <param name=\"ProfilePort\" value=\"0\" />\
	  <param name=\"AllowNetworking\" value=\"all\" />\
	  <param name=\"AllowFullScreen\" value=\"true\" />\
      <embed type=\"application/x-shockwave-flash\" flashVars=\"container=main_flash&amp;playerWidth=600&amp;playerHeight=500&amp;pid=1000&amp;tid=2&amp;autoLoad=1&amp;autoPlay=1&amp;as=1&amp;tj=0&amp;tjAD=0&amp;casualPlay=1&amp;logo=1&amp;vid="+videoInfo["a"]+"&amp;vname=aaaaa&amp;movietvid=xy&amp;programId=3705&amp;episode=2&amp;sid=61631131&amp;next_url=&amp;mp4Id=69066674&amp;actlogActive=0&amp;HTML5Player_skin=black\" pluginspage=\"http://www.macromedia.com/go/getflashplayer\"/>"
      break;
   case "gvod":
	  player=gvod_player();
	  player.height=500;
	  player.width=600;
	  player.nextPage=videoInfo["NextWebPage"];
	  player.nextUrl=videoInfo["c"];
	  player.stickPage='http://'+videoInfo["siteurl"]+'/js/loading.html';
	  player.play(videoInfo["a"]);
	  break;
  } 
  if (videoInfo['b'].toLowerCase()!="gvod") $(".player").html(player)
  var iframe='<iframe width="100%" height="1" frameborder="0" scrolling="no" src="/inc/comment/index.html?id='+videoID+'&type=1&title=标题" marginheight="0" marginwidth="0" name="comment" style="height: 791px;"></iframe>'														  
  $("#comment_list").html(iframe)
})
function Loadiframe(url){
  document.body.innerHTML='<iframe scrolling="no" frameborder="0" style="margin:0;width:100%;height:510px;" src="'+url+'"></iframe>'
}