An evil version of Colonel Sheppard shows up in everyones dreams. He asks if he had a goatee. In Star Trek's "Mirror, Mirror" episode, the evil version of Spock had a goatee.
McKay and Dr. Keller talk about this movie. There is also a dream sequence where some creature bursts out ot Teyla's stomach just like the alien bursts out of John Hurt.