		function check_eradio_object(url) {
			var xmlHttp;
			try {    // Firefox, Opera 8.0+, Safari
				xmlHttp=new XMLHttpRequest();
			}

			catch (e) {    // Internet Explorer
				try {
					xmlHttp=new ActiveXObject("Msxml2.XMLHTTP");
				}

				catch (e) {
					try {
						xmlHttp=new ActiveXObject("Microsoft.XMLHTTP");
					}
	
						catch (e) {
							alert("Your browser does not support AJAX!");
							return false;
						}
				}
			}

			xmlHttp.onreadystatechange=function() {
				if(xmlHttp.readyState==4) {
					eradio_obj = xmlHttp.responseText;
					process_result(eradio_obj);
				}
			}

			xmlHttp.open("GET",url+"?"+Math.random(),true);
			xmlHttp.send(null);
		}

		function process_result(eradio_obj) {
			if (eradio_obj != "false") {
				eval(eradio_obj);
				content = json_obj.a+" - "+json_obj.t;
			} else {
				content = "Loading..";
			}

			put_content("eradio_area", content);
		}

		function put_content(area, content) {
			obj = document.getElementById(area);
			obj.innerHTML = content;
		}

		function ping_eradio() {
			check_eradio_object('http://www.theclub.lv/script/eradio/');
			setTimeout("ping_eradio();", 5000);
		}

	window.onload = function() { ping_eradio(); }
