Avatar of salasadi
salasadi
 asked on

ASP Page to read arabic test

My ASP pages include Arabic text data that come from MS Access XP that insert via ASP forms.  When I pull the data it looked like garbage (non-readable) in the site, however, I can right click and encode it to "Arabic Windows" and it will display correctly.  
I think the problem has to do with Unicode-UTF8, but not sure how to fix it in my pages.   I wish someone have an idea how to display the text correctly?

thanks
ASPWindows OS

Avatar of undefined
Last Comment
Computer101

8/22/2022 - Mon
ASKER CERTIFIED SOLUTION
_Stilgar_

THIS SOLUTION ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
GET A PERSONALIZED SOLUTION
Ask your own question & get feedback from real experts
Find out why thousands trust the EE community with their toughest problems.
salasadi

ASKER
Stilgar,
I fix it before I get your article, however, this is the correct way. here is the tag:

<meta http-equiv=Content-Type content="text/html; charset=windows-1256">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">


you desrve the full credit :)
_Stilgar_

You only need to use one of those. No need for the two of them.

Stilgar.
salasadi

ASKER
my site work while I have both? any problem or conflict for leave them both?
All of life is about relationships, and EE has made a viirtual community a real community. It lifts everyone's boat
William Peck
_Stilgar_

I wouldn't know. Why leave both? would you want to test your site with all possible browsers to see none of them fail to render your page?

Stilgar.
salasadi

ASKER
I make everything as:

<meta http-equiv="Content-Type" content="text/html; charset=utf-8">

everything working OK, store and retrieve.  now I am trying to do link to send email from the page.  the email address and the subject are dynamically build from the database. something like:

response.write "<tr align=right><td><a href='mailto:" & rsitem("email") & "?subject=" & rsitem("title") & "'>" & rsitem("fullname") & "</td></tr>"

since the title is Arabic UTF-8 the subject line will read garbage like:

Ù&اÙ!Ù` أسباب تعثر اÙÙ&شرÙÆع اÙØ£Ù&رÙ`Ù’Ù`

however, when I move the mouse over the mailto link it display the subject correctly in the broswer status bar.  
any idea to fix this issue?

thanks

_Stilgar_

use the iso meta tag instead of the utf one, and see if that fixes the problem.

Stilgar.
⚡ FREE TRIAL OFFER
Try out a week of full access for free.
Find out why thousands trust the EE community with their toughest problems.
Computer101

Forced accept.

Computer101
EE Admin