X-Original-To: pgsql-php-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id 0290856383 for ; Thu, 3 Mar 2005 15:14:20 +0000 (GMT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 96676-05 for ; Thu, 3 Mar 2005 15:14:14 +0000 (GMT) Received: from wproxy.gmail.com (wproxy.gmail.com [64.233.184.202]) by svr1.postgresql.org (Postfix) with ESMTP id 40EC354F8C for ; Thu, 3 Mar 2005 15:14:13 +0000 (GMT) Received: by wproxy.gmail.com with SMTP id 70so531098wra for ; Thu, 03 Mar 2005 07:14:18 -0800 (PST) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:reply-to:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:references; b=PhOuDQvS7YRXbmj1qz+gwJ6FQeoiUC87qai33twLSZIZlhJBAka2jsPtdNr5fHuwClUIYdKunle1PcyTikPBqR35+VPvmOUNXQmmk0hXX8BPw+l9OlRrRYi/cnV2WOGsTyREldooY0SoaarSEGdA6OWHnfepZEnEnmZWthDEo0Q= Received: by 10.54.73.12 with SMTP id v12mr93746wra; Thu, 03 Mar 2005 07:14:18 -0800 (PST) Received: by 10.54.40.4 with HTTP; Thu, 3 Mar 2005 07:14:17 -0800 (PST) Message-ID: <621eda8a0503030714e43bc79@mail.gmail.com> Date: Thu, 3 Mar 2005 16:14:17 +0100 From: Zouari Fourat Reply-To: Zouari Fourat To: Christopher Kings-Lynne Subject: Re: unicode and frensh accents Cc: pgsql-php@postgresql.org In-Reply-To: <42271EF4.8090109@familyhealth.com.au> Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit References: <621eda8a0503030622837a19e@mail.gmail.com> <42271EF4.8090109@familyhealth.com.au> X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.013 tagged_above=0 required=5 tests=AWL, RCVD_BY_IP X-Spam-Level: X-Archive-Number: 200503/16 X-Sequence-Number: 3031 in phppgadmin, the statement header('Content-Type: text/html; charset=UTF-8'); [root@apps pgadmin]# grep -r "header(" * dataexport.php: header("Location: {$url}"); dataexport.php: header("Location: {$url}"); dataexport.php: header("Location: {$url}"); dataexport.php: header('Content-Type: text/plain'); dataexport.php: header('Content-Type: application/download'); dataexport.php: header('Content-Disposition: attachment; filename=dump.' . $ext); dataexport.php: header('Content-Type: text/plain'); dbexport.php: header('Content-Type: text/plain'); dbexport.php: header('Content-Type: text/plain'); dbexport.php: header('Content-Type: application/download'); dbexport.php: header('Content-Disposition: attachment; filename=dump.sql'); dbexport.php: header('Content-Type: application/download'); dbexport.php: header('Content-Disposition: attachment; filename=dump.sql.gz'); help.php: header("Location: $url"); logout.php:header('Location: index.php'); in classes/Misc.php there's echo "\n"; wich result in same as i did ... there's another thing that can be helpfull tracking my problem. when getting data well formed in my explorer from phppgadmin and then saving it to my hard disk and displaying it from its local location i get the same problems. and the line : exists ! On Thu, 03 Mar 2005 22:28:04 +0800, Christopher Kings-Lynne wrote: > > I have a problem displaying frensh data : > > my client encoding is set to UNICODE (same as phpPgAdmin) > > when selecting data with phpPgAdmin, there's no errors displaying > > accents and other special frensh caracters. > > but when selecting from my own script i dont get those frensh caracters. > > in my html pages i do : > > > > like phpPgAdmin and there is allways problems displaying frensh data... > > anyone can help ? > > Well, you can try sending an http header as well, before ANY of your > script's output: > > header('Content-Type: text/html; charset=UTF-8'); > > Alternatively, try setting the client encoding to unicode with an sql > statement before running any queries, however that should not be > necessary as client encoding defaults to server encoding. > > BTW, have a look at the printHeader() method in classes/Misc.php in > phpPgAdmin to see how we do it. > > Chris >