var bTranState = 0;
function fnToggle() {
    oTransContainer.filters[0].Apply();
    if (bTranState=='0') { 
		bTranState = 1;
        oDIV2.style.visibility="visible"; 
		oDIV1.style.visibility="hidden";}
    else {  
		bTranState = 0;
        oDIV2.style.visibility="hidden"; 
		oDIV1.style.visibility="visible";}
    	oTransContainer.filters[0].Play();}

function imgover(imgname)
{
	imgname.src = "../recursos/ibs_recursos/gohandbig.gif"
}

function imgout(imgname)
{
	imgname.src = "../recursos/ibs_recursos/blank.gif"
}

function imgnolink(imgname)
{
	imgname.src = "../recursos/ibs_recursos/gohandbigblue.gif"
}

function gohandover(imgname)
{
	imgname.src = "../recursos/ibs_recursos/gohandorange.gif"
}

function gohandout(imgname)
{
	imgname.src = "../recursos/ibs_recursos/gohandblank.gif"
}

function darformatoblue(boton,ancho)
{
    boton.style.borderRight     = '#FFFFFF 1px outset';
    boton.style.borderLeft      = '#FFFFFF 1px outset';
    boton.style.borderTop       = '#FFFFFF 1px outset';
    boton.style.borderBottom    = '#FFFFFF 1px outset';
    boton.style.fontWeight      = 'normal';
    boton.style.fontSize        = '11px';
    boton.style.color           = '#e8f9ff';
/*    boton.style.color           = '#FFFFC0';*/
    boton.style.backgroundColor = '#0000A0';
/*    boton.style.backgroundColor = '#5e5eff';*/
    boton.style.fontFamily      = 'Tahoma, Arial';
    if (ancho !=null)
      {boton.style.width         = ancho;}
    else
      {boton.style.width         = '90px';}
}

function formatspan(mispan, texto)
{
    mispan.style.paddingRight	 = '10px';
    mispan.style.paddingLeft     = '50px'; 
    mispan.style.filter		 = 'progid:DXImageTransform.Microsoft.Alpha(style=1,opacity=25,finishOpacity=100,startX=0,finishX=100,startY=100,finishY=0)'; 
    mispan.style.font 		 = 'bold 12px/1.3 tahoma';
    mispan.style.width		 = '80%';
    mispan.style.color		 = '#000066';
    mispan.style.height		 = '100px';
    /*mispan.style.backgroundColor = '#ffdead';*/
    mispan.innerHTML		 = texto;
}

function specialspan(mispan, texto)
{
    mispan.style.paddingRight	 = '10px';
    mispan.style.paddingLeft     = '50px'; 
    /*mispan.style.filter		 = 'progid:DXImageTransform.Microsoft.Shadow(direction=45,color=#C04000,strength=3)'; */
    mispan.style.font 		 = 'bold 16px/1.3 tahoma';
    mispan.style.width		 = '80%';
    mispan.style.color		 = '#666699'; 
    mispan.style.height		 = '100px';
    mispan.innerHTML		 = texto;
}

function fShadow(mispan)
{
    mispan.style.paddingRight	 = '10px';
    mispan.style.paddingLeft     = '10px'; 
    /*mispan.style.filter		 = 'progid:DXImageTransform.Microsoft.Shadow(direction=-45,color=#646464,strength=2) ';*/
    mispan.style.font 		 = 'normal 10pt/1.3 tahoma';
    mispan.style.width		 = '80%';
    /*mispan.style.backgroundColor = '#FFFFE0';*/
}

function formattrans(mispan, texto)
{
    /*progid:DXImageTransform.Microsoft.Shadow(direction=-45,color=#646464,strength=5)*/
    mispan.style.paddingRight	 = '10px';
    mispan.style.paddingLeft     = '10px'; 
    mispan.style.filter		 = 'progid:DXImageTransform.Microsoft.Fade(Overlap=0.5)';
    mispan.style.font 		 = 'normal 10pt/1.3 tahoma';
    /*mispan.style.width		 = '80%';*/
    /*mispan.style.color	 	 = '#0033CC';*/
    mispan.style.color		 = '#c04000';
    /*mispan.style.height		 = '50px';*/
    /*mispan.style.backgroundColor = '#000000';*/
    mispan.style.borderColor = '#000000';
    mispan.innerHTML		 = texto;
    /*mispan.style.visibility	 = 'hidden';*/
}

function doTrans(imgObj, texto) 
{
    /* imgObj.filters[0].orientation='horizontal'; */
    imgObj.style.visibility = 'visible';
    imgObj.filters[0].apply() ;
    imgObj.innerHTML = texto ;
    imgObj.filters[0].play() ;
}

function doTrans1(imgObj, texto) 
{
    /* imgObj.filters[0].orientation='horizontal'; */
    imgObj.style.visibility = 'visible';
    imgObj.filters[0].apply() ;
    imgObj.innerHTML = texto ;
    imgObj.filters[0].play() ;
}

function formatimg(imagen, path)
{
    imagen.style.filter	= 'progid:DXImageTransform.Microsoft.Fade(Overlap=0.50)' ; 
    imagen.src		= path ;
    imagen.style.visibility = 'visible';
}

function doTransImg(imgObj, texto) 
{
    imgObj.style.visibility = 'visible'
    imgObj.filters[0].apply() ;
    imgObj.filters[0].play() ;
    imgObj.src = texto ; 
}


function darformatotab(boton)
{
    boton.style.borderRight     = '#6fb0c6 3px groove';
    boton.style.borderLeft      = '#6fb0c6 3px groove';
    boton.style.fontWeight      = 'normal';
    boton.style.fontSize        = '11px';
    boton.style.borderTop       = '#6fb0c6 3px groove';
    boton.style.color           = '#454506';
    boton.style.borderBottom    = '#6fb0c6 3px groove';
    boton.style.backgroundColor = '#FFFFE0';
    boton.style.backgroundColor = '#c04000';
    boton.style.fontFamily      = 'Tahoma, Arial';
}

function darformatotabla(boton)
{
    boton.style.borderRight     = '#FFFFC0 3px groove';
    boton.style.borderLeft      = '#FFFFC0 3px groove';
    boton.style.borderTop       = '#FFFFC0 3px groove';
    boton.style.borderBottom    = '#FFFFC0 3px groove';
}


function win_float(Url, Nombre, Ancho, Alto, Menu, Resize, Scroll, Status, Titulo, Tool, Left, Top, Flag)
{
  if (Url == null) 
    { return false; }

  Ancho   = "width="      + Ancho   + "," ;
  Alto    = "height="     + Alto    + "," ;
  Menu    = "menubar="    + Menu    + "," ;
  Resize  = "resizable="  + Resize  + "," ;
  Scroll  = "scrollbars=" + Scroll  + "," ;
  Status  = "status="     + Status  + "," ;
  Titulo  = "titlebar="   + Titulo  + "," ;
  Tool    = "toolbar="    + Tool    + "," ;
  Left    = "left="       + Left    + "," ;
  Top     = "top="        + Top           ;

  Args = Ancho + Alto + Menu + Resize + Scroll + Status + Titulo + Tool + Left + Top ;

  window.open(Url,Nombre,Args);

  if (Flag != null)
    {return Flag ;}

}

function win_eval(url, logico)
{
  main_win(url);
  return logico;
}


function right(e) 
{
  if (navigator.appName == 'Netscape' && (e.which == 3 || e.which == 2))
    return false;
  else 
    if (navigator.appName == 'Microsoft Internet Explorer' && (event.button == 2 || event.button == 3)) 
    {
      window.open('ipac.web.clientes.hpolseg','','toolbar=no,menubar=no,location=no,height=340,width=400');
      return false;
    }
  return true;
}


function changeScrollbarColor()
{
  if (document.all)
    {
      document.body.style.scrollbarBaseColor = '#8080FF';
    }
}

function delScroll()
{
  if (document.all)
    {
      document.body.scroll = "no";
    }
}

function createHexArray(n)
  { 
    this.length = n;
    for (var i = 1; i <= n; i++)
    this[i] = i - 1;
    this[11] = "A";
    this[12] = "B"; 
    this[13] = "C";
    this[14] = "D";
    this[15] = "E";
    this[16] = "F";
    return this;
  }

function convertToHex(x) 
  {
    if (x < 17) x = 16;
    var high = x / 16;
    var s = high+"";
    s = s.substring(0, 2);
    high = parseInt(s, 10);
    var left = hx[high + 1];
    var low = x - high * 16;
    if (low < 1) low = 1;
    s = low + "";
    s = s.substring(0, 2);
    low = parseInt(s, 10);
    var right = hx[low + 1];
    var string = left + "" + right;
    return string;
  }

function makeRainbow(text)
  {
    text = text.substring(0, text.length);
    color_d1 = 255;
    mul = color_d1 / text.length;
    for(var i = 0; i < text.length; i++) 
      {

        color_d1 = 255*Math.sin(i / (text.length / 3));
        color_d2 = mul * i;
        k = text.length;
        j = k - i;
        if (j < 0) j = 0;
        color_d3 = mul * j;

        if (color_d1 > 160) color_d1 = 160;
        if (color_d2 > 160) color_d2 = 160;
        if (color_d3 > 160) color_d3 = 160;

        color_h1 = convertToHex(color_d3);
        color_h2 = convertToHex(color_d1);
        color_h3 = convertToHex(color_d3);

        document.write("<FONT COLOR=\"#" + color_h3 + color_h1 + color_h2 + "\">" + text.substring(i, i + 1) + "</FONT>");
      }
  }

function simpletext(text)
  {
   text = text.substring(0, text.length);
   document.write(text.substring(0, text.length));

  }




<!--
var timeout         = 200;
var closetimer		= 0;
var ddmenuitem      = 0;

// open hidden layer
function mopen(id)
{	
	// cancel close timer
	mcancelclosetime();

	// close old layer
	if(ddmenuitem) ddmenuitem.style.visibility = 'hidden';

	// get new layer and show it
	ddmenuitem = document.getElementById(id);
	ddmenuitem.style.visibility = 'visible';

}
// close showed layer
function mclose()
{
	if(ddmenuitem) ddmenuitem.style.visibility = 'hidden';
}

// go close timer
function mclosetime()
{
	closetimer = window.setTimeout(mclose, timeout);
}

// cancel close timer
function mcancelclosetime()
{
	if(closetimer)
	{
		window.clearTimeout(closetimer);
		closetimer = null;
	}
}

// close layer when click-out
document.onclick = mclose; 
// -->
