/**  
  insertPlayer.js
  Workaround for IE changes due to Eolas/Microsoft Patent Infringement 
  ActiveX Patch.
**/

function insertPlayerWM6_1(elmID, src, width, height) {
  var html;
  html = "<object id='WinMedia' "
    + "classid='CLSID:22d6f312-b0f6-11d0-94ab-0080c74c7e95' "
    + "codebase='http://activex.microsoft.com/activex/controls/mplayer/en/nsmp2inf.cab#Version=5,1,52,701' "
    + "width='" + width + "' height='" + height + "' "
    + "standby='Loading MultiMedia' "
    + "type='application/x-object'>"
    + "<param name='FileName' value='" + src + "' />"
    + "<param name='AutoStart' value='true' />"
    + "<param name='ShowControls' value='true' />"
    + "<param name='ShowAudioControls' value='true' />"
    + "<param name='ShowPositionControls' value='true' />"

    // Embed for Netscape type Browsers
    + "<embed type='application/x-mplayer2' "
    + "pluginspage='http://www.microsoft.com/Windows/MediaPlayer/' "
    + "src='" + src + "' "
    + "name='MediaPlayer' "
    + "width='" + width + "' "
    + "height='" + height + "' "
    + "autostart='1' "
    + "ShowControls='1' "
    + "ShowAudioControls='1' "
    + "ShowPositionControls='1'>"

    + "</object>";

  document.getElementById(elmID).innerHTML = html;
}

function insertPlayerWM7_1(elmID, src, width, height) {
  var html;
  html = "<object ID='WinMedia' width='" + width + "' height='" + height + "' "
    + "CLASSID='CLSID:6BF52A52-394A-11d3-B153-00C04F79FAA6' "
    + "standby='Loading MultiMedia' "
    + "type='application/x-oleobject'> "
    + "<param name='URL'  value='" + src + "' /> "
    + "<param name='AutoStart' value='true' /> "
    + "<param name='Loop' value='false' /> "
    + "<param name='ShowAudioControls' value='true' /> "
    + "<param name='ShowPositionControls' value='false' /> "
    + "<param name='uiMode' value='full' /> "

    // Embed for Netscape type Browsers
    + "<embed type='application/x-mplayer2' "
    + "pluginspage='http://www.microsoft.com/Windows/MediaPlayer/' "
    + "src='" + src + "' "
    + "name='MediaPlayer' "
    + "width='" + width + "' "
    + "height='" + height + "' "
    + "autostart='0' "
    + "loop='0' "
    + "ShowControls='1' "
    + "ShowAudioControls='1' "
    + "ShowPositionControls='1' "
    + "uiMode='full'>"

    + "</object>";
  
  document.getElementById(elmID).innerHTML = html;
}

function insertPlayerWM6_0(elmID, src, width, height) {
  var html;
  html = "<object id='WinMedia' "
    + "classid='CLSID:22d6f312-b0f6-11d0-94ab-0080c74c7e95' "
    + "codebase='http://activex.microsoft.com/activex/controls/mplayer/en/nsmp2inf.cab#Version=5,1,52,701' "
    + "width='" + width + "' height='" + height + "' "
    + "standby='Loading MultiMedia' "
    + "type='application/x-object'>"
    + "<param name='FileName' value='" + src + "' />"
    + "<param name='AutoStart' value='false' />"
    + "<param name='ShowControls' value='true' />"
    + "<param name='ShowAudioControls' value='true' />"
    + "<param name='ShowPositionControls' value='true' />"

    // Embed for Netscape type Browsers
    + "<embed type='application/x-mplayer2' "
    + "pluginspage='http://www.microsoft.com/Windows/MediaPlayer/' "
    + "src='" + src + "' "
    + "name='MediaPlayer' "
    + "width='" + width + "' "
    + "height='" + height + "' "
    + "autostart='0' "
    + "ShowControls='1' "
    + "ShowAudioControls='1' "
    + "ShowPositionControls='0'>"

    + "</object>";

  document.getElementById(elmID).innerHTML = html;
}

function insertPlayerWM7_0(elmID, src, width, height) {
  var html;
  html = "<object ID='WinMedia' width='" + width + "' height='" + height + "' "
    + "CLASSID='CLSID:6BF52A52-394A-11d3-B153-00C04F79FAA6' "
    + "standby='Loading MultiMedia' "
    + "type='application/x-oleobject'> "
    + "<param name='URL'  value='" + src + "' /> "
    + "<param name='AutoStart' value='false' /> "
    + "<param name='Loop' value='false' /> "
    + "<param name='ShowControls' value='true' /> "
    + "<param name='ShowAudioControls' value='true' /> "
    + "<param name='ShowPositionControls' value='false' /> "
    + "<param name='uiMode' value='full' /> "

    // Embed for Netscape type Browsers
    + "<embed type='application/x-mplayer2' "
    + "pluginspage='http://www.microsoft.com/Windows/MediaPlayer/' "
    + "src='" + src + "' "
    + "name='MediaPlayer' "
    + "width='" + width + "' "
    + "height='" + height + "' "
    + "autostart='0' "
    + "loop='0' "
    + "ShowControls='1' "
    + "ShowAudioControls='1' "
    + "ShowPositionControls='1' "
    + "uiMode='full'>"

    + "</object>";
  
  document.getElementById(elmID).innerHTML = html;
}

/**  
  END insertPlayer.js
  Workaround for IE changes due to Eolas/Microsoft Patent Infringement 
  ActiveX Patch.
**/