[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 172
  • Last Modified:

keyboard and browser autorisation Control

I am creating a html page that I would to assign some privilage to some user with will access my website.

How can I not to let user to print any document from my webpage?
example :
 1) disable CTRL + P;
 2) hide Print option from the menu;
 3) right click function.

except ---> watermark on page
0
cwteoh
Asked:
cwteoh
  • 3
  • 3
  • 3
  • +5
1 Solution
 
CJ_SCommented:
You cannot. There are a LOT of ways to print a website.

regards,
CJ
0
 
dorwardCommented:
Even if you did the above they could save the page and edit out the annoyances.

If you put content on the web then people can do what ever they want with it, your only recourse is the law (and I would expect the printing out of hard copies to fall under fair use)
0
 
LeathCommented:
the only way not to allow every user to copy or print the site is to secure it by password... but so only authorized people are able to view your site... and i don't know if it's that, what you want... i don't think so.

Leath
0
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
webwomanCommented:
There's no way to keep them from printing your site. You can't disable CNTRL-P, you can't stop them from copying, and you can't stop them from doing a screen capture and printing that.

However, if you want to make it harder for them to print from the browser (does nothing for a screen capture), set it as white text on a dark background. Most default browser settings are not to print the background, and that includes background colors. While you can change this, most people don't, and a lot wouldn't even know how. When you set white type on a dark background, what prints is white type -- which is actually nothing.

It's hardly foolproof, since the user can change their settings and get it to print just fine. But if you have a relatively average, only slightly computer literate audience, it's an easy way to confuse people. ;-)  
0
 
cwteohAuthor Commented:
any one how to disable CTRL-P and right-click function???
0
 
dorwardCommented:
It is not possible to reliably disable any browser function whatsoever.

The unreliable methods simply annoy the end user.

Don't try it - you will lose visitors.
0
 
LeathCommented:
here is a little javascript to deactivate the right-click... BUT it's just working with ie and not with netscape... (at least not with netscape 6... i didn't test it with older versions, so i don't know... but i think it won't work there, too...?):


(copy it into the <head>-section...)

<SCRIPT language=Javascript>
function noclick()
{
if (event.button==2)
  {
  alert( '... your message ...')
  }
}
document.onmousedown=noclick
</script>


i think it's (nearly?) impossible to deactivate ctrl+p... and, like said before, EVERYBODY will be able to save the page and print it then... or just by marking the text, putting it - e.g. - into a doc-file and... printing it...

btw... i actually agree to dorward... those methods are really annoying for the user and not very reliable...
0
 
dorwardCommented:
Of course that script won't actually prevent IE users from making use of the right mouse button. I'm pretty sure that if they tab the space bar to click the OK button while holding down the right mouse button it will carry on the click and pop up the menu.

And of course they can dig the file out of their cache.

Or disable JavaScript

Or use a keyboard work around

Or decide that the site sucks and never visit it again.
0
 
LeathCommented:
yub... the script just catches simple right-clicks...

sorry cwteoh, but i think it'd be better to forget your ideas...

Leath
0
 
cwteohAuthor Commented:
is it a good idea that ... I not let some user see the page a lot? My website is some kind of e-marketing solution platform. I need to set some authorisation to defferent user.
0
 
webwomanCommented:
If you have different areas that need to have access restricted, there are lots of ways to do that. But that's totally different from disabling printing. And people use right click for lots of things other than 'stealing' your code (which you can't really hide anyway..)

If this is an e-marketing solution, you don't want to drive away your potential clients, do you? Then forget trying to disable browser features or otherwise annoy/frustrate them.
0
 
COBOLdinosaurCommented:
If I go to a site and they have nonsense attempts to try and "protect what is on the page; I know immediately that they are amateurs.  If they are selling web base solutions, I would not waste my time even evaluation the products offered, because I would never recommend anything to a client that annoys a potential customer.

Cd&

0
 
Ernest022699Commented:
Password protect Pages which you are selling.  Do not attempt to block printing, viewing source, et cetera.  As dorward says, once I've bought information then printing it and/or storing it is fair use.  (Redistributing it is not, however.)

As COBOLdinosaur (among others!) says, attempting to block fair access is the hallmark of an amateur.

Any publicly-viewable Pages are fair game for printing and/or "learning" by viewing the source.

0
 
teacher_modCommented:
This question has been abandoned. Would the experts please indicate how
this should be closed out. Is there a comment which should be accepted?
Should the points be split? Should it be reduced to zero points and PAQed?
should it be deleted?  In the absence of direction, the default will be
for me to delete.

TIA for helping to clean up the old questions.

teacher_mod
Community Support Moderator
Experts-Exchange
teacher_mod@experts-exchange.com


0
 
Ernest022699Commented:
This question, like several others, has probably been abandoned because the asker didn't/doesn't like the consensus answer ("It can't be done.", "Don't do it.", etc.).

teacher_mod: Please split the points as you see fit and make it a PAQ.  Thanks!
0
 
COBOLdinosaurCommented:
CJ answer it in the first post.  We all knowthe answer.  User will not be happy with re-invention of the technology. If we choose to talk these to death, we shouldn't get point just for posting.

Cd&
0
 
Ernest022699Commented:
teacher_mod: COBOLdinosaur is correct.  Giving all the points to CJ_S would be fine with me.
0
 
webwomanCommented:
Fine with me too...
0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

  • 3
  • 3
  • 3
  • +5
Tackle projects and never again get stuck behind a technical roadblock.
Join Now