风讯全系列算号器asp程序
人气:0想了解风讯全系列算号器asp程序的相关内容吗,在本文为您仔细讲解的相关知识和一些Code实例,欢迎阅读和指正,我们先划重点:风讯全系列算号器asp程序,下面大家一起来学习吧。
把现在的代码拷贝下去,保存为ZC.ASP文件放到网站根目录下再访问就可以了 大家试试看,这是我在别的地方看到的.
因为我手上也没有风讯的程序.
复制代码 代码如下:
<%@LANGUAGE="VBSCRIPT" CODEPAGE="936"%>
<!--#include file="Inc/Cls_DB.asp" -->
<!--#include file="Inc/Const.asp" -->
<!--#include file="Inc/Md5.asp" -->
<!--#include file="Inc/Enpas.asp" -->
<%
Set DBC = New DataBaseClass
Set Conn = DBC.OpenConnection()
Set DBC = Nothing
%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" c />
<title>风讯全系列序列号生成器~~~www.icqad.com精彩奉献</title>
<style type="text/css">
body,
input {
margin : 0;
padding : 0;
font-family : Tahoma;
font-size : 11px;
}
input { text-align : center; }
</style>
<script language="javascript">
function checkform() {
if (document.form1.sn1.value.length<5 || document.form1.sn2.value.length<5 || document.form1.sn3.value.length<5 || document.form1.sn4.value.length<5 || document.form1.sn5.value.length<5) {
alert("请输入完整的25位序列号!
如不想输入, 请按生成键!");return false;}}
function generate() {
document.form1.sn1.value=Math.floor(Math.random()*99999);
document.form1.sn2.value=Math.floor(Math.random()*99999);
document.form1.sn3.value=Math.floor(Math.random()*99999);
document.form1.sn4.value=Math.floor(Math.random()*99999);
document.form1.sn5.value=Math.floor(Math.random()*99999);}
function copysn() {
document.form2.sn.select();
js=document.form2.sn.createTextRange();
js.execCommand("Copy")
}
</script>
</head>
<body>
<p> </p>
<p> </p>
<div align="center">风讯全系列序列号生成器</div><br />
<%
Select Case Request("do")
Case "gen"
Call Generate()
Case Else
Call Wizard()
End Select
%>
<% Sub Wizard() %>
<table width="65%" border="0" cellpadding="0" cellpadding="0" align="center" style="word-wrap: break-word;">
<tr>
<td><strong>使用说明:</strong></td>
</tr>
<tr>
<td>本序列号生成器必须在安装前运行.序列号可以任意输入或按生成序列号,安装时再输入此序列号即可.对应风讯任何商业版本.</td>
</tr>
</table>
<br />
<form name="form1" id="form1" method="post" action="zc.asp?do=gen" >
<table width="65%" border="0" align="center" cellpadding="2" cellspacing="2" style="border: 1px solid #000;">
<tr>
<td align="center" width="12%">序列号:</td>
<td align="center" width="88%"><input name="sn1" type="text" id="sn1" size="4" maxlength="5" value="" />
<input name="sn2" type="text" id="sn2" size="4" maxlength="5" value="" />
<input name="sn3" type="text" id="sn3" size="4" maxlength="5" value="" />
<input name="sn4" type="text" id="sn4" size="4" maxlength="5" value="" />
<input name="sn5" type="text" id="sn5" size="4" maxlength="5" value="" />
<input name="random" type="button" id="random" value="生成序列号" />
<input type="submit" name="Submit" value="保存序列号" />
</td>
</tr>
</table>
</form>
<% End Sub %>
<%
Sub Generate()
Dim rsconn,sn1,sn2,sn3,sn4,sn5,encode,sqlstr
sn1=Request.Form("sn1")
sn2=Request.Form("sn2")
sn3=Request.Form("sn3")
sn4=Request.Form("sn4")
sn5=Request.Form("sn5")
code=sn1&"-"&sn2&"-"&sn3&"-"&sn4&"-"&sn5
encode=EnPas(sn1&"-"&sn2&"-"&sn3&"-"&sn4&"-"&sn5)
Set rs=Server.CreateObject("Adodb.Recordset")
sqlstr="SELECT TOP 1 * FROM Config"
rs.Open sqlstr,conn,1,3
rs("Sitelock")=encode
rs.Update
%>
<table width="65%" border="0" cellpadding="0" cellpadding="0" align="center" style="word-wrap: break-word;">
<tr>
<td align="center" style="color:#0000FF;">序列号已成功生成并改写!请复制下面的序列号备用.</td>
</tr>
</table>
<br />
<form name="form2">
<table width="65%" border="0" align="center" cellpadding="2" cellspacing="2" style="border: 1px solid #000;">
<tr><td align="center">
<input name="sn" type="text" size="50" value="<%=code%>" />
<input type="button" name="Submit2" value="复制序列号" />
</td>
</tr>
</table>
</form>
<%
Set conn=Nothing
Set rs=Nothing
End Sub
%>
</body>
</html>
加载全部内容