You need to make 2 changes
1. Modify your HTML page to set content type has below
<html>
<head>
<meta http-equiv="Content-type" value="text/html; charset=utf-8">
2. After mysql_connect() and mysql_select_db() add this line
mysql_query("SET NAMES utf8");