Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

JavaScript

detecting print screen

i am creating a web-app where students have to type their assignments and submit their assignments, but they might also copy

so what i have done: the website would detect the print screen key, (but screenshot will be successful) as a result the person who is taking screenshot would lose the entire assignment and the assignment saved in server would be destroyed and logged out, so out of frustration students don't take screenshot (the text-area would be of medium size so that entire assignment's screenshot isn't taken), is this a good idea? if no, can there be any other alternative

4 Answers

What will keep them from doing their assignments on their laptops, paste them into your website for submission, and then give copies to their friends? Or take a photo with their phone and send it to their friends?

if the basic policy of our college is not to allow students to paste from external source, so only option is that the students must type in their assignments, and no pasting.

sir, i am just concerned with screenshot , would this technique be okay for screenshots? (shots from phone are excluded)

if the basic policy of our college is not to allow students to paste from external source, so only option is that the students must type in their assignments, and no pasting.

sir, i am just concerned with screenshot , would this technique be okay for screenshots? (shots from phone are excluded)

Can they work on their own laptops? If so, what keeps them from giving a copy to their friends?

If they are going to cheat, why do you think they will observe a rule like "no pasting"?

yes they can work on their laptops,

when a student gives a copy to their friends, those friends might directly cut,copy and then paste it. so the college demands that the students deal with their assignments without copying from others and do those themselves.

for images, students can draw diagrams the rule 'no-pasting' is observed again to prevent them from cheating, so that they don't blindly copy and paste and not deserve those marks allotted.

so, would it be a good idea to delete those assignments automatically if screenshot is detected (As a punishment)