1.The customising link

We can change the link's style when we move our pointer on the link like that:

1.1 The " text-decoration:none "means remove the underline !

a:hover{
color: black;
background-color: red;
text-decoration: none;
}

1.2 Why should we customise links?

To emphasise to the user where the links are.

1.3 What is the purpose of a CSS selector?

It connects a set of CSS properties to things in the HTML document.

1.4 a:hover is a CSS selector to select links that the user is hovering over and we can set a different set of style properties for the link when the user moves the mouse over it.

 

2.Layout Control

U can set  classes on anything, and actually if u define the class u can use the class to a different tags .

And we can set any bit text we want. Especially when we use the span class which allow us to cut in .

like that :

.indent {
margin-left: 50px;
}
.gap_bellow{
margin-bottom: 100px;
}
<h1 class = "gap_bellow"><span class = "indent">This is my first page!</span>This is my first page!This is my first page!This is my first page!This is my first page!This is my first page!This is my first page!This is my first page!This is my first page!This is my first page!This is my first page!This is my first page!This is my first page!This is my first page!This is my first page!This is my first page!</h1>

3.CSS Media Queries

Responsiveness can be implemented in CSS with something called CSS Media Queries.

1. The code means let the body's background color be green when brower's window has minimum width 1000px  

And we call the " min-width : 1000px " test !

@media(min-width:1000px){
body{
background: green;
}
}

2016 - 1 - 25 CSS初步 (二)的更多相关文章

  1. 2016 - 1 - 24 CSS初步

    1.The difference between CSS and HTML HTML document is that it specities the content of the page. An ...

  2. 一起看看2016中国第三届CSS开发者大会有哪些大咖演讲

    中国第三届CSS开发者大会于2016年12月17日在广州举办.由W3C.w3ctech.前端圈主办.本次大会我们将邀请行业内知名讲师,与大家共聚广州,畅聊CSS. 快捷报名通道:http://www. ...

  3. 前端总结·基础篇·CSS(二)视觉

    前端总结系列 前端总结·基础篇·CSS(一)布局 前端总结·基础篇·CSS(二)视觉 前端总结·基础篇·CSS(三)补充 前端总结·基础篇·CSS(四)兼容 目录 一.动画(animation)(IE ...

  4. css入门二-常用样式

    css入门二-常用样式总结 基本标签样式 背景色background-color 高度height; 宽度width; 边框对齐以及详细设定举例 width/*宽度*/: 80%; height/*高 ...

  5. 基本CSS布局二

    基本CSS布局二------基本页面布局二 /*主面板样式*/ #container { width:100%; margin:0px auto;/*主面板DIV居中*/ } /*顶部面板样式*/ # ...

  6. 2016.8.25 JavaScript入门之二

    1.字符串中,引用字符串:要用/"转换: 例如:var myStr="I am a \"double quoted\" string inside \" ...

  7. 2016/2/25 html+css学习资源

    html+css学习资源 1.Position is Everything,一个描述和展示在各种浏览器中发现的bug,并提供css解决方法的网站,顶! 2.一个国外的网页设计论坛 3.http://c ...

  8. 2016/1/25 多线程 作业 方法一 继承Thread 方法二 实现Runnable 多线程笔记

    /* * 1,尝试定义一个继承Thread类的类,并覆盖run()方法, * 在run()方法中每隔100毫秒打印一句话.*/ package Stream; //方法一 继承Thread 实现多线程 ...

  9. HTML/CSS初步了解

    一.CSS是什么? 它是一种用来表现HTML(标准通用标记语言的一个应用)或XML(标准通用标记语言的一个子集)等文件样式的计算机语言.CSS为HTML标记语言提供了一种样式描述,定义了其中元素的显示 ...

随机推荐

  1. AxureRP8实战手册(基础21-30)

    AxureRP8实战手册(基础21-30) 本文目录 基础21.     设置元件默认选中/禁用 基础22.     设置单选按钮唯一选中 基础23.     设置元件不同状态时的样式 基础24.   ...

  2. centos mysql 安装及配置

    安装Mysql   1 Centos 6.6下安装Mysql很简单, yum list mysql-server 2 当只有一个时候就可以直接 yum install mysql-server 进行安 ...

  3. TortoiseGit编辑全局变量支持https

    在windows,右键,进入tortoisegit的设置窗口,在左边树形菜单选Git,然后店"编辑全局.gid/config"按钮 输入以下文字 [http] sslVerify ...

  4. 十天精通CSS3学习笔记 part3

    第8章 CSS3中的变形与动画(上) 变形--旋转 rotate() 旋转rotate()函数通过指定的角度参数使元素相对原点进行旋转.它主要在二维空间内进行操作,设置一个角度值,用来指定旋转的幅度. ...

  5. Web之路笔记之一

    简单说一句,现在开始准备面试前端的知识,每天完成相关的任务,记录一些点. 2014秋季学期Web2.0课程习题 <Lab1 - About Me Page> 目标是自己动手写一个粗略的包含 ...

  6. .NET 框架程序使用 Win32 API

    .NET 框架程序可以通过静态 DLL 入口点的方式来访问本机代码库.DllImport 属性用于指定包含外部方法的实现的dll 位置.       DllImport 属性定义如下:      na ...

  7. [HTML/CSS] ul元素居中处理

    CSS: <style type="text/css"> #nav_sub_page { text-align: center; width: 80%; } #nav_ ...

  8. Minimum Depth of Binary Tree [LeetCode]

    Given a binary tree, find its minimum depth. The minimum depth is the number of nodes along the shor ...

  9. js实现图片的大小自适应效果

    需求是传过来一个图片,根据外层div的大小自动进行缩放效果. function ShowSecondImg(v) { var rate, newX, newY,newW, newH = 0; //表示 ...

  10. Android开发--apk的生成

    0.前言 此方法为eclipse中生成apk的方法!!!! 1.生成ketstore 在命令提示符中找到java的jdk路径,例如: D:\study software\Java\jdk1.8.0_2 ...