The Ultimate Fix for Garbled Text When Flash Fetches PHP-Generated XML

I’m never one to back down from wrestling with the most bizarre problems—let’s see who comes out on top. It’s been ages since I hit an obstacle while coding, yet today I ran into a little snag—XML generated by PHP came out as garbled text when fetched with FLASH. After some digging I finally solved it. Recording it here, and also jotting down the general solution. If you also run into XML <-> FLASH garbled text, here’s a quick reference: 1. When you’re certain the XML is absolutely fine:First, FLASH reading XML and getting garbled text involves the static property System.useCodepage. Official description: “A Boolean value that tells Flash Player which code page to use to interpret external text files.” Defaults to false.

Flash