Solved

keyboard and browser autorisation Control

Posted on 2001-06-11
18
153 Views
Last Modified: 2010-04-09
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
Comment
Question by:cwteoh
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 3
  • 3
  • +5
18 Comments
 
LVL 22

Accepted Solution

by:
CJ_S earned 50 total points
ID: 6176486
You cannot. There are a LOT of ways to print a website.

regards,
CJ
0
 
LVL 17

Expert Comment

by:dorward
ID: 6176698
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
 

Expert Comment

by:Leath
ID: 6176733
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
Industry Leaders: 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!

 
LVL 19

Expert Comment

by:webwoman
ID: 6177042
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
 
LVL 1

Author Comment

by:cwteoh
ID: 6179587
any one how to disable CTRL-P and right-click function???
0
 
LVL 17

Expert Comment

by:dorward
ID: 6179623
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
 

Expert Comment

by:Leath
ID: 6180737
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
 
LVL 17

Expert Comment

by:dorward
ID: 6180909
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
 

Expert Comment

by:Leath
ID: 6182435
yub... the script just catches simple right-clicks...

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

Leath
0
 
LVL 1

Author Comment

by:cwteoh
ID: 6184108
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
 
LVL 19

Expert Comment

by:webwoman
ID: 6185339
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
 
LVL 53

Expert Comment

by:COBOLdinosaur
ID: 6198915
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
 
LVL 1

Expert Comment

by:Ernest022699
ID: 6216949
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
 

Expert Comment

by:teacher_mod
ID: 6374483
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
 
LVL 1

Expert Comment

by:Ernest022699
ID: 6374551
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
 
LVL 53

Expert Comment

by:COBOLdinosaur
ID: 6375577
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
 
LVL 1

Expert Comment

by:Ernest022699
ID: 6375718
teacher_mod: COBOLdinosaur is correct.  Giving all the points to CJ_S would be fine with me.
0
 
LVL 19

Expert Comment

by:webwoman
ID: 6375828
Fine with me too...
0

Featured Post

Secure Your Active Directory - April 20, 2017

Active Directory plays a critical role in your company’s IT infrastructure and keeping it secure in today’s hacker-infested world is a must.
Microsoft published 300+ pages of guidance, but who has the time, money, and resources to implement? Register now to find an easier way.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Embedding Tags in a restricted UI 6 33
Copying table data to one another 15 37
Opening a new tab in IE using Powershell / HTML 2 46
Hit counters in SharePoint 2013 2 29
This article discusses how to create an extensible mechanism for linked drop downs.
The article shows the basic steps of integrating an HTML theme template into an ASP.NET MVC project
In this Micro Tutorial viewers will learn how to create navigation buttons that change on rollover, using CSS (Continuation of the CSS Image Sprite tutorial) Create a parent ID for all the list items       - Specify position: absolute and display: block…
The viewer will learn how to create a basic form using some HTML5 and PHP for later processing. Set up your basic HTML file. Open your form tag and set the method and action attributes.: (CODE) Set up your first few inputs one for the name and …

733 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question