Why do Planets Orbit the Sun?

Planets orbit around the sun because of its massive gravitational pull. The planets have a continuous velocity from the time the solar system formed, and if there was no sun for them to revolve around, they would travel in a straight line.