我想从选项标签创建一个条件,例如,如果我选择绿色,它将显示5个图像,但使用for/do-while标签显示它


<select name="operator">
<option name="green">green</option>
<option name="purple">purple</option>
<option name="orange">Orange</option>
</select><p></p><br>
<button type = "submit">Check</button>

for ($i=0; $i<=5; $i++) {
echo "<img src = ""
}
<select name="operator">
<option value="green">green</option>
<option value="purple">purple</option>
<option value="orange">Orange</option>
</select><p></p><br>
<button type = "submit">Check</button>
if($request->operator == 'green') {
for ($i=0; $i<=5; $i++) {
echo "<img src = "" 
}
}

相关内容

  • 没有找到相关文章

最新更新