I've used a couple aproaches to try to combat getting the front foot in the wrong place.
1. Using a more upright stance, which gets the head back towards 'over off stump' instead of slouching which puts the head outside off.
2. Extending the line of the stumps and drawing them on the pitch with a marker, outside the crease in front of you. Then every front foot shot you play, you have a good look at exactly where your front foot is landing, relative to the stumps. This may not solve your problem, but it will make you more aware of it, and may surprise you at the extent of the problem!