0
所有日期都很好。我有下面的代码有问题:flash,actionscript - 发布后,Flash文件的发布请求停止工作
textBox.addEventListener(KeyboardEvent.KEY_DOWN,handler);
function handler(event:KeyboardEvent){
// if the key is ENTER
if(event.charCode == 13){
var url:String = "http://localhost/flashsave.php";
var request:URLRequest = new URLRequest(url);
var variables:URLVariables = new URLVariables();
variables.cuvant = textBox.text;
request.data = variables;
request.method = URLRequestMethod.POST;
navigateToURL(request);
var loader:URLLoader = new URLLoader();
try {
loader.load(request);
} catch (error:Error) {
//trace("Unable to load requested document.");
}
的问题是,代码工作当我测试现场(CTR + ALT +闪光灯进入),但在我发布它不工作。 ..不发送任何请求也不重定向。
我想要做的是在服务器上登录用户输入的文件(与相关:Flash actionscript - save a text file on server)。
谢谢你的帮助。