如何在重定向另一个网页之前显示警告框 [英] how to display the alert box before the another web page is redirected

查看:79
本文介绍了如何在重定向另一个网页之前显示警告框的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

这是我的代码

This is my code

Response.Write("<script>alert('Registered successfully')</script>");
Response.Redirect("userlogin.aspx");



但是response.write吃了......如何解决此问题



but response.write eaten......how to solve this

推荐答案

使用
Page.ClientScript.RegisterStartupScript(this.GetType(), "Inserted", "<script>alert('Record Inserted Sucessfuly')</script>");


这篇关于如何在重定向另一个网页之前显示警告框的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆