On Tue, 20 Jun 2006 13:07:37 +0430, Michiel Korthuis  
<[EMAIL PROTECTED]> wrote:

i think \w = [_A-Za-z0-9]

so instread of
       ^[_A-Za-z0-9-]+(\\.[_A-Za-z0-9-]+)[EMAIL 
PROTECTED](\\.[A-Za-z0-9-]+)*((\\.[A-Za-z]{2,}){1}$)

can tell
       ^\w+(\.\w+)[EMAIL PROTECTED]((\.\w+\.)+|\.)[a-z]{2,3}$

(only my difference that ".word"s in part of domain of email end also to  
"." except of last ".word" that must be 2 or 3 letter)

FAQ : why use | ?

answer : we see below shape after @ in email :
      ali.WORDs.com (WORDs once or more) = (\.\w+\.)+
or
      ali.com = \.


> I am currently working on my graduation(project) @ Topicus with another
> student (Ronald Hemmink). We are new to Wicket and before we saw the
> wicket-build-in validator we came up with our own expression:
> ^[_A-Za-z0-9-]+(\\.[_A-Za-z0-9-]+)[EMAIL 
> PROTECTED](\\.[A-Za-z0-9-]+)*((\\.[A-Za-z]{2,}){1}$)
>
> the Wicket expression:
> ^[_a-z0-9-]+(\\.[_a-z0-9-]+)[EMAIL PROTECTED](\\.[a-z0-9-]+)*(\\.[a-z]{2,3})$
>
> almost identical, but 'large TLD compatible' (the pattern in wicket has  
> the
> argument 'Pattern.CASE_INSENSITIVE' and therefore they don't need to  
> define
> the upper-case charcters).
>
> your pattern looks a bit too complicated for the job :P
>
> Michiel
>
> On 6/20/06, Frank Bille Jensen <[EMAIL PROTECTED]> wrote:
>>
>> Thats right.. In our company we use the (crazy) regex pattern taken from
>> http://www.ex-parrot.com/~pdw/Mail-RFC822-Address.html
>>
>>
>>
>> String emailPattern = [...]
>>
>>
>> Would anyone in the wicket team like to use this as the emailvalidation
>> pattern instead, I would be happy to submit a patch (for both 1.2 or 2.0
>> if thats the case).
>>
>>
>> Regards
>> Frank Bille
>> Avaleo
>>
>>
>> On Tue, 2006-06-20 at 10:08 +0200, Michiel Korthuis wrote:
>> > hi,
>> >
>> > In
>> > wicket.markup.html.form.validation.EmailAddressPatternValidator.java
>> > the validation-expression is incorrect.
>> > the regular expression reads:
>> > ^[_a-z0-9-]+(\\.[_a-z0-9-]+)[EMAIL PROTECTED](\\.[a-z0-9-]+)*(\
>> > \.[a-z]{2,3})$
>> >
>> > According to this expression the TLD is 2 or 3 characters, but that's
>> > incorrect.
>> > Nowadays it can exceed the limit of 3 characters (for example: ".aero"
>> > or ".travel". Source: http://www.iana.org/gtld/gtld.htm ).
>> >
>> > Michiel
>> >
>> >
>> > _______________________________________________
>> > Wicket-user mailing list
>> > [email protected]
>> > https://lists.sourceforge.net/lists/listinfo/wicket-user
>>
>>
>>
>> _______________________________________________
>> Wicket-user mailing list
>> [email protected]
>> https://lists.sourceforge.net/lists/listinfo/wicket-user
>>



-- 
Using Opera's revolutionary e-mail client: http://www.opera.com/mail/

All the advantages of Linux Managed Hosting--Without the Cost and Risk!
Fully trained technicians. The highest number of Red Hat certifications in
the hosting industry. Fanatical Support. Click to learn more
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=107521&bid=248729&dat=121642
_______________________________________________
Wicket-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/wicket-user

Reply via email to