New selector

Selector (selector):
ID Type class (div span ...) select progeny pseudo class selector pseudo-element selector ...

		属性选择器:
			e[attr]	选中e元素,且e元素有attr属性
			e[attr="value"] 选中e元素,且e元素有attr属性,值为value
			e[attr~="value"] 选中e元素,且e元素有attr属性,包含值value
			e[attr^="value"] 选中e元素,且元素有attr属性,以value值开头
			e[attr$="value"] 选中e元素,且有attr属性,以value值结尾
			e[attr*="value"] 选中e元素,且有attr属性,包含value值
			e[attr|="value"] 选中e元素,且有attr属性,仅有value值,或者以value-开头

Pseudo class selector structure:
: First-Child {} select the first element
: last-child () the last selected element
: nth-child (n) { } n is from 0 started,
2N even columns of the even
2N. 1- odd column oDD
: {} Child-only select only a sibling element itself
: nth-last-child (n ) {} n-th element of the inverse of

Published 10 original articles · won praise 1 · views 32

Guess you like

Origin blog.csdn.net/qq_46591632/article/details/105034465