I have developed a Facebook application using Flash as3. In this application when ever the user finished the test, a certificate URL is posted on user wall. the url is encode with Turkish character user first name and user last name.In certificate swf file it reads the url and display the user name on the jpg. This work great with English users but the problem arrives when the user name is in Turkish. I am attaching the jpg of the main problem, you can clearly see the url is looking good, but when i copy past the url i get the same result as display on the picture.

My Certificate Swf code is
package {
import flash.display.MovieClip;
import flash.net.URLLoader;
import flash.net.URLVariables;
import flash.external.ExternalInterface;
import com.adobe.images.JPGEncoder;
public class main extends MovieClip {
public function main() {
valuePairs = new Array();
nextValuePare = new Array();
var search:String = ExternalInterface.call("window.location.href.toString");
//var vars:URLVariables = new URLVariables(search);
valuePairs = search.substring(search.indexOf("?")+1).split("&");
trace(valuePairs);
var map:Object = new Object();
for (var i:int = 0; i<valuePairs.length; i++)
{
nextValuePare = valuePairs[i].split("=");
trace(nextValuePare);
map[nextValuePare[0]] = nextValuePare[1];
}
picture.fbookName.text = String(map["fName"]) +" "+ String(map["lName"]);
}
private var _urlLoader:URLLoader;
private var _urlVariable:URLVariables;
private var valuePairs:Array;
private var nextValuePare:Array
}
}
You should URL encode your URL with the top level function encodeURI(). Then in the swf that extracts the names from the URL use decodeURI().