jquery.attr method was not correctly used and caused bugs like for instance  #463