if(typeof SWFObject == 'undefined'){document.write('<script src="http://old.astrostar.ru/js/swfobject.js" type="text/javascript"></script>')};
function Rich(id,href,src,w,h,bg){
	if(window.opera) return false;
	bg = bg||'#000000'
	document.write('<span id="'+id+'">&nbsp;</span>');
	var so = new SWFObject(src, 'swf_'+id, w, h, '6', bg);
	so.write(id);
	el = document.getElementById(id);
	el.style.position = 'absolute';
	el.style.left = '50%';
	el.style.left = (el.offsetLeft - el.offsetWidth/2)+'px';
	el.style.marginTop = '50%';
	el.style.zIndex = '999999';
	if(el){
	var f = function(){
	// Bugfix: do not move menu for IE Mac //if (browser.isMac && browser.isIE) return false;
		var top;
		if (!el) return false;
		var current = parseInt(el.style.top);
		if (window.innerHeight)
			top = window.pageYOffset;
		else if (document.documentElement && document.documentElement.scrollTop)
			top = document.documentElement.scrollTop;
		else if (document.body)
			top = document.body.scrollTop;
		if (current != top){
			top += -el.offsetHeight;
			el.style.top = top + "px";
		}
	};
	var pwos = window.onscroll;
	window.onscroll = function(){
		if(pwos) pwos();
		f();
	}
	window.setInterval(f, 500);}
	window['swf_'+id+'_FSCommand'] = window['swf_'+id+'_DoFSCommand'] = function(c,a){
		if(c == 'click'){
			window.open(href,'_blank')
		} else if(c == 'kill') {
			el.style.display = 'none';
		}
	}
	if (navigator.appName && navigator.appName.indexOf("Microsoft") != -1 && navigator.userAgent.indexOf("Windows") != -1 && navigator.userAgent.indexOf("Windows 3.1") == -1) {
		document.write('<script language=\"VBScript\"\>\n');
		document.write('On Error Resume Next\n');
		document.write('Sub swf_'+id+'_FSCommand(ByVal command, ByVal args)\n');
		document.write('	Call swf_'+id+'_DoFSCommand(command, args)\n');
		document.write('End Sub\n');
		document.write('</s'+'cript>\n');
	}
}
