You can try using the jcode library. Unicode support in Ruby is dicey at best right now, but this should at least allow you to get the unicode strings from your escape sequences:
$KCODE = 'UTF8' require jcode str = "\342\210\202x/\342\210\202y" puts str => ∂x/∂y On 10/24/06, Christian Kreutzer <[EMAIL PROTECTED]> wrote: > Hi again, > > i think i finally figured out what the real problem is. While reading > UTF-8 encoded files (and passing those unicode strings to watir) works > fine. those *.properties files that we have to use for input use the > unicode-escape encoding (\uxxxx) for unicode chars. The files are > encoded in ASCII. > > python, javascript or java can handle this encoding but i dont know > how use this in ruby. Since this unicode-escape encoding doesnt seem > to be "real" utf-8 encoding the hints i got so far can't solve the > problem. > > any ideas? > > Christian > > On 10/20/06, Chris McMahon <[EMAIL PROTECTED]> wrote: > > > > > > > > > > XSD::Charset.encoding = 'UTF8' <-- is there something to "require" in > > > the script in order to get this working? > > > > > > You might possibly need to install net-http2 for this, but I thought it was > > part of Ruby.... > > > > http://dev.ctor.org/download/http-access-2_0_6.tar.gz > > > > > > > > _______________________________________________ > > Wtr-general mailing list > > [email protected] > > http://rubyforge.org/mailman/listinfo/wtr-general > > > > > _______________________________________________ > Wtr-general mailing list > [email protected] > http://rubyforge.org/mailman/listinfo/wtr-general > _______________________________________________ Wtr-general mailing list [email protected] http://rubyforge.org/mailman/listinfo/wtr-general
