Syntax:
public function navigateToURL(request:URLRequest, window:String = null):voidrequest 需要使用 new URLRequest(url)
window 可用的字串: _self, _blank, _top, _parent
例:
import flash.net.URLRequest; // 需使用 URLRequest 函式
import flash.net.navigateToURL;
btnGotoUrl.addEventListener(MouseEvent.CLICK, gotoUrl);
function gotoUrl(event:MouseEvent):void {
navigateToURL(new URLRequest("http://devmanna.blogspot.com/"), "_blank");
}
沒有留言:
張貼留言