Food always passes down the gut, irrespective of our position. Food is pushed downwards from the oesophagus by the rhythmic contraction of the muscles of the oesophagus. This movement is called peristalsis, which does not allow the food to flow in the reverse direction. This is why we can swallow food when we are upside down on the Earth. Similarly, astronauts in a spaceship have no difficulty in swallowing food even if they are upside down.