Fix Safari 6 issues