<?php
if (strlen($_POST['password']) < 6)
echo '<script>alert("用户密码长度不得少于6位");history.back();</script>';
else
echo "用户信息输入合法";