coolite 獲取新的頁面連接到當前頁面指定位置Panel的運用

以下圖所示,點擊溫州市文成縣以前,右邊是一片空白,點擊後生成新的頁面html

 

html運用到了coolite的Panel控件函數

<Center>
<ext:Panel ID="PanelMain" runat="server" AutoWidth="true" AutoScroll="false" Cls="width_p_100" BodyStyle="border-left:1 solid ;width:100%" Border="false">
<AutoLoad Mode="IFrame" ShowMask="true" MaskMsg="加載中,請稍候..." Url="" Scripts="true" NoCache="false" />
<%--<Body>
<div>
<iframe scrolling="auto" frameborder="0" width="100%" height="100%" id="frame1"></iframe>
</div>
</Body>--%>
</ext:Panel>
</Center>ui

js運用到panel的一些特性,函數setUrl調用新的頁面連接到當前頁面指定位置url

function setUrl(purl) {
PanelMain.autoLoad.url = purl;
PanelMain.autoLoad.mode = "iframe";
PanelMain.autoLoad.showMask = true;
PanelMain.autoLoad.maskMsg = "加載中,請稍等...";
PanelMain.reload();
}debug

函數look調用了setUrl函數server

function look(cgguid, flag, path, drlx) {
debugger;
var url = "";
var drlj = "";
switch (drlx) {
case "01": drlj = "/JccgFilesStore/"; break;
case "02": drlj = "/NdcgFilesStore/"; break;
case "03": drlj = "/NdgxcgFilesStore/"; break;
default:
drlj = "/NdcgFilesStore/";
break;
}
switch (flag) {
case "tif"://圖片
case "jpg":
case "jpeg":
case "png":
case "gif": url = "ShowImgPage.aspx?cgguid=" + cgguid + "&path=" + path + "&drlx=" + drlx; break;
case "txt": url = "ShowTxtPage.aspx?cgguid=" + cgguid + "&drlx=" + drlx; break;
case "doc":
case "docx":
case "xls":
case "xlsx": url = "ShowOfficePage.aspx?cgguid=" + cgguid + "&fileExt=" + flag+"&drlx="+drlx; break;
default: //pdf
//url = "http://" + window.location.host + "/JccgFilesStore/" + path;
url = drlj + path;
break;
}
setUrl(url);
}htm

相關文章
相關標籤/搜索