Hi All,
I am new to Yii application development, i ran into the issue of the arabic text display issue. I am getting all the text from database and i have tried to display it using the following code,
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "/DTD/xhtml1-transitional.dtd">
<html xmlns="removed the link because its my first post:P" xml:lang="en" lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="language" content="en" />
<!-- Set the viewport width to device width for mobile -->
</head>
<body>
<?php
$conn = mysqli_connect("localhost","username","password","some database") or die ("connection error : " . mysqli_error());
$result = mysqli_query($conn,"SELECT * FROM my_table WHERE field = 'value'");
while($row = mysqli_fetch_array($result))
{
echo $row['title'] . " :: " . $row['description'];
echo "<br>";
}
mysqli_close($conn);
?>
</body>
</html>
Now the above code display arabic as it should be doing, when i try the same approach using Yii application, it shows some weird characters. I have added the character set information in /layout/main.php but no use.
I would love to hear a solution ,
Thanks