You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@httpd.apache.org by Pedro Salgueiro <l1...@yahoo.com> on 2003/12/27 14:57:53 UTC

[users@httpd] encoding problem

Hi.

I have made a script in php that calls a java program.
This java program will make a connection to a
PostgreSQL db and do some operations. That java
program works just fine if I run it on a console, but
when it is php to run it gives errors related to the
charset encoding.
The error that apears in "error.log" is the following:

Java.sql.SQLException: ERROR:  Could not convert UTF-8
to ISO8859-1

I think that the problem is than Apache or PHP is
runing the java program with UTF-8 encoding, while it
should be running with iso8859-1.

Does anyone knows how to solve this problem?

Thanks.
Pedro Salgueiro.

__________________________________
Do you Yahoo!?
New Yahoo! Photos - easier uploading and sharing.
http://photos.yahoo.com/

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


RE: [users@httpd] encoding problem

Posted by Rafael Faura <rf...@bassy.net>.
 
Try this ... locate these two lines on your httpd.conf:

AddCharset UTF-8       .utf8
AddCharset utf-8       .utf8

And change them into:

# AddCharset UTF-8       .utf8
# AddCharset utf-8       .utf8

Save the file and restart Apache.



-----------------------------
Rafael Faura Cucalon
Web Developer
rfaura@bassy.net
 
Bassy Servicios Informaticos
http://www.bassy.net


---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org