Link to home
Start Free TrialLog in
Avatar of rivkamak
rivkamakFlag for United States of America

asked on

utf characters from SQL to ASP page

i have a field in my sql table with hebrew characters. The field type is varchar. In my database the information can be read with real letters.
When I try to pass that information onto my asp page, I am getting just ??

The asp page is utf encoded:
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />

What do I need to adjust?
Avatar of Scott Fell
Scott Fell
Flag of United States of America image

In my database the information can be read with real letters.

What is actually being stored in your database?  If you simply use  hebrew characters with utf8 is should work.  Are the characters stored correctly in the dbf when you look directly at the data?
Avatar of rivkamak

ASKER

How do I know how the information is stored.
It looks like real hebrew letters to me in the database
so when you use ms sql server manager studio, and open the table, you can see the hebrew characters?

If you start a new blank pages like below what happens?

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

<title>Untitled Document</title>
</head>

<body>
place raw hebrew character here 
</body>
</html>

Open in new window


then

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

<title>Untitled Document</title>
</head>

<body>
<%=rs("FieldWthHebrew")%>
<hr>
<pre><%=rs("FieldWthHebrew")%></pre>
</body>
</html>

Open in new window

Besides for my dynamic content the rest of the page is full of hebrew characters that show up just fine.

even if I start a new blank page and tried putting my dynamic information on it, it also shows up with ???
I think you need to change varchar to nvarchar
sorry it is nvarchar.

actually there is a page where I have an admin section for our administrator to view the information from the table and add new data, the text does come through properly.
Yet, not on this page:

http://www.oorahhakitzah.co.il/
SOLUTION
Avatar of G_H
G_H
Flag of United Kingdom of Great Britain and Northern Ireland image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
ASKER CERTIFIED SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Thank you