zoukankan      html  css  js  c++  java
  • CSS_最简单,最难的对齐,以及其他

    1,,关于 <input type="text"> <input type="button"> <input type="submit"> 的宽高

    2,,有文字和<input />一起存在时候的居中

     <div class="head">
      你好, world <a href="#">show</a> <input type="text" class="txt" /> <input type="submit" class="sub" value="s1" /> <input type="button" class="but" value="b2" />
     </div>

    .head{height:100px;background:#CCC;text-align:center;line-height:100px;}
    .head input{vertical-align:middle;_margin:36px 0}
    .head input.txt{100px;height:24px;background:#F00;border:1px solid #000;}
    .head input.sub,.head input.but{40px;height:26px;background:#F00;border:1px solid #000;}

    3,,有,文字,行内块级元素,<input /> 一起存在居中的时候

    .head{height:100px;background:#CCC;text-align:center;line-height:100px;}
    .head a{display:inline-block;40px;height:24px;line-height:24px;background:#F00;border:1px solid #000;vertical-align:middle;_margin:36px 0}
    .head input{vertical-align:middle;_margin:36px 0}
    .head input.txt{100px;height:24px;background:#F00;border:1px solid #000;}
    .head input.sub,.head input.but{40px;height:26px;background:#F00;border:1px solid #000;}

     4,,vertical-align:0;vertical-align:-5px;

     

  • 相关阅读:
    第二次结对编程作业
    5 线性回归算法
    4 K均值算法--应用
    3 K均值算法
    2 机器学习相关数学基础
    1 机器学习概述
    15. 语法制导的语义翻译
    14.算符优先分析
    13.自下而上语法分析
    12.实验二 递归下降语法分析
  • 原文地址:https://www.cnblogs.com/somesayss/p/2496734.html
Copyright © 2011-2022 走看看