嗨,我有一个快速的问题要问。但我先举个例子 Column1 是 MemberID Column2 是 Teamname
MemberID = 23, Teamname = ggdiablo
我已经制作了我的团队名称列的下拉列表..
<select id="teamlist" name="teamlist">
$stmt = $pdo->prepare('Select MemberID, teamname from members where ');
$stmt->execute();
while($row = $stmt->fetch(PDO::FETCH_ASSOC)) {
echo "<option>".$row['teamname']."</option>";
}
?>
</select>
如果我从下拉列表中选择“ggdiablo”,是否可以在文本框表单中自动填写 MemberID?如果是这样,如何?