利用selected属性来指定正在HTML页里添载时应过后选择该选项。你否以测验考试运转下列代码来完成selected属性 −
事例
<!DOCTYPE html> <html> <head> <title>HTML selected attribute</title> </head> <body> <p>Here's the list of subjects. Select any one:</p> <form> <select name = "dropdown"> <option value = "Computer Architecture" selected>Computer Architecture</option> <option value = "Java">Java</option> <option value = "Discrete Mathematics">Discrete Mathematics</option> </select> </form> </body> </html>
登录后复造
以上即是正在HTML外何如指定选项正在页里添载时应事后选外?的具体形式,更多请存眷萤水红IT仄台别的相闭文章!
发表评论 取消回复