I have been able to get server side validation working by adding
<ft:validateFormObjects typename="pslClient"
stPropMetadata="#stPropMetadata#" />
within
<ft:processForm action="Register Now">
Still not sure how to make the client side validation work though
On 11 June 2012 12:31, AJ Mercer <[email protected]> wrote:
> I have the following property in my type
> <cfproperty
> ftSeq="1033"
> ftFieldset="Account Details"
> ftWizardStep="Account" name="Country"
> type="string"
> hint="Where do you live"
> required="no"
> default="" ftLabel="Country"
> bLabel="false"
> ftType="string"
> ftStyle="width: 400px;" />
>
> Then in my form page
> <cfset stPropMetadata['Country'] = StructNew() />
> * <cfset stPropMetadata['Country']['ftValidation'] = 'Required' />*
>
> ...
> <ft:object objectid="#stobj.objectid#" typename="pslClient"
> lfields="Phone,Country,State" IncludeFieldSet="true"
> stPropMetadata="#*stPropMetadata*#" />
>
> But the Country required validation is not being enforced.
>
> I added a custom validation
> <cffunction name="ftValidateCountry"
>
> But I noticed that ARGUMENTS.stMetadata.ftValidation is [empty string]
>
>
> How can I make a field not required by default, but enforced in a
> particualr form?
>
>
> --
>
> *AJ Mercer*
> <webonix:net strength="Industrial" /> <http://webonix.net> | <webonix:org
> community="Open" /> <http://webonix.org>
> http://twitter.com/webonix
> Railo Community Manager<http://www.getrailo.org/index.cfm/community/team/>
>
>
--
*AJ Mercer*
<webonix:net strength="Industrial" /> <http://webonix.net> | <webonix:org
community="Open" /> <http://webonix.org>
http://twitter.com/webonix
Railo Community Manager <http://www.getrailo.org/index.cfm/community/team/>
--
You received this message cos you are subscribed to "farcry-dev" Google group.
To post, email: [email protected]
To unsubscribe, email: [email protected]
For more options: http://groups.google.com/group/farcry-dev
--------------------------------
Follow us on Twitter: http://twitter.com/farcry