function removeString(s, t) {

  i = s.indexOf(t);
  r = "";
  if (i == -1) return s;
  r += s.substring(0,i) + removeString(s.substring(i + t.length), t);
  return r;
  }

function AlternarImagen(img) {
	var searchString = '_ON';
	var imgSrc = img.src.toUpperCase();
	var index = imgSrc.indexOf(searchString);

	if ( index > 0 ) {
      img.src = removeString(imgSrc, searchString);

      //img.src = imgSrc.substring(0,imgSrc.indexOf(searchString)) + remove(imgSrc.substring(i + searchString.length), searchString);
	} else {

	  var ext = imgSrc.substring(imgSrc.length-4, imgSrc.length );

      var leading = imgSrc.substring(0, imgSrc.length-4);

      var trailing = imgSrc.substring(imgSrc.length-4, imgSrc.length);

	  img.src = leading + searchString + trailing;
	}
}


var menuItems =
[

['Perfil Institucional',"/perfil","","","","_self","0", , , , , ],
['|Mensaje Presidente Ejecutivo',"/perfil/msg_presid_ejec.html","","","","_self","1","0" , , , , ],
['|Qué es el IMAS',"/perfil/que_es_el_imas.html","","","","_self","1","0" , , , , ],
['|Reseña Histórica',"/perfil/resena_historica.html","","","","_self","1","0" , , , , ],
['|Misión y Visión',"/perfil/mision y vision.html","","","","_self","1","0" , , , , ],
['|Valores',"/perfil/valores.html","","","","_self","1","0" , , , , ],
['|Objetivos',"/perfil/objetivos.html","","","","_self","1","0" , , , , ],
['|Leyes, Decretos y Normativas',"/perfil/leyes_decretos_y_normativas.html","","","","_self","1","0" , , , , ],
['|Organización Institucional',"/perfil/organizacion_institucional.html","","","","_self","1","0" , , , , ],
['|Preguntas Frecuentes',"/perfil/preguntas_frecuentes.html","","","","_self","1","0" , , , , ],
['|Sistema de Información',"/perfil/sist_info","","","","_self","1","0" , , , , ],
['||SIPO',"/perfil/sist_info/sipo","","","","_self","1","0" , , , , ],
['|||Acceso a consultas SIPOWEB',"http://201.196.49.41:8080/Fis/Login.html","","","","_blank","1","0" , , , , ],
['|||Información General SIPO',"/perfil/sist_info/sipo/info_general.html","","","","_self","1","0" , , , , ],
['|||Investigación Social',"/perfil/sist_info/sipo/investigacion_social.html","","","","_self","1","0" , , , , ],
['|||Estadisticas SIPO',"/perfil/sist_info/sipo/estadisticas_sipo.html","","","","_self","1","0" , , , , ],
['|||Mapas de Pobreza en Costa Rica',"/perfil/sist_info/sipo/mapas_pobreza.html","","","","_self","1","0" , , , , ],
['||Sistemas de Información',"/perfil/sist_info/sistemas_de_informacion.html","","","","_self","1","0" , , , , ],
['||Tecnología de Información',"/perfil/sist_info/tecnologia_informacion.html","","","","_self","1","0" , , , , ],
['||Graficos, Mapas y Estadisticas',"/perfil/sist_info/GphMapEstad.html","","","","_self","1","0" , , , , ],
['|Centro de Prensa',"/perfil/prensa","","","","_self","1","0" , , , , ],
['||cp_sala_de_prensa',"/perfil/prensa/cp_sala_de_prensa.html","","","","_self","1","0" , , , , ],
['||Galería Fotográfica',"/perfil/prensa/cp_galeria_fotografica.html","","","","_self","1","0" , , , , ],
['||Revista últIMAS',"/perfil/prensa/cp_boletin_Nuestro_Rostro.html","","","","_self","1","0" , , , , ],
['||Informes De Gestión',"/perfil/prensa/cp_informes_gestion.html","","","","_self","1","0" , , , , ],
['Programas Sociales',"/prog_soc","","","","_self","0", , , , , ],
['|Programa Nacional de Voluntariado',"/oficinas/centrales/ibs/pn_voluntariado.html","","","","_self","1","0" , , , , ],
['|Beneficios Grupales',"#","","","","_self","1","0" , , , , ],
['||Emprendimientos Productivos Grupales',"/prog_soc/Beneficios Grupales/bg_emprend_prod_grup.html","","","","_self","1","0" , , , , ],
['||Infraestructura Comunal',"/prog_soc/Beneficios Grupales/bg_infraest_comunal.html","","","","_self","1","0" , , , , ],
['||Infraestructura Educativa',"/prog_soc/Beneficios Grupales/bg_infraest_educativa.html","","","","_self","1","0" , , , , ],
['||Beneficios IBS',"/oficinas/centrales/ibs/IBS_Beneficios.html","","","","_self","1","0" , , , , ],
['|Beneficios Individuales',"#","","","","_self","1","0" , , , , ],
['||Avancemos',"/prog_soc/beneficios_ind/ps-avancemos.html","","","","_self","1","0" , , , , ],
['||Bienestar Familiar',"/prog_soc/beneficios_ind/bi_bienestar_familiar.html","","","","_self","1","0" , , , , ],
['||Capacitación',"/prog_soc/beneficios_ind/bi_capacitacion.html","","","","_self","1","0" , , , , ],
['||Emergencias',"/prog_soc/beneficios_ind/bi_emergencias.html","","","","_self","1","0" , , , , ],
['||Emprendimientos Productivos Individuales',"/prog_soc/beneficios_ind/bi_emprend_prod_indiv.html","","","","_self","1","0" , , , , ],
['||Gastos Implementación Mejoramiento Vivienda',"/prog_soc/beneficios_ind/bi_gastos_impl_mejor_viv.html","","","","_self","1","0" , , , , ],
['||Incentivos Participación Servicios Comunales',"/prog_soc/beneficios_ind/bi_incent_partic_srv_comunal.html","","","","_self","1","0" , , , , ],
['||Levantamiento de Limitaciones',"/prog_soc/beneficios_ind/bi_levantamiento_limitac.html","","","","_self","1","0" , , , , ],
['||Mejoramiento de Vivienda',"/prog_soc/beneficios_ind/bi_mejoramiento_vivenda.html","","","","_self","1","0" , , , , ],
['||Segregación de Lotes',"/prog_soc/beneficios_ind/bi_segregacion_lote.html","","","","_self","1","0" , , , , ],
['||Titulación de Tierras',"/prog_soc/beneficios_ind/bi_titulacion_propiedades.html","","","","_self","1","0" , , , , ],
['||Veda',"/prog_soc/beneficios_ind/bi_veda.html","","","","_self","1","0" , , , , ],
['|FIDEICOMISO',"/prog_soc/Fideicomiso/Fideicomiso.mod.html","","","","_self","1","0" , , , , ],
['Oficinas',"#","","","","_self","0", , , , , ],
['|Oficinas Regionales',"/oficinas/gen_reg/gerencias_regionales.html","","","","_self","1","0" , , , , ],
['||Gerencia Regional Alajuela',"/oficinas/gen_reg/gr_aj.html","","","","_self","1","0" , , , , ],
['||Gerencia Regional Brunca',"/oficinas/gen_reg/gr_br.html","","","","_self","1","0" , , , , ],
['||Gerencia Regional Cartago',"/oficinas/gen_reg/gr_cg.html","","","","_self","1","0" , , , , ],
['||Gerencia Regional Guanacaste',"/oficinas/gen_reg/gr_gt.html","","","","_self","1","0" , , , , ],
['||Gerencia Regional Heredia',"/oficinas/gen_reg/gr_hd.html","","","","_self","1","0" , , , , ],
['||Gerencia Regional Huetar Norte',"/oficinas/gen_reg/gr_hn.html","","","","_self","1","0" , , , , ],
['||Gerencia Regional Limón',"/oficinas/gen_reg/gr_ln.html","","","","_self","1","0" , , , , ],
['||Gerencia Regional Noreste',"/oficinas/gen_reg/gr_ne.html","","","","_self","1","0" , , , , ],
['||Gerencia Regional Puntarenas',"/oficinas/gen_reg/gr_pt.html","","","","_self","1","0" , , , , ],
['||Gerencia Regional Suoreste',"/oficinas/gen_reg/gr_so.html","","","","_self","1","0" , , , , ],
['|Centrales',"#","","","","_self","1","0" , , , , ],
['||Archivo Central',"/oficinas/centrales/archivo_central.html","","","","_self","1","0" , , , , ],
['||Auditoria Interna',"/oficinas/centrales/auditoria.html","","","","_self","1","0" , , , , ],
['||Contraloría de Servicios',"/oficinas/centrales/contraloria_de_servicios.html","","","","_self","1","0" , , , , ],
['||Centro de Información y Recursos - CIRE',"/oficinas/centrales/cire.html","","","","_self","1","0" , , , , ],
['||Comisión de Donaciones',"/oficinas/centrales/donaciones.html","","","","_self","1","0" , , , , ],
['||Instituciones de Bienestar Social (IBS)',"/oficinas/centrales/ibs/IBS_index.html","","","","_self","1","0" , , , , ],
['||Plataforma de Servicios',"/oficinas/centrales/plataforma_servicios.html","","","","_self","1","0" , , , , ],
['||Recursos Humanos',"/oficinas/centrales/recursos_humanos.html","","","","_self","1","0" , , , , ],
['||Proveeduría',"/oficinas/centrales/proveeduria/01-prov-Pagina principal.html","","","","_self","1","0" , , , , ],
['|Duty Free',"http://dutyfree.imas.go.cr/","","","","_blank","1","0" , , , , ],
['Transparencia',"/transparencia","","","","_self","0", , , , , ],
['|Transparencia',"/transparencia/index.html","","","","_self","1","0" , , , , ],
['|Actas Concejo Directivo',"/transparencia/actascd/actas_CD.html","","","","_self","1","0" , , , , ],
['Contáctenos',"/contactenos","","","","_self","0", , , , , ],
['|Directorio Correo Electrónico',"/contactenos/directorio_correo_electronico.html","","","","_self","1","0" , , , , ],
['|Formulario Interactivo',"/contactenos/formulario.html","","","","_self","1","0" , , , , ],
['|Directorio Telefónico',"/contactenos/Directorio Telefonico IMAS.html","","","","_self","1","0" , , , , ],
['Mapa del Sitio',"/mapasitio.html","","","","_self","0", , , , , ],


];
