Re: Remove blank space at the end of all insert/update
Re: Remove blank space at the end of all insert/update
- Subject: Re: Remove blank space at the end of all insert/update
- From: Paul Hoadley <email@hidden>
- Date: Fri, 12 Aug 2016 08:48:17 +0930
On 11 Aug 2016, at 10:02 PM, Luiz Alfredo Carrara Bertusso <email@hidden> wrote:
> Hello, nowadays people can use mobile versions of websites and most of them use the autocomplete function or the swipe one, the problem is both of them add a blank space after the words that come from them.
> The problem is blank spaces at the end of data is not a wished thing, is there some property that can automatically remove blank spaces (somethink lika a trim) before inserting/updating data in database?
ERXGenericRecord looks at the property ‘er.extensions.ERXGenericRecord.shouldTrimSpaces’, which defaults to false. If you set it true, willInsert() and willUpdate() will call ERXEOControlUtilities.trimSpaces() on the EO. This should get you what you want.
--
Paul Hoadley
http://logicsquad.net/
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden