hi i want to share with you this code to avoid people who want to see your html code or to copy and paste your content with the wright boton of the mouse, put it between <head> and </head> or <body> </body> <script language="JavaScript1.2"> function nosource() { alert('sorry copyright ...'); return(false); } document.oncontextmenu = nosource; </script>
This isn't very useful, the user can always press ctrl+u or use the "File" menu. I suggest you use tools like this one http://scriptasylum.com/tutorials/encdec/encode-decode.html
your code just works on IE, if you want to hide your HTML code, you should use some JavaScript encoder/decoder software; or you can JavaScript online encrypting tool from my JavaScript library
protecting stuff from webpages is naive at best - to a determined person, its all too easy to steal whatever they need. the only thing worth wasting time over is encoding your php source code with something like ioncube so that other uses on the server cannot access it. as for html obfuscating, you can always save the rendered source of the html (webdev plugin in firefox) for images, there are plugins, but webdev plugin can also help here and list you all images from the DOM for js, you can use a packer like dean edwards' old one (relying on eval, even though it's not a recommended practice these days) - but using firebug you can view the eval'd code and steal the functions anyway if you post it on the internet, it stops being yours :/
Obfuscating stuff this way is completely useless. What it does is make it harder for casual users to use your page, determined people, or people who's geeky enough just find this mildly annoying. For casual users, breaking the right-click menu is horrible, and leads to thousands of question to the IT-department, which then have to "quelch the fire" - that there isn't anything wrong with the browser, just the person who's made the page.