Skip to main content
Inspiring
September 14, 2009
Question

<cfif value > another value>

  • September 14, 2009
  • 1 reply
  • 629 views

Good afternoon all,

I would like to know, is this feasible?

<cfif FORM.StartUnits > FORM.EndUnits>

Starting Units cannot be larger than Ending Units. Please adjust your calculations!

</cfif>

Thanks in Advance,

DJ Khalif

This topic has been closed for replies.

1 reply

djkhalifAuthor
Inspiring
September 14, 2009

I got this to work after placing it at the top of my action page:

<cfif FORM.StartUnits GT FORM.EndUnits>

<cflocation url="/errorPages/startunitsGTendunits.cfm">

</cfif>

If I could place this somewhere in my form to trigger before submitting then, I that would help me.

Thanks in Advance,

DJ Khalif

ilssac
Inspiring
September 14, 2009

If you want anything to happen on the client before the client submits a request to the server, then you need to be using code that runs on the client.

Which is most often JavaScript.  Not CFML which is only going to run on the server.