Blogger Information
Blog 19
fans 0
comment 0
visits 10119
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
css_0630作业
bloght5386
Original
513 people have browsed it
作业内容:1. 制作一个用户注册表单,将课堂上提到的表单控件全部用到;
  1. <h3>用户注册</h3>
  2. <form action="" method="post">
  3. <fieldset id="">
  4. <legend>必填项</legend>
  5. <div >
  6. <label for="username">用户名:</label>
  7. <input type="text" name="" id="username" value="" autofocus="autofocus" required="required"/>
  8. </div>
  9. <div >
  10. <label for="pwd">密 码:</label>
  11. <input type="password" name="" id="pwd" value="" />
  12. </div>
  13. <div >
  14. <label for="email">邮箱:</label>
  15. <input type="email" name="" id="email" value="" required/>
  16. </div>
  17. </fieldset>
  18. <div id="">
  19. <input type="radio" name="gender" id="male" value="" />
  20. <label for="male"></label>
  21. <input type="radio" name="gender" id="girl" value="" />
  22. <label for="girl"></label>
  23. </div>
  24. <div id="">
  25. <input type="checkbox" name="hobby[]" id="football" value="" checked="checked" /><label for="football">足球</label>
  26. <input type="checkbox" name="hobby[]" id="football" value="" /><label for="football">篮球</label>
  27. <input type="checkbox" name="hobby[]" id="football" value="" /><label for="football">乒乓球</label>
  28. <input type="checkbox" name="hobby[]" id="football" value="" /><label for="football">铁球</label>
  29. </div>
  30. <div id="">
  31. <select name="" id="">
  32. <option value ="金牌会员">金牌会员</option>
  33. <option value ="银牌会员">金牌会员</option>
  34. <option value ="铜牌会员">金牌会员</option>
  35. </select>
  36. </div>
  37. <div id="">
  38. <label for="search">搜索关键字</label>
  39. <input type="search" name="search" id="search" value="" list="keywords" />
  40. <datalist id="keywords">
  41. <option value ="html"></option>
  42. <option value ="css"></option>
  43. <option value ="javascript"></option>
  44. </datalist>
  45. </div>
  46. </form>
2. 理解css模块的思想,并试写一个案例(选做)
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <meta charset="utf-8">
  5. <title></title>
  6. <link rel="stylesheet" type="text/css" href="style.css"/>导入style.css文件
  7. </head>
  8. <body>
  9. <header>头部</header>
  10. <main>主体</main>
  11. <footer>尾部</footer>
  12. </body>
  13. </html>
  14. /* 初始化样式 */
  15. * {margin: 0;
  16. padding: 0;
  17. box-sizing: border-box;
  18. }
  19. a {
  20. color: red;
  21. text-decoration: none;
  22. }
  23. /* 公共样式 */
  24. body {
  25. height: 100vh;
  26. background-color: #ccc;
  27. }
  28. /* 头部样式 */
  29. header {
  30. height: 5em;
  31. background-color: aqua;
  32. }
  33. /* 主体样式 */
  34. main {
  35. height: 50em;
  36. background-color: yellow;
  37. }
  38. /* 尾部样式 */
  39. footer {
  40. height: 10em;
  41. background-color: blue;
  42. }
  43. #####新建style.css文件
  44. @import url("reset.css");
  45. @import url("public.css");
  46. @import url("header.css");
  47. @import url("main.css");
  48. @import url("footer.css");
3. 实例演示基本选择器与上下文选择器
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <meta charset="utf-8">
  5. <title></title>
  6. <style type="text/css">
  7. /* 标签基本选择器 */
  8. /* li {background-color: red;} */
  9. /* 属性选择器 */
  10. /* li[id="demo"] {background-color: aquamarine;} */
  11. /* 上下文选择器 */
  12. /* 后代选择器 */
  13. /* ul li {background-color: beige;} */
  14. /* 子选择器
  15. */
  16. ul>li {background-color: bisque;}
  17. /* 相邻选择器 */
  18. #demo+li {background-color: yellow;}
  19. </style>
  20. </head>
  21. <body>
  22. <!-- 基本选择器 -->
  23. <ul>
  24. <li id="demo">item1</li>
  25. <li>item2</li>
  26. <li>item3</li>
  27. <li>item4</li>
  28. <li>item5</li>
  29. </ul>
  30. </body>
  31. </html>
4. 预习伪类选择器与常用元素的css样式设置,盒模型知识等
Correcting teacher:天蓬老师天蓬老师

Correction status:qualified

Teacher's comments:
Statement of this Website
The copyright of this blog article belongs to the blogger. Please specify the address when reprinting! If there is any infringement or violation of the law, please contact admin@php.cn Report processing!
All comments Speak rationally on civilized internet, please comply with News Comment Service Agreement
0 comments
Author's latest blog post