View Full Version : limit of length of user name
chrispadfield
Sat 17th Feb '01, 7:32pm
I couldn't find any way to limit the length and i don't know if it is in the code. Anyway it mucks up table spacing if people with usernames too long register. I have someone with a username of 23 letters and am going to try and get them to change it but only if i can stop others doing it as well. suggestions?
Mas*Mind
Sat 17th Feb '01, 7:33pm
a quick but not very secure solution: just set a 'maxlenght=x' to the username-field
chrispadfield
Sat 17th Feb '01, 7:36pm
cunning. Will do, thanks
bira
Sat 17th Feb '01, 7:40pm
on this occassion, any idea how to set a minimum as well? A few folks registered with just one character on my BB and I dislike that. I'd like to set a minimum of 3 characters and maximum 16. Ideas?
Mas*Mind
Sat 17th Feb '01, 7:46pm
in templates this can only be done through javascript...something like:
<script language="javascript">
function check() {
if(forms[0].fieldname.value.length < 3)
alert("Numbers of characters to small");
}
</script>
and set a onSubmit="check()" on the submit button..
I don't know if it's the correct code...I'm not really a big javascript guru...
Mas*Mind
Sat 17th Feb '01, 7:49pm
hmz...seems like a bug on the [php]-code....
the </script> tag seems to screw it up
vBulletin® v3.8.0 Release Candidate 1, Copyright ©2000-2008, Jelsoft Enterprises Ltd.