开发者

How to add a pop-up confirmation on a web based exam?

Good day,

Hi, I'm nearly on completion on the web based exam and I wanted to add a pop-up confirmation which is "Are you sure you want to end your exam?". I needed help on scripts on this. Hope that someone could help.

FYI, I'm n开发者_如何学运维ew in this programming field. I may not understand the other terms when you guys answer my question. Please bear with my follow-up questions.

Thanks.


Like this:

  <script language="JavaScript">
  window.onbeforeunload = confirmExit;
  function confirmExit() {
        return "Are you sure you want to leave";
  }
  </script>
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜