你的位置:首页 > 软件开发 > ASP.net > MVC弹出子页面向父页面传值

MVC弹出子页面向父页面传值

发布时间:2015-07-30 15:00:13
实现思路是使用js在父子页面间传值视图一代码,父页面@{ ViewBag.Title = "Index";}<script type="text/javascript"> //alert("1"); f ...

实现思路是使用js在父子页面间传值

视图一代码,父页面

@{  ViewBag.Title = "Index";}<script type="text/javascript">  //alert("1");  function test()  {    get='_blank'>window.showModalDialog('test/listtest', 'newwindow', 'height=400,width=400,top=0,left=0,toolbar=no,menubar=no,scrollbars=no,resizable=yes,location=no, status=no')    var temp = window.showModalDialog('test/listtest', 'newwindow', 'height=400,width=400,top=0,left=0,toolbar=no,menubar=no,scrollbars=no,resizable=yes,location=no, status=no')    document.getElementById("test").value = temp;  }</script><h2>@ViewData["Message"]</h2><p><input type="submit" value="submit" onclick="test()"></p><p><input type="text" id="test"></p>

原标题:MVC弹出子页面向父页面传值

关键词:mvc

mvc
*特别声明:以上内容来自于网络收集,著作权属原作者所有,如有侵权,请联系我们: admin#shaoqun.com (#换成@)。