    function wybierzwojewodztwo(id)
    {
        var object = getObject('mapka');
        var object2 = getObject('mapka_embed');
        var wojew = getObject('wojew');
        var wojewh = getObject('wojewh');
        if(wojew != null) wojew.selectedIndex = id;
        if(wojewh != null) wojewh.setAttribute('value',id);
        if(object != null) object.FlashVars='id='+id;
        if(object2 != null)
        {
            object2.FlashVars='id='+id;
            object2.setAttribute('FlashVars', 'id='+id);
            //alert(object2.getAttribute('FlashVars'));
        }
    }

    function getObject(obj) {
        var theObj;
        if(document.all) {
            if(typeof obj=="string") {
                return document.all(obj);
            } else {
                return obj.style;
            }
        }
        if(document.getElementById) {
            if(typeof obj=="string") {
                return document.getElementById(obj);
            } else {
                return obj.style;
            }
        }
        return null;
    }

