Oh no! Where's the JavaScript?
Your Web browser does not have JavaScript enabled or does not support JavaScript. Please enable JavaScript on your Web browser to properly view this Web site, or upgrade to a Web browser that does support JavaScript.
Sign In
Not a member yet? Click here to register.
Forgot Password?
Navigation

right click lock

Last updated on 3 years ago
Z
zimi27Junior Member
Posted 3 years ago
In which file should I set the right-click lock?
<body bgcolor='$body_bg' text='$body_text' >'return false'>n";
R
Anonymous UserVeteran Member
Posted 3 years ago
Code you provided does nothing. You need javascript code that will do this. And you can do it in theme.php.

Btw this is silly idea, because user can disable javascript and copy text anyway. Also he can use view-source code (via right click or keyboard shortcut). Smarter users can even download page and then copy.. There are many ways how to bypass it. So you have 0 ways to block right-click or text copying that works 100%.

So don't do it. It's a waste of time and annoying to users.
Z
zimi27Junior Member
Posted 3 years ago
In PF7 I gave the code in
themes -> templates -> header.php
And it worked, now this file is different.
I know there is a way around it, but not everyone can do it or want to.
Some kid won't copy the article if someone else blocks the ad.

I don't know why the code got lost, that's how it is:
echo "<body bgcolor='$body_bg' text='$body_text' Xoncontextmenu='return false'>n";

del X wink
Edited by zimi27 on 25-02-2022 22:01, 3 years ago
R
Anonymous UserVeteran Member
Posted 3 years ago
This is the worst way.. With this you can still select text and copy with ctrl c. You blocking only right click but not text selecting.

Effectiveness 0%.
You can view all discussion threads in this forum.
You cannot start a new discussion thread in this forum.
You cannot reply in this discussion thread.
You cannot start on a poll in this forum.
You cannot upload attachments in this forum.
You cannot download attachments in this forum.
You cannot up or down-vote on the post in this discussion thread.
You cannot set up a bounty in this discussion thread.
Moderator: Support Team