<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <div class="input__container"> <div class="shadow__input"></div> <button class="input__button__shadow"> <svg fill="none" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 20 20" height="20px" width="20px"> <path d="M4 9a5 5 0 1110 0A5 5 0 014 9zm5-7a7 7 0 104.2 12.6.999.999 0 00.093.107l3 3a1 1 0 001.414-1.414l-3-3a.999.999 0 00-.107-.093A7 7 0 009 2z" fill-rule="evenodd" fill="#17202A"></path> </svg> </button> <input type="text" name="text" class="input__search" placeholder="What do you want to search?"> </div> <title>Title</title> </head> </html>有没有什么错误
时间: 2023-07-19 17:24:00 浏览: 129
这段代码中有一个错误,<div>标签不能直接放在<head>标签中,它应该放在<body>标签内部来显示在网页中。因此,需要将<div>标签放在<body>标签内部。以下是修改后的代码:
```
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Title</title>
</head>
<body>
<div class="input__container">
<div class="shadow__input"></div>
<button class="input__button__shadow">
<svg fill="none" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 20 20" height="20px" width="20px">
<path d="M4 9a5 5 0 1110 0A5 5 0 014 9zm5-7a7 7 0 104.2 12.6.999.999 0 00.093.107l3 3a1 1 0 001.414-1.414l-3-3a.999.999 0 00-.107-.093A7 7 0 009 2z" fill-rule="evenodd" fill="#17202A"></path>
</svg>
</button>
<input type="text" name="text" class="input__search" placeholder="What do you want to search?">
</div>
</body>
</html>
```
这是一个包含一个搜索框的HTML网页代码。其中,<div>标签用于包含搜索框,<input>标签用于创建输入框,<button>标签用于创建按钮,<svg>用于创建图标。
阅读全文
相关推荐




<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta http-equiv="X-UA-Compatible" content="IE=edge"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <title>登录页</title> </head> <body>
我的博客系统 主页 写博客 注销 登录 用户名 <input type="text" id="username"> 密码 <input type="password" id="password"> <input type="button" value="提交" id="submit"> </body> </html>

請你幫我打修改HTML代碼<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <title>异常记录</title> <style> .main { display: flex; flex-direction: row; justify-content: space-between; align-items: center; } </style> </head> <body> 首页 登记数据 查询数据 异常记录登记 <form method="post" action="/submit"> <label>确认线别:</label> <input type="text" name="line">
<label>确认日期:</label> <input type="date" name="date">
<label>异常机种:</label> <input type="text" name="model">
<label>异常现象:</label> <textarea name="issue"></textarea>
<label>生产日期:</label> <input type="date" name="prod_date">
<label>生产班别:</label> <input type="text" name="shift">
<label>生产线别:</label> <input type="text" name="prod_line">
<label>责任人:</label> <input type="text" name="responsible">
<input type="submit" value="提交"> </form> 欢迎访问 </body> </html>














