How to hide source code of a website
|
Go4Expert Member
|
|
| 26Oct2011,05:36 | #1 |
|
Can anyone please tell me how to hide source code of a website . I need it very desperately
|
|
Go4Expert Founder
|
![]() |
| 26Oct2011,10:23 | #2 |
|
You can encode the html and do it if you don't want developers to not see the code.
|
|
Newbie Member
|
|
| 26Oct2011,15:00 | #3 |
|
Contributor
|
|
| 26Oct2011,21:18 | #4 |
|
You can rename your files in .php if you are using .html then encode all the code but a person who wants to decode it and knows the method of encryption can decrypt your code. there is a php crypt algorithm that uses a key to decrypt and to encrypt. anyway you can use ioncube to encode your files. remember that .html source can always be seen from browser.
|
|
Newbie Member
|
|
| 26Oct2011,23:36 | #5 |
|
Quote:
Originally Posted by Alex.Gabriel |
|
Contributor
|
|
| 26Oct2011,23:58 | #6 |
|
Well , when you encode any file you must make it logic. for example an encoded html text for example :
Code:
<html> Code:
<HTML> I have seen that some peoples are encoding entire pages with base64 but this method is easy to recognize and to decrypt using php's base64_decode function. Anyway , this function is php-made and is recognized by browsers. I have used that algorithm to to encode direct links to media files on my website and make sure nobody can get them. I haven't tryed to encode an entire page but i think will work with some encoding. I should ask this before : do you want to hide source code in browser or in file?
shabbir
like this
|
|
Banned
|
|
| 9Nov2011,17:42 | #7 |
|
Hello,
protect your source code! follow these easy 5 steps: Step 1: let's assume your main page is named index.htm. Rename index.htm to encrypt.htm. Step 2: open encrypt.htm source code and add the code below to the file, right after the opening BODY tag. CODE Code:
<script language=JavaScript>m='%3Cscript%20language%3DJavaScript%3E%3C%21--%0D%0A%0D%0Avar%20message%3D%22Function%20Disabled%21%22%3B%0D%0A%0D%0Afunction%20clickIE%28%29%20%20%7Bif%20%28document.all%29%20%7Balert%28message%29%3Breturn%20false%3B%7D%7D%0D%0Afunction%20clickNS%28e%29%20%7Bif%20%0D%0A%28document.layers%7C%7C%28document.getElementById%26%26%21document.all%29%29%20%7B%0D%0Aif%20%28e.which%3D%3D2%7C%7Ce.which%3D%3D3%29%20%7Balert%28message%29%3Breturn%20false%3B%7D%7D%7D%0D%0Aif%20%28document.layers%29%20%0D%0A%7Bdocument.captureEvents%28Event.MOUSEDOWN%29%3Bdocument.onmousedown%3DclickNS%3B%7D%0D%0Aelse%7Bdocument.onmouseup%3DclickNS%3Bdocument.oncontextmenu%3DclickIE%3B%7D%0D%0A%0D%0Adocument.oncontextmenu%3Dnew%20Function%28%22return%20false%22%29%0D%0A%0D%0A//%20--%3E%3C/script%3E';d=unescape(m);document.write(d);</script> Step 3: create a text file and name it index.htm (or whatever your main file was named originally). the contents of the new index.htm file is given below - the code below is all that will be contained in index.htm. CODE Code:
<script language=JavaScript>m='%3C%21--%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%0D%0A%23%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%23%0D%0A%23%20%20%20%20%20%20%20%23%0D%0A%23%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%23%0D%0A%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%0D%0A%23%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%23%0D%0A%23%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%23%0D%0A%23%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%23%0D%0A%23%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%23%0D%0A%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%23%0D%0A%23%0D%0A%23%%3E';d=unescape(m);document.write(d);</script> create a text file and name it encrypt.js. the contents of the new encrypt.js file is given below -this is all that will be contained in encrypt.js. CODE document.write('<title>||||| SOURCE CODE ENCRYPTION |||||</title>'); document.write('<frameset rows="100%,*" framespacing="0" border="0">'); document.write('<frame frameborder="0" name="topFrame" src="encrypt.htm" noresize="noresize" />'); document.write('</frameset>'); Step 5: copy all the files to your server (index.htm, encrypt.htm, and encrypt.js). all the files must be located in the same directory. then open the index.htm file. try to view the source code, then try to right click on the page. Best regards Carly Fiorina |
|
Go4Expert Member
|
|
| 9Nov2011,23:04 | #8 |
|
Hey Alex, CarlyFiorina . Thanks for the suggestion. I just tried what CarlyFiorina said and its was working
.
|
|
Banned
|
|
| 16Nov2011,17:40 | #9 |
|
Quote:
Originally Posted by JohnAadam Many many thanks for sharing your information, I am highly appreciated!! Any problem please suggest ![]() Carly Fiorina Last edited by CarlyFiorina; 16Nov2011 at 17:52.. |
|
Newbie Member
|
|
| 31Dec2011,15:28 | #10 |
|
Where can i change the page code? I.e index.html.
And where can i put the encryt code in my control panel? |



.
