Re: [PHP] Invalid byte sequence for encoding UTF-8
- From: paragasu@xxxxxxxxx (paragasu)
- Date: Fri, 31 Oct 2008 02:39:14 -0700
i do not use any function other that addslashes on the $_POST
On 10/30/08, Lester Caine <lester@xxxxxxxxxxx> wrote:
paragasu wrote:.
i am using php with postgresql. when i submit post query to the
server. i have the pg_exec error
<snip>
Warning: pg_query() [function.pg-query]: Query failed: ERROR: invalid
byte sequence for encoding "UTF8": 0x93 HINT: This error can also
happen if the byte sequence does not match the encoding expected by
the server, which is controlled by "client_encoding".
</snip>
is there any function to prevent this type of error. something i can
apply to any POST query
before i submit to pg_query() ?
You probably need to tell us which functions you are using to create/modify
the UTF8 string that you are sending as data. I does sound like a conversion
TO UTF8 is not being carried out somewhere. PHP5 requires that only
multi-byte
string functions are used to handle UTF8 data
--
Lester Caine - G8HFL
-----------------------------
Contact - http://lsces.co.uk/lsces/wiki/?page=contact
L.S.Caine Electronic Services - http://lsces.co.uk
EnquirySolve - http://enquirysolve.com/
Model Engineers Digital Workshop - http://medw.co.uk//
Firebird - http://www.firebirdsql.org/index.php
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
- References:
- Invalid byte sequence for encoding UTF-8
- From: paragasu
- Re: [PHP] Invalid byte sequence for encoding UTF-8
- From: Lester Caine
- Invalid byte sequence for encoding UTF-8
- Prev by Date: Re: [PHP] Mailing lists
- Next by Date: RE: [PHP] DOCTYPE, javascript and Firefox
- Previous by thread: Re: [PHP] Invalid byte sequence for encoding UTF-8
- Index(es):
Relevant Pages
|