Modify a text before the insert query

Alhazred 20 Jun, 2011
I have a form on my site, when a user writes something inside the textarea this text is stored into the database as he writes it.
A user can put more than 1 whitespace between words and I need to replace them with only 1 because I'll need to print that text on paper.

Where do I have to put my regex to replace the whitespaces? Or in other words, where is the INSERT query?
Alhazred 20 Jun, 2011
I've found out that the insert is inside the autogenerated code and it can't be modified... is there any chance to do what I need?
Alhazred 21 Jun, 2011
Solved with some Javascript.
GreyHead 21 Jun, 2011
Hi Alhazred,

You can also change the submitted results in the OnSubmit Before Email box in CFv3 or a Custom Code action in CFv4.

Bob
This topic is locked and no more replies can be posted.