Exceptions are Venus, Uranus, Pluto. The direction which most known moons revolve around their planet is the same direction as the planet rotates on its axis. We know there are two very distinct types of planets. Asteroids are VERY OLD a contain materials not found in either terrestrial or Jovian planets and their moons. Asteroids orbit very similar to planets.
Comets are very primitive.
They do not orbit in the ecliptic plane and they reside mainly in the very outer reaches of the solar system. As nebula collapses, it becomes denser and hotter and can eventually form a star at its center. The outer edges remain cooler and less dense and form a swirling region of matter that form planets and moons as by-products of the star formation. Star forming region in the nebula NCG 604, in the nearby sprial galaxy M33, as imaged by HST and the Mount Palomar telescope. The hot, dense center becomes a protostar.