logo       

Re: Best way to read UTF-8 data?: msg#00115

Subject: Re: Best way to read UTF-8 data?
On Mon, 2004-11-15 at 14:41 +0100, Christian Vandendorpe wrote:
> I'm trying to read an xmltv file that is in utf-8 mode from a perl 
> script however I'm having some weird problems.
> 

Well, UTF-8 and perl is still weird to me as well, despite having used
it a number of times and really trying to understand it. You are
supposed to be able to read and write in any encoding using the
techniques shown in perldoc perluniintro. I have never gotten this to
work consistently, and especially not together with XML::LibXML which I
use a lot.

What I have done in the past is to use Text::Iconv to convert between
different encodings and it works after a bit of fiddling.

Having said that, I notice that you are giving Swedish TV-listings as
sample data. tv_grab_se_swedb outputs data in iso-8859-1 (I do all the
necessary conversions in the backend and tv_grab_se_swedb only prints
strings without processing them). That data might be easier for you to
work with.

/Mattias







-------------------------------------------------------
This SF.Net email is sponsored by: InterSystems CACHE
FREE OODBMS DOWNLOAD - A multidimensional database that combines
robust object and relational technologies, making it a perfect match
for Java, C++,COM, XML, ODBC and JDBC. www.intersystems.com/match8


<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

Recently Viewed:
science.linguis...    culture.sf.lite...    video.mplayer.c...    yellowdog.gener...    ietf.rfc822/199...    emacs.help/2002...    redhat.release....    kernel.speakup/...    java.openejb.de...    debian.devel.gt...    xfree86.newbie/...    bug-tracking.ma...    pam/2003-05/msg...    games.devel.ope...    user-groups.lin...    music.pancham/2...    network.mq.deve...    web.html.genera...    arklinux.bugs/2...    linux.ecasound/...    qnx.openqnx.dev...    org.user-groups...    file-systems.sf...    trustix.contrib...   
Home | blog view | USPTO Patent Archive | advertise | OSDir is an inevitable website. super tiny logo

Free Magazines

Cisco News
Receive a free quarterly e-newsletter with exclusive articles on how Cisco IT uses its own products and solutions to enable the business.
subscribe

Systems Management News, the newspaper for IT systems administration and data center managers! Each issue of Systems Management News is chock-full of news and analysis to help you understand what's happening in your field.
subscribe

The Enterprise Newsweekly eWeek is the essential technology information source for builders of e-business.
subscribe

Oracle Magazine Oracle Magazine contains technology strategy articles, sample code, tips, Oracle and partner news, how to articles for developers and DBAs, and more. Oracle (NASDAQ: ORCL) is the world's largest enterprise software company.
subscribe

Total Telecom Total Telecom is "The Economist of the communications industry".
subscribe