How to implement a 'source code hiding' script

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Inny
    New Member
    • Nov 2007
    • 77

    How to implement a 'source code hiding' script

    Im not sure how to implement this script, it should pop the blank window only if someone clicks veiw source in the context menu or the toolbatr. help?

    Code:
    <html>
    <head>
    <SCRIPT>
    <!--
    /**************************************************
    Speed Code Seal v1.5
    Created by Howard Chen
    Provided & Modified By http://www.DesignerWiz.com
    Your Free Complete Web Development Resource Center
    Get more JavaScripts at http://start.at/javascripts/
    Bugs report to jdeveloper@telebot.net
    This script is free as long as the credits above are kept
    **************************************************/
    //== BROWSER COPY THE CODE BELOW==
    code="<H2><b>Access Denied</a></b></H2>" 
    //== BROWSER COPYING STOP HERE ==
    //== Code Present ==
    //== If Present ==
    codeabove=""
    n = (document.layers) ? 1:0;function init() { if (n) {document.layers['display'].document.open();document.layers['display'].document.write(unescape(code));document.layers['display'].document.close();}if (!n) document.write(unescape(code));
    }//-->
    </script>
    <title>RESTRICTED AREA: YOU ARE BEING TRANSPORTED</title>
    </head>
    <BODY bgcolor="#ffffff" text="#ffffff" onLoad='init()' onunload ="document.open('code_seal_v1.5_1.htm','','halfscreen,scrollbars')" <!--www.DesignerWiz.com-- -->
    <SCRIPT><!--
    if (n) document.write("<DIV ID='display' STYLE='position:absolute; top:0; left:0; width:800; height:600'></DIV>")
    //-->
    </script></script></body></html>
  • ronverdonk
    Recognized Expert Specialist
    • Jul 2006
    • 4259

    #2
    Apart from the questions why (1) you do not want users to see your source - must be very secret - , and (2) why this script does not work, I'd like to put it to you that, since you run on my PC, anything running at my PC is mine!

    You can try to protect it from prying eyes, but since it is running on my pc, in my system's storage, and I have full authority over my own storage, you have no say over that. You can only make a a bit more difficult, but it will cost you more effort to hide than it costs me to get at it.

    Meaning that it makes no sense to protect your code from exposure to anyone who is determined to have a look at it.

    Ronald

    Comment

    • gits
      Recognized Expert Moderator Expert
      • May 2007
      • 5390

      #3
      that is quite true ... may be you find this article and the related comments useful here ...

      kind regards

      Comment

      • gits
        Recognized Expert Moderator Expert
        • May 2007
        • 5390

        #4
        btw: please remember to use a meaningful threadtitle according to the posting guidelines

        kind regards
        MOD

        Comment

        Working...