in reply to help needed in unicode retriving

Perhaps should you tell perl you want to use unicode first with :
use open ':utf8';
Hope that helps.

update: Well actually it should even be

use utf8;

Then all strings will be treated as utf8. "use open ':utf8'" is for opening and writing to utf8 files.

Replies are listed 'Best First'.
Re^2: help needed in unicode retriving
by singam (Initiate) on Mar 10, 2006 at 12:39 UTC
    but still its giving the wrong answer, substr $target,0,2 it returns only one chinese character , but how to get two chinese characters
      Sorry, my mistake, actually use utf8; should do the trick, see the update to my previous message.
        i tried both, but still the same problem . do we need to use encode . if so can you give me one example which using the encode stuff.