curl and UTF-8

From: Date: Mon, 26 Aug 2002 12:36:31 +0000
Subject: curl and UTF-8
Groups: php.general 
Request: Send a blank email to php-general+get-114129@lists.php.net to get a copy of this message
Hello List, I have a problem with the php CURL module and UTF-8 data. My php script uses curl to do a post to a perl/cgi script. This perl script returns UTF-8 encoded XML. The perl script returns utf-8, i have verified that using the webserver logfiles, but the data that i receive in $result (see below) is decoded to ISO-8859-1. $ch = curl_init(); curl_setopt($ch, CURLOPT_URL, $post_url); curl_setopt($ch, CURLOPT_HEADER, 0); curl_setopt($ch, CURLOPT_VERBOSE, 0); curl_setopt($ch, CURLOPT_POST, 1); curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); curl_setopt($ch, CURLOPT_POSTFIELDS, $postfields); $result = curl_exec ($ch);// #### UTF compatible? curl_close ($ch); Anyone an idea how i can get curl to return me UTF-8 data? Thank you, Merijn van den Kroonenberg

« previous php.general (#114129) next »