locked
disabling context menu in opera RRS feed

  • Question

  • User694310073 posted

    Hi

    <body oncontextmenu="return false"> this is not working in opera.
     

    could any one help me to disable the context menu in opera.

    Thanks & Regards

    sreelu

    Tuesday, February 10, 2009 1:32 AM

Answers

  • User-1171043462 posted

    Hi

    <body oncontextmenu="return false"> this is not working in opera.
     

    could any one help me to disable the context menu in opera.

    Thanks & Regards

    sreelu

    I have not tested it in opera but it works in IE, Firefox and chrome

    try it and leave  a comment on the site if it works

    http://www.aspsnippets.com/post/Disable-Right-Click-in-Browsers.aspx

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Tuesday, February 10, 2009 3:09 AM

All replies

  • User-1171043462 posted

    Hi

    <body oncontextmenu="return false"> this is not working in opera.
     

    could any one help me to disable the context menu in opera.

    Thanks & Regards

    sreelu

    I have not tested it in opera but it works in IE, Firefox and chrome

    try it and leave  a comment on the site if it works

    http://www.aspsnippets.com/post/Disable-Right-Click-in-Browsers.aspx

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Tuesday, February 10, 2009 3:09 AM
  • User242281485 posted

    <script type="text/javascript">
    <!--
    function VerifyIfRightClick(evt)
    {
    if(evt.button == 2) {evt.preventDefault();};

    }

    function init()
    {
    if(document.addEventListener)
    {document.addEventListener("mousedown", VerifyIfRightClick, true);};

    }

    -->
    </script>
    <head>
    <body onload="init();" ...>

    Tuesday, February 10, 2009 3:56 AM
  • User694310073 posted

    its not woking in opera

    Wednesday, February 11, 2009 12:32 AM
  • User-1171043462 posted

    its not woking in opera

    Did you tried mine?? what error did you get

    Wednesday, February 11, 2009 12:34 AM