码迷,mamicode.com
首页 > Web开发 > 详细

导航,头部,CSS基础

时间:2017-10-17 20:55:31      阅读:190      评论:0      收藏:0      [点我收藏+]

标签:code   标签   aix   alt   www.   选择器   back   password   otto   

  • 制作自己的导航条。
  • HTML头部元素:
    1. <base>  定义了页面链接标签的默认链接地址
    2. <style>  定义了HTML文档的样式文件
    3. <link>  定义了一个文档和外部资源之间的关系
  • 练习样式表:
    1. 行内样式表
    2. 内嵌样式表
    3. 外部样式表
  • 分别练习定义三类选择器:
    1. HTML 选择器
    2. CLASS 类选择器
    3. ID 选择器
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>登陆页面</title>
    <base href="http://www.gzcc.cn/"target="_blank">
    <link rel="stylesheet"type="text/css"href="123.css">
    <style>
           h2{ text-align: center;margin-bottom:0;}
           #headertwo{background-color:#FF359A;}
           #contenttwo{background-color:#9D9D9D;height:200px;width:400px;float:left;}
           #footertwo{background-color:#FF5151;clear:both;text-align:center;}
           #wedang{width:400px;float:right}
           #school{width:400px;float:left}

    </style>

</head>
<body>
<img src="http://img3.redocn.com/tupian/20150312/haixinghezhenzhubeikeshiliangbeijing_3937174.jpg"width="100" height="20" alt="h" >
    <a href="">首页</a>
    <a href="">下载</a>
    <input type="text"name="search">
    <input type="submit"value="搜索">
    <a href="">登录</a>
    <a href="">注册</a>
</nav>

<h1>登陆页面</h1>
<h2>2017</h2>

<p></p>
<div>
    <p>注意认真阅读信息<span style="font-family: ‘‘, monospace; font-size: 25px;background-color:#750000">认真阅读</span></p>
</div>

<div  id="container" style="width:400px " >
    <div id="header" style="background-color:green;"><h2 align="center" style="margin-bottom:0;">LOGIN</h2></div>

    <div id="content" style="background-color:#EEEEEE;height:150px;width:400px;float:left;">
        <form action="">
            Username:<input type="text" name="user"placeholder="Username"><br>
            Password:<input type="password" name="password"placeholder="Password">
            <br>
            <input type="radio"name="role"value="stu">student
            <input type="radio"name="role"value="tea">teacher
            <br>
            <input type="button" value="login">
            <input type="button" value="cancel">
        </form>
    </div>


    <div id="footer" style="background-color:mediumpurple;clear:both;text-align:center;">版权 ? duym</div>

</div>
<div  id="container" style="width:400px " >
    <div id="header" style="background-color:green;"><h2 align="center" style="margin-bottom:0;">SEARCH</h2></div>

    <div id="content" style="background-color:#EEEEEE;height:150px;width:400px;float:left;">
        <from>
            <select>
                <option>选择</option>
                <option>收藏</option>
                <option>喜欢</option>
            </select>
        </form><br>
      相关查询:
      <ul>
         <li>教学资料查询</li>
          <li>考试查询</li>
      </ul>
       <ol>
         <li>教学管理</li>
           <li>资源管理</li>
      </ol>

    </div>
    <div id="footer" style="background-color:#C0C0C0;clear:both;text-align:center;">版权 ? duym</div>

</div>


<hr>
 <P>友情链接</P>
  <a href="http://www.gzcc.cn/">广州商学院<br>
      <img src="http://img1.3lian.com/img013/v3/2/d/61.jpg" width="258" height="39" alt="gzcc.cn"  ></a>
</body>
</html>

技术分享

导航,头部,CSS基础

标签:code   标签   aix   alt   www.   选择器   back   password   otto   

原文地址:http://www.cnblogs.com/095lqt/p/7683814.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!