zoukankan      html  css  js  c++  java
  • CSS基础学习

    一、背景

    CSS 属性定义背景效果:

    • background-color          //背景颜色  十六进制 - 如:"#ff0000" RGB - 如:"rgb(255,0,0)" 颜色名称 - 如:"red"
    • background-image     //背景图像  background-image:url('img_tree.png');
    • background-repeat        //背景图像是否及如何重复  background-repeat:no-repeat; (no-repeat 不平铺 repeat-x 横向平铺 repeat-y 横向平铺)
    • background-attachment //背景图像是否固定或者随着页面的其余部分滚动。
    • background-position      //背景图像定位
    background:颜色 图片 平铺  定位;
    例:body {background:#ffffff url('img_tree.png') no-repeat right top;}

      background-attachment:scroll; 默认随页面的其余部分滚动   fixed; 背景图像是固定的   inherit; 指定background-attachment的设置应该从父元素继承

    主页背景图设置

    .bodybg {
    100%;
    height: 100%;
    position: absolute;
    top: 0;
    left: 0;
    z-index: -1;
    }

    <img src="./images/loginbg1.jpg" class="bodybg">

     二、圆角按钮——CSS

    .btn {
    99px;
    height: 35px;
    line-height: 35px;
    border-radius: 5px;
    -moz-border-radius: 5px;
    -webkit-border-radius: 5px;
    border: none;
    cursor: pointer;
    font-size: 14px;
    font-family: "Microsoft Yahei";
    color: #fff;
    }

  • 相关阅读:
    Final Zadanie 题解
    CF1096E The Top Scorer 题解
    [SDOI2008]Sue的小球 题解
    柱爷与远古法阵 题解
    [ZOJ3329] One Person Game 题解
    扑克牌 题解
    CF494C Helping People 题解
    CF1025D Recovering BST 题解
    linux基础学习-Raid 0 1 5 10的原理、特点、性能区别
    linux基础学习-CentOS7.5用户管理
  • 原文地址:https://www.cnblogs.com/wuss/p/6632250.html
Copyright © 2011-2022 走看看