|
将下面的代码保存为.htm或.html就可以了
复制代码 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>网页加密器</title>
<style>
td{font-size:9pt;line-height:140%}
body{font-size:9pt;line-height:140%}
a:link { color: #0033CC; text-decoration: none }
a:visited { color: #0033CC; text-decoration: none }
a:active { color: #FF0000; text-decoration: none }
a:hover { color: #000000; text-decoration: none }
</style>
</head>
<body bgcolor="#DDDDDD" leftMargin="0" topMargin="0">
<TABLE cellSpacing=5 cellPadding=5 width=100% border=0>
<TBODY>
<TR>
<TD valign="top">
<script language=JavaScript>
<!--
//////////////////////////////////////////////////////////////////
// Source Code Encrypter v1.0 //
//////////////////////////////////////////////////////////////////
// //
// This JavaScript can be freely used as long as this message //
// stays here in the header of the script. Any modifications //
// and bugs found (and fixed) are appreciated. //
// Script submitted/featured on Dynamicdrive.com //
// //
//////////////////////////////////////////////////////////////////
var i=0;
var ie=(document.all)?1:0;
var ns=(document.layers)?1:0;
function generate() /* Generation of "Compilation" */
{
code = document.pad.text.value;
if (code)
{
document.pad.text.value='正在生成加密代码,请稍后!';
setTimeout("compile()",1000);
}
else alert('请输入源文件代码')
}
function compile() /* The "Compilation" */
{
document.pad.text.value='';
compilation=escape(code);
document.pad.text.value="<script>\n<!--\ndocument.write(unescape(\""+compilation+"\"));\n//-->\n<\/script>";
i++;
alert("页面被加密了 "+i+" 次!");
}
function selectCode() /* Selecting "Compilation" for Copying */
{
if(document.pad.text.value.length>0)
{
document.pad.text.focus();
document.pad.text.select();
}
else alert('没有可以选择的文本内容!')
}
function preview() /* Preview for the "Compilation" */
{
if(document.pad.text.value.length>0)
{
pr=window.open("","Preview","scrollbars=1,menubar=1,status=1,width=700,height=320,left=50,top=110");
pr.document.write(document.pad.text.value);
}
else alert('没有可以预浏览的文本内容!')
}
function uncompile() /* Decompiling a "Compilation" */
{
if (document.pad.text.value.length>0)
{
if (i>0) i--;
source=unescape(document.pad.text.value);
document.pad.text.value=""+source+"";
}
else alert('你需要生成被加密的代码后才能取回源代码!')
}
// -->
</script>
<table cellspacing="0" cellpadding="0" width="760" border="0" align="center">
<tr>
<td width="100%" align="left" style="font-size:14px">
提示: 把你想加密的文档的源代码拷贝到下面的文本框内,按下生成按钮就可以得到一段加密了的页面代码,把代码复制到新的页面就可以了. [注意:可重复加密啊!]
</td>
</tr>
<tr>
<form name=pad method=post align="center">
<td width="100%" align="center"><textarea style="WIDTH: 99%;" name=text rows=16></textarea>
<input onClick=generate() type=button value=加密代码 name=compileIt>
<input onClick=selectCode() type=button value=全选代码 name=select>
<input onClick=preview() type=button value=预浏览页面 name=view>
<input onClick=uncompile() type=button value=原代码 name=retur>
<input onClick="javascript:i=0" type=reset value=清空 name=clear>
</td>
</form>
</tr>
<tr>
<td width="100%" height=10>
</td>
</tr>
</table>
</TD>
</TR>
</TBODY>
</TABLE>
<center>
<!-- x -->
</body>
</html> |
|