如何在java中打开局部视图“window.open()” [英] How to Open a Partial View in java "window.open()"
本文介绍了如何在java中打开局部视图“window.open()”的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
嗨
i想在window.open()java脚本方法中打开局部视图
like:window.open('/ docs / Calculator / Calculator.html',PopupWindow,'width = 500px,height = 500px,top = 150,left = 250');
怎么可能请帮我
hi
i want to open a partial view in window.open() java script method
like: window.open('/docs/Calculator/Calculator.html', "PopupWindow", 'width=500px,height=500px,top=150,left=250');
how it possible pls help me
推荐答案
创建一个控制器或者你可能已经创建了
create a controller or you may be you have already created as
public PartialViewResult ShowPopup()
{
return PartialView();
}
ShowPopup是你的页面名称。
传递网址为
ShowPopup is yor page name.
pass url as
window.open('@Url.Action("ShowPopup", "PopupController")', "PopupWindow", 'width=500px,height=500px,top=150,left=250');
我解决了它
window.open('@ Url.Action (ActionName,ControllerName)',PopupWindow,width = 500px,height = 500px,top = 150,left = 250');
I solve it
window.open('@Url.Action("ActionName", "ControllerName")', "PopupWindow", 'width=500px,height=500px,top=150,left=250');
这篇关于如何在java中打开局部视图“window.open()”的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文