Can homophobic policies win elections?

Can homophobic policies win elections?