// JavaScript Document
function openWindow() {
//remote=window.open("","popupwin","scrollbars=yes,resizable=yes,width=435,height=445");
//if (remote.opener == null) remote.opener = window;
return openWindowWithName("popupwin");
}
function openWindowWithName(windowname) {
remote=window.open("",windowname,"scrollbars=yes,resizable=yes,width=435,height=445,top=30,left=30");
if (remote.opener == null) remote.opener = window;
if (window.focus){remote.focus()}
return false;
}

function writeFlash(mov,w,h,extra) {
  var object = '<div style="margin:0;padding:0;position:relative;top:0; "><object classid=\"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000\" ';
  object = object + 'codebase=\"http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,29,0\" ';
  object = object + 'width=\"'+w+'\" height=\"'+h+'\">\n';
  var param = '<param name=\"movie\" value=\"'+mov+'?'+extra+'\">\n';
  param = param + '<param name=\"quality\" value=\"high\">\n';
  param = param + '<param name=\"wmode\" VALUE=\"opaque\">\n';  
  var embed = '<embed src=\"'+mov+'?'+extra+'\" quality=\"high\" ';
  embed = embed + 'pluginspage=\"http://www.macromedia.com/go/getflashplayer\" ';
  embed = embed + 'type=\"application/x-shockwave-flash\" width=\"'+w+'\" height=\"'+h+'\"></'+'embed></'+'object></div>';
  document.write(object+param+embed);
}
