|
马上注册,结交更多好友,享用更多功能,让你轻松玩转社区。
您需要 登录 才可以下载或查看,没有帐号?立即注册
x
ASP是依赖组件的,能访问数据库的组件好多就有好多种,再有就是你微软的工具可是什么都要收钱的啊!<html>
<head>
<metahttp-equiv="Content-Type"content="text/html;charset=gb2312">
<METANAME="Author"CONTENT="haiwa">
<title>Asp天生条形码</title>
</head>
<body>
<%
functionhaiwaocde(zfstr)
zf=zfstr
zf=replace(zf,"0","_|_|__||_||_|")
zf=replace(zf,"1","_||_|__|_|_||")
zf=replace(zf,"2","_|_||__|_|_||")
zf=replace(zf,"3","_||_||__|_|_|")
zf=replace(zf,"4","_|_|__||_|_||")
zf=replace(zf,"5","_||_|__||_|_|")
zf=replace(zf,"7","_|_|__|_||_||")
zf=replace(zf,"6","_|_||__||_|_|")
zf=replace(zf,"8","_||_|__|_||_|")
zf=replace(zf,"9","_|_||__|_||_|")
zf=replace(zf,"a","_||_|_|__|_||")
zf=replace(zf,"b","_|_||_|__|_||")
zf=replace(zf,"c","_||_||_|__|_|")
zf=replace(zf,"d","_|_|_||__|_||")
zf=replace(zf,"e","_||_|_||__|_|")
zf=replace(zf,"f","_|_||_||__|_|")
zf=replace(zf,"g","_|_|_|__||_||")
zf=replace(zf,"h","_||_|_|__||_|")
zf=replace(zf,"i","_|_||_|__||_|")
zf=replace(zf,"j","_|_|_||__||_|")
zf=replace(zf,"k","_||_|_|_|__||")
zf=replace(zf,"l","_|_||_|_|__||")
zf=replace(zf,"m","_||_||_|_|__|")
zf=replace(zf,"n","_|_|_||_|__||")
zf=replace(zf,"o","_||_|_||_|__|")
zf=replace(zf,"p","_|_||_||_|__|")
zf=replace(zf,"r","_||_|_|_||__|")
zf=replace(zf,"q","_|_|_|_||__||")
zf=replace(zf,"s","_|_||_|_||__|")
zf=replace(zf,"t","_|_|_||_||__|")
zf=replace(zf,"u","_||__|_|_|_||")
zf=replace(zf,"v","_|__||_|_|_||")
zf=replace(zf,"w","_||__||_|_|_|")
zf=replace(zf,"x","_|__|_||_|_||")
zf=replace(zf,"y","_||__|_||_|_|")
zf=replace(zf,"z","_|__||_||_|_|")
zf=replace(zf,"-","_|__|_|_||_||")
zf=replace(zf,"*","_|__|_||_||_|")
zf=replace(zf,"/","_|__|__|_|__|")
zf=replace(zf,"%","_|_|__|__|__|")
zf=replace(zf,"+","_|__|_|__|__|")
zf=replace(zf,".","_||__|_|_||_|")
haiwaocde=zf
endfunction
code_H=52
code_W=2
functiondragcode(ccode)
c=ccode
c=replace(c,"_","<spanstyle=height:"&code_H&";width:"&code_w&";background:#FFFFFF></span>")
c=replace(c,"|","<spanstyle=height:"&code_H&";width:"&code_w&";background:#000000></span>")
dragcode=c
endfunction
FunctionCheckExp(patrn,str)
SetregEx=NewRegExp
regEx.Pattern=patrn
regEx.IgnoreCase=true
regEx.Global=True
CheckExp=regEx.test(str)
EndFunction
code=request("c")
ifcode=""then
code="*51windows.net*"
else
ifCheckexp("^[abcdefghijklmnopqrstuvwxyz1234567890+-*/\%$.]*$",code)then
code="*"&code&"*"
else
code="*51windows.net*"
errstr="<br><centerstyle=color:red;>含有不法字符</center>"
endif
endif
ocode=code
code=lcase(code)
%>
<center><formname="form1"method="post">正当字符:ABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890+-*/%$.<br><br><inputname="c"type="text"value="<%=request("c")%>"size="25"maxlength="15"><inputtype="submit"name="Submit"value="提交"></form><center>
<divalign="center">
<center>
<tableborder="0"cellpadding="0"cellspacing="0"height="79">
<tr>
<tdheight="61"align="center"><%=dragcode(haiwaocde(code))%></td>
</tr>
<tr>
<tdheight="18"align="center"style="text-align:justify;text-justify:Distribute-all-lines;"><%=(ocode)%></td>
</tr>
</table>
</center>
</div>
<%=errstr%>
</body>
</html>
因为ASP脚本语言非常简单,因此其代码也简单易懂,结合HTML代码,可快速地完成网站的应用程序。还无法完全实现一些企业级的功能:完全的集群、负载均横。 |
|