0

I'm trying to make an online test using spring-mvc and html, css, jquery and I want to prevent the user that is doing the test from leave the test screen while doing the test. Does anybody know how I can do that?

mplungjan
  • 169,008
  • 28
  • 173
  • 236
  • since it's from a web browser, no you cant. the user can make new tabs. close the browser and do many other things. – IbraHim M. Nada Jul 31 '18 at 07:48
  • **disable the user to leave my screen** please elaborate it. Do you mean by closing browser window OR just switch the window OR minimize the window? – Vikasdeep Singh Jul 31 '18 at 07:49
  • Write your test in an .exe instead of a browser if you want to know what they're up-to. Won't stop them using 2nd PC/mobile phone to get your answers though... – freedomn-m Jul 31 '18 at 07:50
  • 3
    If this was possible, do you not think spammers/hackers/advertisers would have already done this to your browser and you wouldn't even be able to have posted this question. – freedomn-m Jul 31 '18 at 07:52
  • 1
    @freedomn-m They did, big time until the browser makers made it harder/impossible – mplungjan Jul 31 '18 at 07:53
  • There are so many ways this can be done. So no you just can prevent them 100%. You can alert them at some point though. – Ketan Vaghasiya Jul 31 '18 at 07:57
  • disable the user to leave my screen - it doesn't need to be necessarily disable (because that can't be done), but i want to somehow warn the user when he tries to switch the focus from the test screen. Can that be done? – ZoranMilicevic Jul 31 '18 at 07:57

0 Answers0