zoukankan      html  css  js  c++  java
  • 用CSS3在手机上写弹出框,遮盖层

    html:

    在页面头部要写

    <title>网上预约</title>
    <link href="../App_Themes/default/css/header.css" rel="stylesheet" type="text/css" />
    <link href="../App_Themes/default/css/public.css" rel="stylesheet" type="text/css" /

    <!--自适应手机页面-->
    <meta content="width=device-width,initial-scale=1.0,maximum-scale=1.0,user-scalable=0;" name="viewport" />
    <meta name="apple-mobile-web-app-capable" content="yes" />
    <meta name="apple-mobile-web-app-status-bar-style" content="black" />
    <meta name="format-detection" content="telephone=no, email=no" />
    <meta name="msapplication-tap-highlight" content="no" />

    <script src="../App_Themes/default/js/jquery-1.9.1.min.js" type="text/javascript"></script>

    <div class="page onlinebooking">

    <div class="mask"></div>
    <div class="pop">
    <p>来源</p>
    <p><input type="radio" checked="checked" />微信公众号</p>
    <p><input type="radio" />中介</p>
    <p><input type="radio" />朋友介绍</p>
    <p><input type="radio" />传单</p>
    <p><input type="radio" />其他</p>
    <p style="border:none;">
    <input type="button" value="确 定" />
    </p>
    </div>

    </div>

    css:

    .onlinebooking .mask
    {
    100%;
    height: 100%;
    background: #000;
    opacity: .3;
    position: fixed;
    top: 0;
    left: 0;
    z-index: 1;
    }

    .onlinebooking .pop
    {
    240px;
    height: 16rem;
    background: #fff;
    font-size: 62.5%;
    position: fixed;
    top: 50%;
    left: 50%;
    margin-top: -130px;
    margin-left: -118px;
    z-index: 10;
    }

    .onlinebooking .pop p
    {
    100%;
    line-height:2.8em;
    vertical-align:middle;
    padding: 0 1em;
    box-sizing: border-box;
    border-bottom:1px solid #eee;
    }

    .onlinebooking .pop p input[type="radio"]
    {

    margin-right:.5em;
    position:relative;
    top:2px;
    -webkit-appearance: radio;

    }

    .onlinebooking .pop p input[type="button"]
    {
    100%;
    line-height:2.5em;
    margin-top:1em;
    background-color:#B380B5;
    border:none;
    text-align:center;
    vertical-align:middle;
    color:#fff;
    border-radius:.2em;
    font-family: Arial, Microsoft YaHei;
    font-size: 1em;
    }

  • 相关阅读:
    ZOJ2334 Monkey King 并查集 STL
    ZOJ2286 Sum of Divisors 筛选式打表
    ZOJ2105 终于找到错误
    ZOJ-2091-Mean of Subsequence (反证法的运用!!)
    【9929】潜水员
    【9928】混合背包
    【t077】宝物筛选
    【9927】庆功会
    【9926】完全背包
    【9925】0/1背包
  • 原文地址:https://www.cnblogs.com/ruoyuting/p/5619758.html
Copyright © 2011-2022 走看看