当我尝试使用如下所示的mysql_query创建选择选项时,它不支持中文,它显示为问号“ ???”。
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
</head>
<form name="idSearchReport" action="" method="GET" accept-charset="UTF-8" >
<select name="area_id" style="width: 100px" >
<option value="%%">地區</option>
<?php
// select CarArea
$result = mysql_query("
SELECT
area_id AS area_tbid,
area_name AS area_tbname
FROM CarArea
");
$i=0;
while($row = mysql_fetch_array($result)) {
$area_tbid = $row["area_tbid"];
?>
<option value="<?php echo $row["area_tbid"]; ?>" > <?php echo $row["area_tbname"]; ?></option>
<?php
$i++;
}
?>
</select>
<input type="submit" name="SearchReport" value="查看" />
</form>
只能显示英语。
我该怎么办?非常感谢