I am using GD Image and PHP to resize image files and maintain transparency. I could only get this to work reliably using PNG, which didn't seem like a problem since the flash app that will use these images can import PNGs.

If i save a PNG out of photoshop and load into my swf, it shows up as expected, no problem. However if I load a PNG generated by PHP, it shows as a flat red square. However, the PNG file when viewed in the browser, any image editing software, my OS file browser, or even the flash authoring tool, looks perfectly normal and as expected.

So the file works fine if imported into flash at author time, but renders as flat red if imported at run time.

This is really going to sink my project if I can't find a solution, any ideas at all would be much appreciated.

I've attached one of the PHP generated .PNGs and below is the painfully simple AS to load it. Paste this into a FLA in the same directory as the attached image and let me know what you see.

Thanks for your time

var clip:MovieClip = createEmptyMovieClip("clip",1);

var loader:MovieClipLoader = new MovieClipLoader();
var listen:Object = new Object();
var path:String = "wheel.png";
listen.onLoadInit = function(loaded:MovieClip){