asp.net core弹出对话框最佳实践

浪淘沙11个月前后端182
 public void OnGet()
 {         
     TempData["AlertMessage"] = "操作成功!";     

 }
@if (TempData["AlertMessage"] != null)
{
    <script>
        alert('@Html.Raw(TempData["AlertMessage"])');
        var p=parent.layer.getFrameIndex(window.name); parent.layer.close(p); parent.location.reload();
    </script>
}


相关文章

asp.net core razor 写入读取cookie集合

@{     Layout = null; } <form method="post">...

HttpClient 远程post,获取数据并对数组进行处理

using System.Text.Json; namespace xxtsoft.Web.Entry.Pages.sysadmins.ansyc {  &nb...

SqlSugar

   var dt = _db.SqlQueryable<object>("select * fr...

asp.net core Razor 部门视图Partial Views 用法

1、在/Pages/Shared/目录下创建设视图文件 _top.cshtml2、在razor页面中进行引用@await Html.PartialAsync("_top&...

文件上传

@page @model xxtsoft.Pages.uploadModel @{    } <h1>@ViewData["Title...

asp.net core 对datatable 中的内容 组装a1,a2,a3

var fzlm_name = string.Join(",",       &...

发表评论    

◎欢迎参与讨论,请在这里发表您的看法、交流您的观点。