if( top.frames.length == 0 )
{
    top.location="http://www.albangerhardt.com/frames.pl?path=" + document.URL;
    /* previously used window.location.pathname instead of document.URL but it didn't return blog URL vars */
}


/* -----------------------------------------------------------
    Univeral method for javascript->flash setvariable
    This script is based on the version by Mustardlab.com:
    http://www.mustardlab.com/developer/flash/jscommunication/
----------------------------------------------------------- */

/* -----------------------------------------------------------
    function flashEvent(swf, event, params)
----------------------------------------------------------- */
function flashEvent(inSwf, inEvent, inParams) {	
    
    var divcontainer = "flash_setvariables_" + inSwf;	
    if(!document.getElementById(divcontainer)){
        var divholder = document.createElement("div");
        divholder.id = divcontainer;
        document.body.appendChild(divholder);
    }
    var divinfo = "<embed src='http://www.albangerhardt.com/menu/gateway.swf' FlashVars='lc=" + inSwf + "&ev=" + escape(inEvent) + "," + escape(inParams) + "' width='0' height='0' type='application/x-shockwave-flash'></embed>";
    document.getElementById(divcontainer).innerHTML = "";
    document.getElementById(divcontainer).innerHTML = divinfo;
}
