I looked at that documentation but don't understand why the name property is being used as opposed to the label property.
On 9/26/07, Dave Newton <[EMAIL PROTECTED]> wrote: > > http://struts.apache.org/2.x/docs/localizing-output.html > > --- "Cory D. Wiles" <[EMAIL PROTECTED]> wrote: > > > Does anyone have a possible solution for using wild > > cards in error messages > > for form validation? > > > > In my package.properties I have: > > arc.screen.required.error.message = {0} is a > > required field > > > > How does my validation need to be formatted to > > accept a parameter for the > > message? > > <!DOCTYPE validators PUBLIC > > "-//OpenSymphony Group//XWork Validator > > 1.0.2//EN" > > > > > "http://www.opensymphony.com/xwork/xwork-validator-1.0.2.dtd"> > > > > <validators> > > <field name="screenone.screenOneProtocolNumber"> > > <field-validator type="requiredstring"> > > <message > > key="arc.screen.required.error.message"/> > > </field-validator> > > </field> > > > > <field > > name="screenone.screenOnePrincipalInvestigator"> > > <field-validator type="requiredstring"> > > <message > > key="arc.screen.required.error.message"/> > > </field-validator> > > </field> > > </validators > > > > The form field looks like this: > > <s:textfield > > name="screenone.screenOneProtocolNumber" id=" > > screenone.screenOneProtocolNumber" > > label="%{getText(' > > arc.screen.one.section.one.first.input.label')}" > > size="10" value="%{ > > screenone.screenOneProtocolNumber}"/> > > > > I can't use ${getText(fieldName)} is a required > > field because the message > > that is displayed is: > > screenone.screenOneProtocolNumber is required > > > > Thanks, > > Cory > > > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > >