By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
438,818 Members | 2,089 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 438,818 IT Pros & Developers. It's quick & easy.

Customize RightClick Menu

P: n/a
Hi All,
I am using a Web Application and I want to customize Right Click Menu
as following:-

Do Nothing when user does a Right Click.

When user select some text and does a Right Click he/she should have a
option of Copy and Paste.

Any Ideas how can this be done.

Thanks

Sep 5 '06 #1
Share this Question
Share on Google+
5 Replies


P: n/a
*** ri****************@gmail.com escribió/wrote (5 Sep 2006 10:23:09
-0700):
I am using a Web Application and I want to customize Right Click Menu
as following:-

Do Nothing when user does a Right Click.

When user select some text and does a Right Click he/she should have a
option of Copy and Paste.

Any Ideas how can this be done.
We might be able to provide better advise if you tell us why you need this
and what you're trying to accomplish. I hope you aren't trying to protect
your source code...

BTW, Mozilla Firefox has a security feature to explicitly avoid what you're
trying to do.

--
-+ http://alvaro.es - Álvaro G. Vicario - Burgos, Spain
++ Mi sitio sobre programación web: http://bits.demogracia.com
+- Mi web de humor con rayos UVA: http://www.demogracia.com
--
Sep 5 '06 #2

P: n/a
Alvaro G. Vicario said the following on 9/5/2006 6:08 PM:
*** ri****************@gmail.com escribió/wrote (5 Sep 2006 10:23:09
-0700):
>I am using a Web Application and I want to customize Right Click Menu
as following:-

Do Nothing when user does a Right Click.

When user select some text and does a Right Click he/she should have a
option of Copy and Paste.

Any Ideas how can this be done.

We might be able to provide better advise if you tell us why you need this
and what you're trying to accomplish. I hope you aren't trying to protect
your source code...

BTW, Mozilla Firefox has a security feature to explicitly avoid what you're
trying to do.
And Opera doesn't allow it at all.

Want a customized Right Click Menu that is dependable on the Web? Write
your own browser.

--
Randy
Chance Favors The Prepared Mind
comp.lang.javascript FAQ - http://jibbering.com/faq & newsgroup weekly
Javascript Best Practices - http://www.JavascriptToolbox.com/bestpractices/
Sep 5 '06 #3

P: n/a
Hi Alvaro,
I am trying to protect my Source code but thats not my main
concern.....I also dont want user to Browse Back and Forward using
RightClick Menu.

I just want them to have Options of RightClick Menu which is generated
when we select/highlight a text on a webpage which are Undo, Copy,
Paste, Cut , Delet, Select All etc.

I hope this further expalins what I am trying to do.

Thanks

Sep 6 '06 #4

P: n/a
Hi Randy,
Thanks for your Advice...I will let you know once I get around with
what I am trying to achieve. Unfortunately this is the first project I
am dealing with lots of client side scripting so my knowledge is
limited.

Thanks all you folks out there for your suggestions.

Sep 6 '06 #5

P: n/a
wrote on 06 sep 2006 in comp.lang.javascript:
Hi Alvaro,
I am trying to protect my Source code but thats not my main
concern.....I also dont want user to Browse Back and Forward using
RightClick Menu.

I just want them to have Options of RightClick Menu which is generated
when we select/highlight a text on a webpage which are Undo, Copy,
Paste, Cut , Delet, Select All etc.

I hope this further expalins what I am trying to do.
[please always quote what you are replying to,
this is not email but usenet,
and so we do not know what it is that it would expalin
what you are trying to do further.]

No, you don't own my browser, so preventing me to use it to the full
extent is an insult and I would, found that, opt not to return to your
site anymore, which could harm your business.
... Browse Back and Forward ...
This is easly done by the BS or alt-leftarrow and alt-rightarrow key
combinations, or the relevant browser icons or menu.

I doubt that many ordinary surfers even know or have ever used the back
function in the rightclick menu.

Yes, some page sequences, like in form submission are compromized when
executing a pageback, however, you should be able to detect that and
prevent the unwanted consequences with your [preferably serversided IMHO]
code.
... I am trying to protect my Source code ...
You cannot protect it but from the coding ignorant,
who would not understand it or have use for it anyway.
If you don't know that now,
your code surely is not innovative enough to be protected.

Since hopefully you have learned al lot of clientside coding by
viewsource viewing otherman's code, don't you feel a slight obligation to
give others the ability to viewsource view your selfprofessed as
important code?

--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)
Sep 6 '06 #6

This discussion thread is closed

Replies have been disabled for this discussion.