Use this guide to replace the front glass panel.
Stick a suction cup near each of the two top corners of the glass panel.
If your suction cups refuse to stick, try cleaning both the glass panel and the suction cup with a mild solvent.
Gently lift the glass panel perpendicular to the face of the LCD enough to clear the steel mounting pins attached along the underside of the top edge of the glass panel.
Pull the glass panel away from the lower edge of the iMac and carefully set it aside.