html 5は、ポップアッププロンプトボックスを実現し、マスク層に伴ってポップアップボックスを閉じることができる
2335 ワード
<script src="js/jquery-1.8.3.min.js"/>
<style>
*{padding: 0; margin: 0}
.box{
position: fixed;
width: 100%;
height: 100%;
background: rgba(0,0,0,0.2);
display: none;
}
.box1{
width: <a href="https://www.baidu.com/s?wd=500px&tn=44039180_cpr&fenlei=mv6quAkxTZn0IZRqIHckPjm4nH00T1dBPWbsuy7Bn1-WmvmYnWbY0ZwV5Hcvrjm3rH6sPfKWUMw85HfYnjn4nH6sgvPsT6K1TL0qnfK1TL0z5HD0IgF_5y9YIZ0lQzqlpA-bmyt8mh7GuZR8mvqVQL7dugPYpyq8Q1Rznjf4n1mvnWn3njDYnjfsPf" target="_blank" class="baidu-highlight">500px</a>;
height: <a href="https://www.baidu.com/s?wd=500px&tn=44039180_cpr&fenlei=mv6quAkxTZn0IZRqIHckPjm4nH00T1dBPWbsuy7Bn1-WmvmYnWbY0ZwV5Hcvrjm3rH6sPfKWUMw85HfYnjn4nH6sgvPsT6K1TL0qnfK1TL0z5HD0IgF_5y9YIZ0lQzqlpA-bmyt8mh7GuZR8mvqVQL7dugPYpyq8Q1Rznjf4n1mvnWn3njDYnjfsPf" target="_blank" class="baidu-highlight">500px</a>;
position: fixed;left: 50%; top: 25%;
<a href="https://www.baidu.com/s?wd=margin-left&tn=44039180_cpr&fenlei=mv6quAkxTZn0IZRqIHckPjm4nH00T1dBPWbsuy7Bn1-WmvmYnWbY0ZwV5Hcvrjm3rH6sPfKWUMw85HfYnjn4nH6sgvPsT6K1TL0qnfK1TL0z5HD0IgF_5y9YIZ0lQzqlpA-bmyt8mh7GuZR8mvqVQL7dugPYpyq8Q1Rznjf4n1mvnWn3njDYnjfsPf" target="_blank" class="baidu-highlight">margin-left</a>: -250px;
border: 1px solid #000000;
}
</style>
<script>
</script>
<div class="box">
<div class="box1">
<a href="javascript:;" class="close"> </a>
</div>
</div>
<a href="javascript:;" class="show"> </a>
</code></pre>
<p><br/></p>
<p><br/></p>
<pre><code> href, , button , , a </code></pre>
<pre><code> <code>fixed auto </code></pre>
<br/>
</div>
</div>
</div>
</div>