看板 Flash 關於我們 聯絡資訊
※ 引述《tk5301 (小豬)》之銘言: : 執行都會出現以下錯誤 : Error #2044: 未處理的 IOErrorEvent:。 text=Error #2035: 找不到 URL。 : 底下是一些程式碼 : import flash.net.URLRequest; : import flash.net.URLVariables; : import flash.net.URLLoader; : import flash.events.Event; : var url:String="http://project.tkmspace.com/magic/getQueandAns1.php"; : var urlRQ:URLRequest=new URLRequest(url); : urlRQ.method=URLRequestMethod.POST; : var dataLength:Number=0; : var LDR:URLLoader=new URLLoader(); : LDR.load(urlRQ); : 希望大家能幫幫忙 這是後續的程式碼 LDR.addEventListener(Event.COMPLETE,abc); function abc(e:Event):void{ var getVars:URLVariables = new URLVariables(e.target.data); dataLength=parseInt(getVars.Count); queID=new Array(); queID=getVars.Id.split("^"); queID.addEventListener(Event.COMPLETE,ff); } function ff(event:Event):void { var lldr:Loader; lldr = new Loader(); lldr.load(new URLRequest(queID[1])); bg_mc.addChild(lldr); } 如果把前面載入路徑改成http://localhost/getQueandAns1.php 這樣可行嗎?? -- ※ 發信站: 批踢踢實業坊(ptt.cc) ◆ From: 163.17.133.18
pm2001:localhost...... 07/25 16:44
tk5301:LOCALHOST 怎麼了嗎?? 07/25 17:40
chengchieh:把queID[1]給trace出來吧...看實際去call哪個address 07/25 17:55
chengchieh:localhost是你機器上的http server path 07/25 17:56
chengchieh:要看你是要讀本機還是前面的網站上的 07/25 17:57
leenl:這問題我早在知識加就回答他,code都沒問題正常讀出php內容 07/28 15:42