I have this html code:
<div class="staff_options dep_0" onclick="javascript: selectDepartamento(0, 'black')">
<hr class="hr_staff dep_0" style="width:50px;">ShBarcelona<hr class="hr_staff dep_0" style="width:50px;">
</div>
<div class="staff_options dep_1" onclick="javascript: selectDepartamento(1, 'rgb(165,33,33)')">
<hr class="hr_staff dep_1" style="width:65px;">Dirección<hr class="hr_staff dep_1" style="width:65px;">
</div>
<div class="staff_options dep_2" onclick="javascript: selectDepartamento(2, 'rgb(42, 54, 199)')">
<hr class="hr_staff dep_2" style="width:47px;">Administración<hr class="hr_staff dep_2" style="width:47px;">
</div>
and the function selectDepartamento only does this:
if (id != 0){
$('.empleado_imagen').css("background-size", '0px');
$('.dep_'+id).css("background-size", '125px');
}else{
$('.empleado_imagen').css("background-size", '125px');
}
$('.staff_options').css('color', 'black');
$('.staff_options').css('font-weight', 'normal');
$('.staff_options.dep_'+id).css("color", "'"+color+"'");
$('.staff_options.dep_'+id).css("font-weight", "bold");
if !($.browser.msie){
$('.hr_staff').css('display', 'none');
$('.hr_staff.dep_'+id).css("border-color", "'"+color+"'");
$('.hr_staff.dep_'+id).css('display', 'inline-block');
}
with Google Chrome and Mozilla Firefox this works well but IE only detect onclick event when I'm using element inspector.
I don't understand because this not works. Thanks.