[CSS3] Use Sticky Positioning for Section Headers
We can take advantage of sticky positioning to keep a section header at the top of the page while the user scrolls. This is useful for neat categorisation of sections on the page.
<dl>
<dt>Premier League</dt>
<dd>Brighton & Hove Albion 2 - 2 AFC Bournemouth</dd>
<dd>Burnley 1 - 2 Liverpool</dd>
<dd>Leicester City 3 - 0 Huddersfield Town</dd>
<dd>Stoke City 0 - 1 Newcastle United</dd>
<dd>Everton 0 - 1 Manchester United</dd> <dt>Championship</dt>
<dd>Bolton Wanderers 1 - 0 Hull City</dd>
<dd>Derby County 1 - 1 Sheffield United</dd>
<dd>Leeds United 0 - 0 Nottingham Forest</dd>
<dd>Norwich City 2 - 1 Millwall</dd>
<dd>Preston North End 2 - 3 Middlesbrough</dd>
<dd>Queens Park Rangers 2 - 1 Cardiff City</dd>
<dd>Sheffield Wednesday 0 - 3 Burton Albion</dd>
<dd>Sunderland 0 - 1 Barnsley</dd>
<dd>Aston Villa 3 - 0 Bristol City</dd> <dt>League 1</dt>
<dd>AFC Wimbledon 2 - 0 Southend United</dd>
<dd>Bristol Rovers 2 - 1 Portsmouth</dd>
<dd>Charlton Athletic 1 - 2 Gillingham</dd>
<dd>Fleetwood Town 1 - 2 Bradford City</dd>
<dd>Northampton Town 0 - 1 Wigan Athletic</dd>
<dd>Oxford United 3 - 1 Milton Keynes Dons</dd>
<dd>Peterborough United 1 - 1 Doncaster Rovers</dd>
<dd>Plymouth Argyle 1 - 0 Walsall</dd>
<dd>Rochdale 1 - 2 Blackpool</dd>
<dd>Rotherham United 1 - 1 Blackburn Rovers</dd>
<dd>Scunthorpe United 1 - 0 Bury</dd>
<dd>Shrewsbury Town 1 - 0 Oldham Athletic</dd>
</dl>
dl {
font-size: 30px;
}
dt {
background-color: mediumseagreen;
position: sticky; /*sticky positioning*/
position: -webkit-sticky;
top:;
}
dd {
padding: 20px 0;
}
[CSS3] Use Sticky Positioning for Section Headers的更多相关文章
- ConfigParser.MissingSectionHeaderError: File contains no section headers.
今天使用ConfigParser解析一个ini文件,报出如下错误: config.read(logFile) File "C:\Python26\lib\ConfigParser.py&qu ...
- python ConfigParser读取配置文件,及解决报错(去掉BOM)ConfigParser.MissingSectionHeaderError: File contains no section headers的方法
先说一下在读取配置文件时报错的问题--ConfigParser.MissingSectionHeaderError: File contains no section headers 问题描述: 在练 ...
- 【问题解决方案】CentOS7替换yum的问题:使用yum makecache出现File contains no section headers
参考链接 CentOS7替换yum的问题:使用yum时出现File contains no section headers centos安装网络repo源及错误说明 一.centos替换yum的步骤 ...
- Android7.0后JNI库必须保留Section Headers
此修改在官网的描述如下: Each ELF file has additional information contained in the section headers. These header ...
- css3 position:sticky
最近在写一个小程序,项目中遇到一个需求:页面滚动到tab切换菜单时,菜单fixed到页面顶部: 实现方法: 使用小程序的onPageScroll事件,滚动到指定位置添加fixed样式: bug1:获取 ...
- raise missingsectionheadererror:file containe no section headers问题解决
本人亲测,遇到这个问题,就换到管理员方式运行命令 因为太小白,所以这次重新装包的时候切换到D盘了,想着省一点儿C盘内存,结果,每次pip install安装的时候都是这个问题,中间还有什么反序列失败, ...
- CentOS7使用yum时File contains no section headers.解决办法
本文转载于 https://blog.csdn.net/trokey/article/details/84908838 安装好CenOS7后,自带的yum不能直接使用,使用会出现如下问题: 原因是没 ...
- CSS3与页面布局学习总结(三)——BFC、定位、浮动、7种垂直居中方法
一.BFC与IFC 1.1.BFC与IFC概要 BFC(Block Formatting Context)即“块级格式化上下文”, IFC(Inline Formatting Context)即行内格 ...
- CSS3与页面布局学习总结(四)——页面布局大全BFC、定位、浮动、7种垂直居中方法
目录 一.BFC与IFC 1.1.BFC与IFC概要 1.2.如何产生BFC 1.3.BFC的作用与特点 二.定位 2.2.relative 2.3.absolute 2.4.fixed 2.5.z- ...
随机推荐
- python自动化测试学习笔记-4常用模块
常用模块 1.os 2.sys 3.random 4.string 5.time 6.hashlib 一.os模块 os模块主要用来操作文件.目录,与操作系统无关.要使用os模块首先要导入OS模块,用 ...
- Zabbix Server参数文件详解
Zabbix的配置文件一般有三种: zabbix_server.conf:zabbix server的配置文件 zabbix_proxy.conf:zabbix proxy的配置文件 zabbix_a ...
- S2深入.NET编程总结
不知从几何时,我也开始变得懒了,以往为了学习的那股子斗劲也早已不在,是时候反思反思了.失败的检测成绩希望可以把我唤醒. 经过总结,在本书中大概学到了这些知识: 1.如果一个类可序列化,则它的子类和包含 ...
- JS——input标签注册事件
注意:淘宝的lable是用定位制作的,事件是oninput事件 <!DOCTYPE html> <html> <head lang="en"> ...
- Centos 修改源
1首先备份原来的配置文件: mv /etc/yum.repos.d/CentOS-Base.repo /etc/yum.repos.d/CentOS-Base.repo.backup 2下载对应版本r ...
- Web 服务器与应用服务器的区别是什么?
不太严谨的说法:web服务器就是负责接收用户的Request,然后响应html等给客户浏览器.应用服务器处理一些业务逻辑等. 作者:luo链接:https://www.zhihu.com/questi ...
- CAD把实体放到当前选择集中
主要用到函数说明: _DMxDrawX::AddCurrentSelect 把实体放到当前选择集中,详细说明如下: 参数 说明 LONGLONG lId 实体id VARIANT_BOOL isSho ...
- 00 python基础知识
''' ''' print('hello world!') ''' 变量 ''' # 变量的:‘tank’,会在内存中产生一份内存地址 #变量名:相当于一个门牌号,用于与变量进行绑定 # = :用来把 ...
- css页面布局总结
W3C标准:是万维网制定的一系列标准,包括结构化标准语言(html.xml),表现 标准语言(css),行为标准语言(DOM,ECMAScript<javascript>)组成.这个标准倡 ...
- js的基础运用
总结: 1.定义:分为隐式定义和显式定义可以先定义后赋值. 2.+:当两边都是数值则运行加法运算,若一遍是字符型则进行拼接. 3.数值变字符:数值变量.toString()方法. 字符变数值:通过加一 ...