Properly detect what browser you are dealing with