[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Re: How to Disable Right Click in browser window using

Subject: Re: How to Disable Right Click in browser window using javascript
From: Matt Gushee <mgushee@xxxxxxxxxxxxx>
Date: Sat, 16 Mar 2002 10:54:50 -0700
disable right click using html
On Sat, Mar 16, 2002 at 06:14:38PM +0200, Anupam Agarwal wrote:

> i want to disable right click of mouse in browsser window 
> how can this be done 

As your subject line says, it can be done using Javascript. Since this is
not a Javascript list, you will probably get better and faster answers by
checking one of the many Javascript web sites or mailing lists, or the
comp.lang.javascript news group. Once you know what Javascript you need,
it's usually a simple matter to create an XSLT stylesheet that will 
generate that script. E.g.:

  <xsl:template match="/">
    <html>
      <head>
        <title>No Right Clicks Allowed</title>
        <script type="text/javascript" language="JavaScript">
          &lt;!--
            function NoRightClicking(){
              ...
            }
          // --&gt;
	</script>
      </head>
      <body onLoad="NoRightClicking();">
        ...
      </body>
    </html>
  </xsl:template>

Notice that if you follow the conventional practice of wrapping the
JavaScript in a comment, you have to escape the opening '<' character.
Otherwise the XSLT processor will ignore the commented-out text instead
of writing it to the output. You could also use an <xsl:comment>
</xsl:comment> element.

Hope this helps.
-- 
Matt Gushee
Englewood, Colorado, USA
mgushee@xxxxxxxxxxxxx
http://www.havenrock.com/

 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.