jquery +struts2 路径跳转问题

feifei694893239 2010-11-03 10:31:29
//删除按钮按下
function delPurchase(purId){
alert(purId);
if(confirm("确实要删除端口信息么?")){
window.location="{applicationScope.rootpath}/purchase/purchase_delPurchaseInfo.action&purId="+purId;
}else{
}

}
这样写路径有问题么???
...全文
96 2 打赏 收藏 转发到动态 举报
写回复
用AI写文章
2 条回复
切换为时间正序
请发表友善的回复…
发表回复
tianshi1017 2010-11-03
  • 打赏
  • 举报
回复
[Quote=引用 1 楼 singlesteven 的回复:]
HTML code

<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>
function delPurchase(purId){
……
[/Quote]
+1
singlesteven 2010-11-03
  • 打赏
  • 举报
回复

<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>
function delPurchase(purId){
alert(purId);
if(confirm("确实要删除端口信息么?")){
window.location="{<%=basePath %>purchase_delPurchaseInfo.action&purId="+purId;
}else{
}

}

这样最好,

81,095

社区成员

发帖
与我相关
我的任务
社区描述
Java Web 开发
社区管理员
  • Web 开发社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧