1 /// <summary> 2 /// 弹出对话框 并且跳转界面 3 /// </summary> 4 /// <param name="page">Page或者this</param> 5 /// <param name="str">值 如'登陆成功!'</param> 6 /// <param name="url">要跳转的界面 如'admin/main.aspx'</param> 7 public static void show(Page page, string str, string url) 8 { 9 page.ClientScript.RegisterStartupScript(page.GetType(), "", "<script language=javascript>alert('" + str + "');location.href='" + url + "';</script>"); 10 }