// Apply :hover effect to menu (ie6 hack)
$(document).ready(function(){

	// externals
	$("a[rel=external]").attr('target', '_blank');

	// ocults
	$(".hidden").hide();

	// dropdown :hover for ie
	$('#pagina #cuerpo #menu ul li').mouseover(function(){
		// hide all opened 'submenus'
		$('#pagina #cuerpo #menu ul li').removeClass('hovered');
		// set LI's class
		$(this).addClass('hovered');
	});
	$('#pagina #cuerpo #menu ul li ul').mouseout(function(){
		// remove LI's class
		$(this).parent().removeClass('hovered');
	});

	$('ul.cycle', '#contenido').cycle();

	// replace antispam in emails
	$("a[href*='(ELIMINAR)']").each(function(i) {
		omg = $(this).attr('href');
		omg2 = $(this).text();
		$(this).attr('href', omg.split('(ELIMINAR)').join(''));
		$(this).text(omg2.split('(ELIMINAR)').join(''));
	});
	$("a[href*='(DELETE)']").each(function(i) {
		omg = $(this).attr('href');
		omg2 = $(this).text();
		$(this).attr('href', omg.split('(DELETE)').join(''));
		$(this).text(omg2.split('(DELETE)').join(''));
	});

});
