From: "J. mp" Date: 2007-02-12T08:21:06+09:00 Subject: Re: Regular expressions Vincent Fourmond wrote: > J. mp wrote: >> Hi folks, >> I'm burning my head because i don't understand how regular expressions >> works >> >> I just want to validade a username wher >> username ->valid >> user.name ->valid >> >> everything else is invalid > > Just to get you started: > > /[a-z]+(\.[a-z]+)?/ > > Vince First of all, thanks for the attention. More details: max size allowed is 30 min size allowed is 5 the follwoing chars are allowed : - _ . (Slash, undescore, perdiod) these chars are not allowed as start neither as ending char any alphabetic char, english chars only case insensitive no numbers eg .username ->invalid user-name -> valid _username -> invalid user.name -> valid user_name ->valid basically I want allow the same pattern allowed for emails but before the @ char :) -- Posted via http://www.ruby-forum.com/.