Unicode not display properly (urgent)

Hi All,

I’m new to PHP. I need a help from u. I’m generating word doc from php. The problem is characters(unicode) which I give in the input textfield is not display properly in the generated word doc.

My input is : tès©åæ÷øþësttést, but
displays in Word doc : tčs©åę÷ųžėsttést

seems lot of difference in the word doc like “è” became “č” and “øþë” became “ųžė”.

My php code is

$text = utf8_decode(htmlspecialchars(stripslashes(trim($_POST[‘imageDesc’.$i]))))

and I store the $text in the word doc.

Note: I have place meta tag in the php page like:
<meta http-equiv=“Content-Type” content=“text/html; charset=utf-8” />

when check in the php page(print($text)) its working fine but its not proper only in the word doc.

Please help me to solve this prob.

Thanks in advance
Guru

Let me ask you one question.
Why do you use function utf8_decode() and what does it return?

If I didn’t give utf8_decode() all unicodes displays wrongly. If I use that function, some of the unicode not display as I typed but not all.

If I didn’t give utf8_decode() all unicodes display wrongly. But, if I use that function, some of the unicodes does not display as expected.