/*选择带有id属性的元素*/
a[id]{
background: yellow;
}
a[id=first]{
background: red;
}
/*class属性中包含item的元素*/
a[class*="item"]{
background: deeppink;
}
/*选中href中以http开头的元素*/
a[href^=http]{
background: blueviolet;
}
/*选中href中以pdf结尾的元素*/
a[href$=pdf]{
background: gray;
}