fixes https probs with jquery