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.
Not a member yet? Click here to register.
Forgot Password?

The Mouse Cursor Is Not Shown on Firefox

Asked Modified Viewed 3,709 times
A
anemis
A
anemis 10
  • Junior Member, joined since
  • Contributed 12 posts on the community forums.
  • Started 3 threads in the forums
  • Started this discussions
asked
Junior Member

Hi There;
I am using this script to disable right clik on my site.. (on subheader.php)

Quote

<script language='javascript'>
function NSclick(e) {
if (navigator.appName=='Netscape' && parseInt(navigator.appVersion)==4) {
if (e.which == 3) {
return false;
}
}
if (navigator.appName=='Netscape' && parseInt(navigator.appVersion)>=5) {
if (e.button == 2 || e.button == 3) {
e.preventDefault();
return false;
}
}
}
if (navigator.appName=='Netscape' && parseInt(navigator.appVersion)==4) {
document.onmousedown=NSclick;
document.captureEvents(Event.MOUSEDOWN);
}
if (navigator.appName=='Netscape' && parseInt(navigator.appVersion)>=5) {
document.onmouseup=NSclick;
}
if (navigator.appName=='Microsoft Internet Explorer'wink {
document.oncontextmenu = new Function('return false;'wink
}
function disableselect(e){
return false
}
function reEnable(){
return true
}
document.onselectstart=new Function ('return false'wink
if (window.sidebar){
document.onmousedown=disableselect
document.onclick=reEnable
}
</script>


I get this code from ther: http://www.php-fusion.co.uk/forum/viewthread.php?forum_id=25&thread_id=14803&highlight=right%2Bclick&pid=95600

anyway.. it works perfectly on Internet Explorer.. But most of my users (including me) use mostly Firefox...

ths script works on firefox too but with a litle bug or error..

people cant right click on my site, but also cant write any comments on my articles or even cant login my site.. just because mouse cursor is not shown at designated or specified text area to write..

I mean, any text area on my site becomes not clickable when i use this code...

i m sry to my bad english.. i hope you can understand me..
Edited by anemis on 02-03-2008 23:22,
0 replies

7 posts

J
Josso
J
Josso 10
–––
Without faith, nothing is possible. With it, nothing is impossible
  • Senior Member, joined since
  • Contributed 309 posts on the community forums.
  • Started 1 thread in the forums
answered
Senior Member

Quote

TammyK wrote:
[...]unless you're doing a pop-up that doesn't show the menu bars.

And then you can do it with a shortcut. ;)

So don't bother yourself with it, and leave a copyright notice in the bottom. ;)
0 replies
N
noxes
N
noxes 10
noxes connection
-express your mind with imagination -
  • Member, joined since
  • Contributed 61 posts on the community forums.
  • Started 2 threads in the forums
answered
Member

if u want make protection all of file.. make it in flash..u will get full secure..
0 replies
U
unknown
U
  • Member, joined since
  • Contributed 142 posts on the community forums.
  • Started 7 threads in the forums
answered
Member

To disable right click, Modify /subheader.php and just add the following code to your <BODY> tag

oncontextmenu='return false'


Example:
<body bgcolor='$body_bg' text='$body_text' [color=#ff0000]oncontextmenu='return false'[/color]>\n";


Test it and it's work with IE and FF...

Note: If someone really wants something from your page they can find ways around it, so don't bother yourself. :)
0 replies
X
Xessive
X
I am not always right, but I'm never wrong.
http://www.xessive.nl
  • Senior Member, joined since
  • Contributed 327 posts on the community forums.
  • Started 4 threads in the forums
answered
Senior Member

Try these scripts:

http://www.jcmiras.net/jcm/item/9/
http://forums.devarticles.com/javascr...89888.html

Or browse these search results for usable Javascript code:
http://www.google.com/search?hl=en&am...gle+Search

Hope this helps!
0 replies
A
anemis
A
anemis 10
  • Junior Member, joined since
  • Contributed 12 posts on the community forums.
  • Started 3 threads in the forums
  • Started this discussions
answered
Junior Member

so how can i protect my site to illegal copies??
0 replies
S
Sandrob57
S
  • Member, joined since
  • Contributed 86 posts on the community forums.
  • Started 16 threads in the forums
answered
Member

I'd recommend allowing right click. There are very easy ways to get around the javascript you listed:

1) Click fast (it works sometimes)

2) Disable Javascript on your browser (even easier, and always works)
0 replies
A
anemis
A
anemis 10
  • Junior Member, joined since
  • Contributed 12 posts on the community forums.
  • Started 3 threads in the forums
  • Started this discussions
answered
Junior Member

no idea :|
0 replies

Category Forum

Bugs and Errors - 6

Labels

None yet

Statistics

  • Views 0 views
  • Posts 7 posts
  • Votes 0 votes
  • Topic users 6 members

0 participants

Notifications

Track thread

You are not receiving notifications from this thread.

Related Questions

Not yet