Yeni <input type="email" />
öğesini kullanmak istiyorum. Tarayıcıda gerçekleşen sunucuda aynı doğrulamayı uygulayan Java koduna sahip olmak isterim.HTML5 giriş e-posta doğrulamasının bir Java uygulaması var mı?
1*(atext/".") "@" ldh-str *("." ldh-str)
<ldh-str> ::= <let-dig-hyp> | <let-dig-hyp> <ldh-str>
<let-dig-hyp> ::= <let-dig> | "-"
<let-dig> ::= <letter> | <digit>
<letter> ::= any one of the 52 alphabetic characters A through Z in upper case and a through z in lower case
<digit> ::= any one of the ten digits 0 through 9
The HTML5 spec defines email addresses
atext = ALPHA/DIGIT/ ; Printable US-ASCII
"!"/"#"/ ; characters not including
"$"/"%"/ ; specials. Used for atoms.
"&"/"'"/
"*"/"+"/
"-"/"/"/
"="/"?"/
"^"/"_"/
"`"/"{"/
"|"/"}"/
"~"
Bu olup aynı kurallarde tarif edildiği gibidir. Bir adresin Java'da bu kurallara uygun olduğunu nasıl test edebilirim?
Teşekkürler!
Bir normal ifadeler kullanabilirsiniz
Hazır bir çözümün var olup olmadığını bilmiyorum, ancak bulamıyorsanız, PEP ile kolayca bir tane oluşturabilirsiniz. http://www.ling.ohio-state.edu/~scott/ – biziclop