Review CSS Selectors
Throughout this lesson, you learned how to select HTML elements with CSS and apply styles to them. Let's review what you learned:
CSS can change the look of HTML elements. In order to do this, CSS must select HTML elements, then apply styles to them.
CSS can select HTML elements by tag, class, or ID.
Multiple CSS classes can be applied to one HTML element.
Classes can be reusable, while IDs can only be used once.
IDs are more specific than classes, and classes are more specific than tags. That means IDs will override any styles from a class, and classes will override any styles from a tag selector.
Multiple selectors can be chained together to select an element. This raises the specificity, but can be necessary.
Nested elements can be selected by separating selectors with a space.
The !important flag will override any style, however it should almost never be used, as it is extremely difficult to override.
Multiple unrelated selectors can receive the same styles by separating the selector names with commas.
Great work this lesson. With this knowledge, you'll be able to use CSS to change the look and feel of websites to make them look great.
Review CSS Selectors的更多相关文章
- BeautifulSoup高级应用 之 CSS selectors /CSS 选择器
BeautifulSoup支持最常用的CSS selectors,这是将字符串转化为Tag对象或者BeautifulSoup自身的.select()方法. 本篇所使用的html为: html_doc ...
- 转:SELENIUM TIPS: CSS SELECTORS
This page will show you some CSS rules and pseudo-classes that will help you move your XPATH locator ...
- (3)选择元素——(4)css选择器(CSS selectors)
The jQuery library supports nearly all of the selectors included in CSS specifications 1 through 3, ...
- CSS selectors for Selenium with example,selenium IDE
CSS selectors for Selenium with example http://seleniumeasy.com/selenium-tutorials/css-selectors-tut ...
- [Selenium] 在Chrome的开发者工具中验证检查XPath/CSS selectors
Evaluate and validate XPath/CSS selectors in Chrome Developer Tools Method 1 : From Elements panel U ...
- css selectors tips
from https://saucelabs.com/resources/articles/selenium-tips-css-selectorsSauce Labs uses cookies to ...
- CSS Selectors
CSS selectors are used to "find" (or select) HTML elements based on their element name, id ...
- Why are dashes preferred for CSS selectors / HTML attributes?
Why are dashes preferred for CSS selectors / HTML attributes? I use dashes because I don't have to h ...
- flight.Archives001 / CSS Selectors选择器
Title/CSS选择器 序 : 这是flight.Archives 梦开始的地方, 作者我熬夜肝出来了这篇文章... 保证这是最简洁高效的 CSS Selectors 教程 Note : 暂时没有能 ...
随机推荐
- 将OpenVZ系统硬盘从200G升级到400G
平时习惯性动作df了一下,结果发现...... ‘ 200G的磁盘空间快满了(99%),只剩下2G多了. 索性一下加到400G空间 目前为止很顺利. 但是OpenVZ这台需要关机再开机才行. 重新开机 ...
- keras LSTM学习实例
1. 购物时间预测 http://www.cnblogs.com/arkenstone/p/5794063.html https://github.com/CasiaFan/time_seires_p ...
- [UE4]碰撞的随机性
物理引擎(包括碰撞)的计算具有随机性 原因: 一.每一帧的时间并不是严格相等 二.浮点数计算不是完全准确(两个浮点数运算,结果不可重复) 影响 在左边窗口(服务器端)打几发子弹把其中3个立方体的位置打 ...
- 2018年最新PHP面试题
面试之前多看看公司的资料,可以看出面试的公司主要做什么,电商,数据库,php函数,sql的优化,接口,session和cookie等经常会问到,都是必问之题,这其中有一部分题目摘抄自网络,回答也不错 ...
- MySQL 索引建立原则及注意事项
一.索引建立的几大原则: 1) 最左前缀匹配原则,非常重要的原则,mysql会一直向右匹配直到遇到范围查询(>.<.between.like)就停止匹配,比如a = 1 and b = 2 ...
- DB通用类:MySQL通用类
Mysql类为网络上收集的,没有测试过.. using System; using System.Collections; using System.Collections.Generic; usin ...
- python+selenium+PhantomJS批量投递智联简历(不要用自己的账号进行测试,请使用小号,很烦人的,哈哈哈)
1.环境python2.7+selenium+PhantomJS(软件安装和库的安装网上都有教程我们跳过,so easy) 2.原理 绕过首页登录需要验证码,直接进入搜索栏,输入搜索的职位+地区搜索出 ...
- Django中常用命令
Django 基本命令 熟练使用Django常用命令能让你事半功倍!!!! 1. 新建一个 django project django-admin.py startproject project-na ...
- Python网络爬虫相关基础概念
什么是爬虫 爬虫就是通过编写程序模拟浏览器上网,然后让其去互联网上抓取数据的过程. 哪些语言可以实现爬虫 1.php:可以实现爬虫.php被号称是全世界最优美的语言(当然是其自己号称的,就是王婆 ...
- MySQL通过游标来实现通过查询结果集循环
/*我们有时候会遇到需要对 从A表查询的结果集S_S 的记录 进行遍历并做一些操作(如插入),且这些操作需要的数据或许部分来自S_S集合*/ /*临时存储过程,没办法,不能直接在查询窗口做这些事.*/ ...