The sun and moon are not planets when you consider the objects in space they orbit. For the sun to be a planet, it would have to orbit another sun. Although the sun is in a orbit, it moves around the center of mass of the Milky Way galaxy, not another star.