繁体   English   中英

使用 while 循环创建文本字段时,如何将多个文本字段值发送到下一个 pho 页面?

[英]How to send multiple text field values to next pho page when the text field is created using while loop?

如何将使用 while 循环创建的表单的多个文本字段值传递到另一个页面?

echo”<form method=\”POST\” action =\”store.php\”>”;
While($result = mysqli_fetch_row($exec))
{
echo $result[0].” “ .$result[1].” “;
echo “<input text =\”type\” name=\” marks\”>”;
}
echo “<input type=\”submit\”>”;
echo “</form>”;

上面的代码工作正常,但是当循环创建多个文本字段并且当我提交表单时,只有最新的被发送到 store.php。 我的问题是如何发送所有值。?

您可以使用数组表示法。 其中包含所有值作为数组

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM