Is this happening for the default edit form in the webtop, or in one of your own pages?
Blair On Fri, Aug 6, 2010 at 5:22 AM, Szabolcs <[email protected]> wrote: > Hi there, > > I am trying to do a custom validation on a field in my publishing > rule, but the validation let pass any value. > > This is what I did. > 1.) I set up a cfproperty in the rule like this. > <cfproperty ftSeq="1" ftFieldset="General" name="channel" > type="string" ftType="myFieldType" hint="The channel name" > required="true" ftLabel="Channel Name" /> > > 2.) I created myFieldType.cfc in plugins/myplugin/packages/formtools/ > > 3. ) I overrode the validate function in the above file and at this > point it only contains this > <cfset var stResult = structNew()> > <cfset stResult.bSuccess = false> > <cfset stResult.Value = ""> > <cfset stResult.stError = StructNew()> > <cfset stResult.stError.message = 'Error Message'> > <cfset stResult.stError.class = 'validation-advice'> > <cfreturn stResult> > so the validation should fail all the time and I should get the 'Error > Message' . > Well it never happens. > > I checked the validate function is actually gets called from /farcry/ > core/tags/formtools/processformobjects.cfm (line 506), but it seems > after the call only stResult.Value is used and the rest of the > structure is discarded. > > > What am I doing wrong? > Any help is appreciated. > Thank you, > Szabolcs > > -- > You received this message cos you are subscribed to "farcry-dev" Google > group. > To post, email: [email protected] > To unsubscribe, email: > [email protected]<farcry-dev%[email protected]> > For more options: http://groups.google.com/group/farcry-dev > -------------------------------- > Follow us on Twitter: http://twitter.com/farcry -- 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
