1. Clean it. You're not usually in a situation where you can clean the opposite side of the glass you're shooting through, but hopefully you can ensure that your side of the glass is clean and smudge-free. Even if you can't clean it effectively, at least look for an area of the glass that's as clean and gunk-free as possible.
2. Get close. You may be tempted to stand back from the glass, but actually putting your lens right up to the glass, even touching it, is the best way to minimize distortions and reflections. After all, the main problem with shooting through glass is that it acts like a mirror and reflects light back into the camera.
3. Turn off the lights. In some cases it may be impossible to control the background as you shoot through glass; but if you can turn off the lights, do so. Like looking out of a window at night, it's easier to see if the lights aren't on inside. It helps to minimize distracting reflections. If you can't control the lights, position anything dark-a cloth, a jacket, even your whole body-in such a way as to block ambient reflections from bouncing off the glass and into your lens.
4. No flash. In the continuing effort to minimize the light on your side of the glass, try not to use your flash if at all possible. It's bound to light up all sorts of imperfections in the glass, as well as lots of things on your side of the glass-creating more opportunities for distracting reflections. Worst of all, it can create a huge lens flare problem by reflecting directly back into the lens.
5. 45-degrees. Instead of shooting directly through glass (with the lens axis perpendicular to the glass surface) it's often best to rotate the camera to a 45-degree angle or more. It's an absolute must if you're forced to use a flash, and even without one it will help to eliminate the reflections of you and your camera.
6. Filter it. Polarizing filters are always handy, and shooting through glass is just another example of their versatility. At the right rotation a circular polarizer can eliminate all sorts of reflections from making their way into your D-SLR, so why not use one in this uber-reflective scenario? Best of all, by looking through the lens as it rotates you can see exactly how effective your through-the-glass shot might be.
7. Manual focus. Although it's handy on many occasions, autofocus is often a hindrance when it comes to shooting through glass. The tiniest smudges and spots, or even just the surface of the glass can trick the camera into focusing on the wrong spot. Switch to manual mode and control the point of focus by hand. There are enough other problems with shooting through glass, minimizing this one goes a long way toward increasing your chances for success.