Why i have to use iconv if there is the StringTrim filter?

I aspect that StringTrim's behavior is like the native PHP function trim.

I'm italian and we use accented letters. The StringTrim filter works fine, for example, on the string " La città è bella " and returns "La città è bella" but if the string is "La città" the filter returns "La citt�" and when save into the DB the application throws the Exception:

Message: SQLSTATE[HY000]: General error: 1366 Incorrect string value: '\xC3' for column 'column_name' at row 1

I think it is a bug.
ZF version 1.11.3



Il 17/06/2011 00:23, Mark Harris ha scritto:
http://us3.php.net/iconv

Hope this helps :)
//-----
Information Security
eMail: [email protected]
http://www.markizano.net/

On 06/16/2011 08:45 AM, Antonio Caccese wrote:
Hi,
i'have a problem with the StringTrim filter and accented letter 'à' at the end
of words.
If character 'à' is at the end of the string the filter returns the bad
character � and when save it in the DB it throws the following exception:

SQLSTATE[HY000]: General error: 1366 Incorrect string value: '\xC3' for column
'categoria' at row 1

All is well configured to works with UTF-8, IDE Editor, Database, page encoding,
ecc.
Any suggestions?





--
List: [email protected]
Info: http://framework.zend.com/archives
Unsubscribe: [email protected]


Reply via email to