html - ×...它在跨度、div 和 p 标签中向我显示正斜杠(浏览器 chrome 和 firefox)
问题描述
/* CSS Document */
@import url('https://fonts.googleapis.com/css?family=Exo+2');
body {
margin: 0;
padding: 0;
font-family: 'Exo 2', sans-serif, arial, helvetica, roboto, callibri, verdana;
text-align: center;
}
button {
background-color: #069;
color: #FFF;
width: 150px;
height: 40px;
border: none;
margin: 0 auto;
display: block;
font-size: 16px;
cursor: pointer;
}
div#modal {
background-color: #0004;
width: 100%;
height: 100%;
position: fixed;
top: 0;
padding-top: 120px;
}
.img_contr {
border: 1px solid red;
}
.close {
float: right;
font-size: 25px;
font-weight: bold;
width: 50px;
}
form {
border: 1px solid #666;
width: 60%;
text-align: ;
margin: 20px auto;
padding: 20px;
background-color: #fff;
}
<h2>Modal Login Form</h2>
<button>Login</button>
<div id="modal">
<form action="action_page.php">
<div class="img_contr">
<img src="https://dummyimage.com/200x200/000/fff" alt="magic">
<span class="close">×</span>
</div>
<label for="user_name">Username</label>
<input type="text" placeholder="Enter Username" />
<label for="user_pass">Password</label>
<input type="password" placeholder="Password" />
</form>
</div>
这是我的代码和实体,它向我显示跨度、div 和 p 标签中的正斜杠(浏览器.. chrome 和 firefox)
解决方案
推荐阅读
- jenkins - 仅在测试成功的情况下如何使用 Jenkins 部署 Drupal
- android - 在 Android 上处理使用 ImageReader 获得的图像
- sql - 将日期集转换为月末日期
- java - 如果 Kotlin 中的 try catch 失败返回什么?
- postgresql - 需要在 PostgreSQL 中的外部表上并行追加
- javascript - How can I get properties of a type as an array in Typescript?
- r - 向量化 R 中的双循环
- laravel - 动态路由 url 更改未反映在 laravel 包中
- ios - 在 webRTC 调用期间在 WebRTC 中流式传输音频
- linkedin - 可以从 API 调用返回 LinkedIn 连接度吗?