/*==================================================================================*
 * This script was made in order to embad flash objects without the gray border     *    
 *                                                                                  *
 * Written by: Idan Doitch                                                          *
 * Date: July 2007                                                                  *
 *                                                                                  *
 *==================================================================================*/

    function addFlashObj(targetObj, flashIdObj, fileName, width, height){
            var objHtml = "";    
       //     debugger
            objHtml += "<object classid='clsid:d27cdb6e-ae6d-11cf-96b8-444553540000' codebase='http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,0,0' width='" + width + "' height='" + height + "' id='" + flashIdObj + "' align='middle'>";
            objHtml += "<param name='allowScriptAccess' value='sameDomain' />";
            objHtml += "<param name='allowFullScreen' value='false' />";
            objHtml += "<param name='movie' value='" + fileName + "' />";
            objHtml += "<param name='quality' value='high' />";
            objHtml += "<param name='bgcolor' value='#0D0E16' />";
            objHtml += "<param name='wmode' value='opaque' />";
            objHtml += "<embed src='" + fileName + "' quality='high' bgcolor='#0D0E16' width='" + width + "' height='" + height + "' name='" + flashIdObj + "' align='middle' allowscriptaccess='sameDomain' allowfullscreen='false' type='application/x-shockwave-flash' pluginspage='http://www.macromedia.com/go/getflashplayer' wmode='opaque' />";
            objHtml += "</object>";
         
         var objParEl = document.getElementById(targetObj);
         objParEl.innerHTML = objHtml;
        
    } 
    
    // after load  the  flash we focused this  element
    function FocusField(Field)
    {
    document.getElementById(Field).focus();
    }
