清除导航历史记录 [英] Clearing Navigation History

查看:114
本文介绍了清除导航历史记录的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述




我正在考试门户网站上.

测试"页面上具有下一个"和上一个"按钮.如果单击上一个按钮,我们需要检查问题是否得到回答.如果已回答,则应显示页面已过期"消息.否则返回上一页.

请帮助我.

问候,
Raghu

Hi,


I am working on an examination portal.

The Test page is having Next and Previous buttons. If previous button is clicked, we need to check whether the question is answered or not. If answered, Page expired message should display. Else go back to previous page.

Please help me on this.

Regards,
Raghu

推荐答案

使用会话.
如果用户回答该页面,
成功提交后,请对该页面进行会话,然后
在此会议中给予一些价值".
如果用户未回答该页面,则提供会话值= null
和页面加载事件
检查该会话值.如果为null,则必须对其进行解析;如果不为null,则检查您在问题的提交"按钮上提供的值.
如果Equall,则将其转发到您想要的页面.


回答
use the session.
if the user answer the page then,
after successfull submit make the session for that page and
give "some value" in this session.
and if the user is not answered the page then give session value= null
and on page load event
check that session value .if it is null then it has to be ansewered and if it is not then check that value that you give on the submit button of the question.
if it Equall then forward it to that page which you wanted.


on Answer
Submit button()
{
if(answer submitted)
{
session["pagename"] = "answered";
}
else
{
session["pagename"] = null or your value.
}
}




并在




and on

page load event
{
if (session["pagename"]=="answered")
{
response.redirect("your page URL");
}
else
{
//he can answer your page.
}
}



如果您有任何问题,请告诉我反馈.



if you have any problem then tell me the feedback.


这篇关于清除导航历史记录的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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