Good question. I didn't know there were "three". I just put my leg whereever it gets the best result from the horse. Only rarely in front of the girth, and only when he is not listening to me asking him to move his shoulder over, or to back up and he's getting snitty, I might put my leg more toward his shoulder, for just a sec.
This is probably different depending on discipline, so there are probably a dozen different versions, none universally correct but all with correct applications.
That disclaimer out of the way, the theory I subscribe to is leg at the girth influences the shoulders, leg slightly behind the girth influences the barrel, and leg farther behind the girth influences the haunches.
I was taught to ride and teach to never have 'chair legs' not sitting on a horse the way you would a chair and toes should always be behind the girth/cinch but not more than 6 inches from the girth. But I suppose there are a bunch of different way to ride. I think the majority rule is to keep a straight line from your ear lobe to shoulder to hip to heel. Or at least in my experience.
Assuming we're talking about English then you want your feet at the girth or a smidgen behind but never in front. In the ideal position, you should be able to draw a straight line from your shoulders, hip and heel.
I used to do this great exercise with students after they had begun riding on contact and needed to understand how to ask for a bend. I would hold one of the inexpensive very flexible school crops and ask the students how to bend it into a shallow C shape. We'd experiment with applying pressure at one or both ends and pressure in the middle and come to the conclusion that it worked best if you put pressure on the ends in one direction, and pressure in the middle in the opposite direction.
Then I'd explain to them that the stick represented the spine of the horse, that their inside hand was the pressure on the head of the stick, the outside leg well behind the girth was the pressure on the tail of the stick, and an active inside leg was the pressure on the middle, pushing the barrel of the horse outward.
Then I'd have a little fun, simulating a rider riding a circle on reins alone, with the haunches and body trailing outside the arc, or how forgetting the active inside leg would cause the horse to straighten its body and then fall in on the turn.