Fixing some cross browser incosistencies