关于处理注册表单的问题!

本人有2个问题!
第一:如何检测注册时两次输入的密码一致?
第二:如何检测注册时的用户名是不是已经存在?
一个问题100!

---------------------------------------------------------------

1

 1<script language="javascript">   
 2function is(form1){   
 3if(form1.pass1.value!=form.pass2.value){   
 4alert("密码不一样");   
 5return false;   
 6}   
 7else   
 8{   
 9return true;   
10}   
11}   
12</script>
1<form action="xxx.php" method="post" name="form1" onsubmit="return is(this)">   
21密码<input name="pass1" type="password"/>
3<br/>   
42密码<input name="pass2" type="password"/>
5<input type="submit" value="send"/>
6</form>

2
select * from tablename where name='name'

Published At
Categories with Web编程
Tagged with
comments powered by Disqus