<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>select和datalist</title>
</head>
<body>
<!-- <form action="http://localhost">
<select name="key" size="4" multiple="multiple">
<optgroup>
<option value="安里屯">安里屯</option>
<option value="新镇中心">新镇中心</option>
<option value="河西">河西</option>
<option value="安店">安店</option>
</optgroup>
</select>
<input type="submit">
</form> -->
<form action="http://localhost">
<input type="text" name="key" list="my">
<datalist id="my">
<option value="安里屯">安里屯</option>
<option value="新镇中心">新镇中心</option>
<option value="河西">河西</option>
<option value="安店">安店</option>
</datalist>
<input type="submit">
</form>
</body>
</html>