Step 1: The problems appear
Step 2: Make a miter guide
Step 3: To use it
Step 4: Another way to use it
Step 5: A bigger, more substantial guide
Because of the way this guide works, the left member of a miter joint is cut from the right side of the guide, and vice versa.
If you wish, one of the fences could be made slightly adjustable, just in case your miters are not quite perfect the first time you use the guide.
(I would have shown a photo of the guide I made and have used, but my guide has disappeared and I cannot find it, so I made this illustration with Google Sketch-Up.)