我需要的数字和字母有点像这样的0000-00-0000A。 我正在一个项目上工作,所以当我放置一张优惠券时,随机数字和字母会出现在优惠券ID上,我将它放在上面,但是对于每张优惠券,数字和字母都是不同的。 是的,我是新的编码2个月,我觉得我做的除了这个随机数的东西没有问题。下面是我正在做的例子。我需要一个项目的数字和字母发生器
<!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" content="text/html; charset=utf-8" />
<title>Untitled Document</title>
<style>
#coupon{
width: 600px;
height:auto;
top:145px;
background: #FFFF95;
margin: 2px auto;
border: 1px solid #000000;
text-align: center;
-webkit-border-top-left-radius:06px;
-webkit-border-top-right-radius:06px;
-webkit-border-bottom-left-radius:06px;
-webkit-border-bottom-right-radius:06px;
-moz-border-radius-topleft:06px;
-moz-border-radius-bottomleft:06px;
-moz-border-radius-topright:06px;
-moz-border-radius-bottomright:06px;
border-top-left-radius:06px;
border-top-right-radius:06px;
border-bottom-left-radius:06px;
border-bottom-right-radius:06px;
/* additional features, can be omitted */
border:2px outset #093;
padding:15px;
font-size:15px;
-moz-box-shadow: 0 0 15px #999;
-webkit-box-shadow: 0 0 15px #999;
box-shadow: 0 0 15px #999;
}
</style>
</head>
<body>
<div id="coupon" class="coupon">
<p>This can be the coupn area where the cupon is place and the deal can be read then printed!</p>
<div class="print-page" id="print-page">
<p><a href=" #" onClick=" window.print()" >Print Deal</a></p>
</div>
<div class="coupon-id-number" id="coupon-id-number">0000-00-0000-A</div></div>
</body>
</html>
请任何人都可以帮我吗?
什么样的服务器端技术你使用? – Thilo 2012-04-23 09:05:32
你想用什么语言?我希望您使用数据库来存储优惠券号码,以便以后可以验证它们(作为单次使用)。 – TomDunning 2012-04-23 09:06:44
java和iquery真的...我几乎是新鲜的一切,是的,我有一个系统都存储优惠券ID的工作。 Javascript是首选。 – Thedude420 2012-04-23 09:10:48