<!--


function add_to_fav(siteurl,site_name) {
if (document.all) window.external.AddFavorite(siteurl,site_name);
else alert("Your browser doesn't support this function. Please press Ctrl");
}

function show_hide_div(state,object) {
//alert(object);
if(state) { object.style.display="block"; }
else { object.style.display="none"; }
}


function smoothHeight(id,curH,targetH,stepH,mode) {
var smooth_timer;
diff = targetH - curH;
if (diff != 0)
{ newH = (diff > 0) ? curH + stepH : curH - stepH;
  ((document.getElementById) ? document.getElementById(id) : eval("document.all['" + id + "']")).style.height = newH + "px";
  if (smooth_timer) window.clearTimeout(smooth_timer);
  smooth_timer = window.setTimeout( "smoothHeight('" + id + "'," + newH + "," + targetH + "," + stepH + ",'" + mode + "')", 20 );
}
else if (mode != "o") ((document.getElementById) ? document.getElementById(mode) : eval("document.all['" + mode + "']")).style.display="none";
}
function mini_preview(number,url) {
var tr_object = (document.getElementById) ? document.getElementById('row'+number) : eval("document.all['row"+number+"']");
var nameObj = (document.getElementById) ? document.getElementById('name'+number) : eval("document.all['name"+number+"']");
var iframe_object = (document.getElementById) ? document.getElementById('iframe'+number) : eval("document.all['iframe"+number+"']");
if (tr_object != null)
{ if (tr_object.style.display=="none")
  { tr_object.style.display="";
    if (!iframe_object.src) iframe_object.src = url;
    smoothHeight('iframe'+number,0,210,42,'o');
  }
  else smoothHeight('iframe'+number,210,0,42,'row'+number);
}
}
function mini_preview_rss(number,url) {
var tr_object = (document.getElementById) ? document.getElementById('rowrss'+number) : eval("document.all['rowrss"+number+"']");
var nameObj = (document.getElementById) ? document.getElementById('namerss'+number) : eval("document.all['namerss"+number+"']");
var iframe_object = (document.getElementById) ? document.getElementById('iframerss'+number) : eval("document.all['iframerss"+number+"']");
if (tr_object != null)
{ if (tr_object.style.display=="none")
  { tr_object.style.display="";
    if (!iframe_object.src) iframe_object.src = url;
    smoothHeight('iframerss'+number,0,210,42,'o');
  }
  else smoothHeight('iframerss'+number,210,0,42,'rowrss'+number);
}
}



function open_new_window(url,w,h,scrollbars) {
winLeft = (screen.width-800)/2; 
winTop = (screen.height-720)/2; 
new_window = window.open(url,'my_window','scrollbars='+scrollbars+',toolbar=0,menubar=0,resizable=0,dependent=0,status=0,width='+w+',height='+h+',left='+winLeft+',top='+winTop);
}

function go_to_delete(text,url) { if (confirm(text)) { location = url; } }



function DOMCall(name) {
if (document.layers) return document.layers[name];
else if (document.all) return document.all[name];
else if (document.getElementById) return document.getElementById(name);
}
function showPic (whichpic) {
DOMCall('big_image').src = whichpic.href;
if (whichpic.title) { DOMCall('image_description').innerHTML = whichpic.title; DOMCall('image_description').className = ""; } 
else { DOMCall('image_description').className = "hidden"; }
return false;
}
function clickedImage (whichpic) {
imageUrl = whichpic.src;
}


var http_request = false;
function makeRequest(url,parameters,what) {
http_request = false;
if (window.XMLHttpRequest) // Mozilla, Safari,...
{ http_request = new XMLHttpRequest();
  if (http_request.overrideMimeType) { http_request.overrideMimeType('text/html'); }
}
else if (window.ActiveXObject) // IE
{ try { http_request = new ActiveXObject("Msxml2.XMLHTTP"); }
  catch (e) { try { http_request = new ActiveXObject("Microsoft.XMLHTTP"); } catch (e) {} }
}
if (!http_request) { alert('Cannot create XMLHTTP instance'); return false; }
if (what=='poll') http_request.onreadystatechange = alertContents_poll;
else if (what=='rate_form') http_request.onreadystatechange = alertContents_rate_form;
http_request.open('GET', url + parameters, true);
http_request.send(null);
}
function alertContents_poll() {
if (http_request.readyState==4)
{ if (http_request.status==200)
  { //alert(http_request.responseText);
    result = http_request.responseText;
    document.getElementById('poll_results').innerHTML = result;            
  }
  else { alert('There was a problem with the request.'); }
}
}
function alertContents_rate_form() {
if (http_request.readyState==4)
{ if (http_request.status==200)
  { //alert(http_request.responseText);
    result = http_request.responseText;
    document.getElementById('rate_results').innerHTML = result;            
  }
  else { alert('There was a problem with the request.'); }
}
}
   
function get(obj,php_script_url) {
var getstr = "?";
for (i=0; i<obj.childNodes.length; i++)
{ if (obj.childNodes[i].tagName == "INPUT")
  { if (obj.childNodes[i].type=="hidden") { getstr += obj.childNodes[i].name + "=" + obj.childNodes[i].value + "&"; }
    if (obj.childNodes[i].type=="text") { getstr += obj.childNodes[i].name + "=" + obj.childNodes[i].value + "&"; }
    if (obj.childNodes[i].type == "checkbox")
    { if (obj.childNodes[i].checked) { getstr += obj.childNodes[i].name + "=" + obj.childNodes[i].value + "&"; } 
      else { getstr += obj.childNodes[i].name + "=&"; }
    }
    if (obj.childNodes[i].type == "radio")
    { if (obj.childNodes[i].checked)
      { getstr += obj.childNodes[i].name + "=" + obj.childNodes[i].value + "&"; }
    }
    }   
    if (obj.childNodes[i].tagName == "SELECT")
    { var sel = obj.childNodes[i];
      getstr += sel.name + "=" + sel.options[sel.selectedIndex].value + "&";
   }
}
makeRequest(php_script_url,getstr,'rate_form');
}


function openmap(url, width, height)
{
	if (width == 0)
		width =	document.body.offsetWidth * 80 / 100
	if (height == 0)
		height = document.body.offsetHeight * 80 / 100
	config = ""
	config += "left=" + (window.screenLeft + ((document.body.offsetWidth - width) / 2)) + ","
	config += "top=" + (window.screenTop + ((document.body.offsetHeight - height) / 2)) + ","
	config += "toolbar=no,"
	config += "location=no,"
	config += "directories=no,"
	config += "status=yes,"
	config += "menubar=no,"				// Not on Apple Mac for obvious reasons
	config += "scrollbars=yes,"
	config += "resizable=yes,"			// Mac windows are always resizable
	config += "copyhistory=no,"
	config += "width=" + width + ","
	config += "height=" + height
	var win = open(url, "", config)
	win.focus()
}




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;
}
function Contar(entrada,salida,texto,caracteres) {
var entradaObj=getObject(entrada);
var salidaObj=getObject(salida);
var longitud=caracteres - entradaObj.value.length;
if(longitud <= 0)
{ longitud=0;
  texto='<span class="disable"> '+texto+' </span>';
  entradaObj.value=entradaObj.value.substr(0,caracteres);
}
salidaObj.innerHTML = texto.replace("{CHAR}",longitud);
}

-->