- Open the original image.
- Set a proper background colour as oposed to it being transparent. It is best to make this colour similar to the background colour of the website to generate the antialiasing in your image borders in order for the image to blend nicely.
- Flatten the image (Image - Flatten image).
- Add an alpha channel (Layer - Transparency - Add alpha channel).
- Select the background color (Selection - By color).
- Clear the background colour (Edit - Clear).
- Convert the image to indexed color (Image - Mode - Indexed color).
- Save the image to the final PNG file (File - Save as) and remember to check: Save color values from transparent pixels.
Thank you Matthew!
P.S. And yes, there are still people out there using IE6.