struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Mick.Knut...@wellsfargo.com
Subject RE: Validation Mask help please
Date Thu, 24 Jun 2004 19:39:04 GMT
What is the $ for?
I know the ^ is to start at the beginning.

-----Original Message-----
From: RDoss@quickhire.com [mailto:RDoss@quickhire.com]
Sent: Thursday, June 24, 2004 12:34 PM
To: user@struts.apache.org
Subject: RE: Validation Mask help please


try something like [a-zA-Z][0-9]{4}-\d{3}

-Ram

-----Original Message-----
From: Mick.Knutson@wellsfargo.com [mailto:Mick.Knutson@wellsfargo.com]
Sent: Thursday, June 24, 2004 2:06 PM
To: user@struts.apache.org
Subject: Validation Mask help please


I have the following field validation:
<field property="bankerMacAddress" depends="required,mask">
<msg name="required" key="mask.bankerMacAddress"/>
<msg name="mask" key="mask.bankerMacAddress"/>
<arg0 key="form.bankerMacAddress"/>
<var>
   <var-name>mask</var-name>
   <var-value>^[A-Za-z]\d{4}-\d{3}$</var-value>
</var>
</field>

I want to have a MAC address like follows _OLNY_:
"1 letter, followed by 4 digits, a hyphen, then 3 digits"
A8345-123

Can someone help with this REGEX please:
^[A-Za-z]\d{4}-\d{3}$


---
> Thanks...
> Mick Knutson
> 
> 525 Market Street, SF, CA  94103
> (415) 222-1020
> Mick.Knutson@WellsFargo.com
> MAC A0103-223
---



---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


Mime
View raw message