刷新网页会再次导致相同的操作 [英] refreshing a webpage causes the same action again

查看:73
本文介绍了刷新网页会再次导致相同的操作的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好,

这是我的问题.
我有一个div标签.单击某些链接后,将显示该标签.
在我的div提交按钮中,它工作正常,并显示成功添加的消息.

执行此操作后,当我单击刷新"或F5时,相同的操作再次进行并显示添加成功.

请帮帮我......

在此先感谢

Hi all,

here is my problem.
I have one div tag .this will be shown after click on certain link.
in my div submit button is there it works fine and shows the message added successfully.

after this action when i click refresh or F5 the same action is going on again and displays added successfully.

please help me out......

Thanks in advance

推荐答案

在您的Page_Load方法中执行以下操作:

In your Page_Load method do this:

if (IsPostBack)
{
    //...put your existing code here (page initialization)
}
else
{
}


这篇关于刷新网页会再次导致相同的操作的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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