request:URLRequest — URLRequest 对象,指定要导航到哪个 URL。
window:String (default = null) — 浏览器窗口或 HTML 帧,其中显示 request 参数指示的文档。可以输入某个特定窗口的名称,或使用以下值之一:
* "_self" 指定当前窗口中的当前帧。
* "_blank" 指定一个新窗口。
* "_parent" 指定当前帧的父级。
* "_top" 指定当前窗口中的顶级帧。
var requestUrl:URLRequest = new URLRequest(url);
var variables:URLVariables = new URLVariables();//带参数
var ids:String="";
for each(var task:BaBuildrequiresite in quireList){
ids += task.brsiteId+",";
}
variables.activename="build";
variables.ids=ids;
//variables.siteName=siteName.text;
variables.btbindex=btbindex;
if(mapregion.selected){//当前地图范围过滤/
variables.region="region";
variables.xmin=map.extent.xmin;
variables.xmax=map.extent.xmax;
variables.ymin=map.extent.ymin;
variables.ymax=map.extent.ymax;
}
requestUrl.data = variables;
requestUrl.method=URLRequestMethod.POST;//指定提交方式
navigateToURL(requestUrl, "_self");
本文介绍如何使用Flash AS3中的URLRequest对象进行页面导航,包括设置请求参数、提交方式及目标窗口等内容。
205

被折叠的 条评论
为什么被折叠?



