The :not pseudo-class selector can filter elements that do not match the expression example table tbody tr:not(:first-child):not(:last-child) td { text-align: right; } The above code can select the non-first and non-last tr in the tbody part of the table, and set the text style of its child td element to the right Here we need to pay attention to the grammatical format of not: Single not writing: /*Select non-paragraph elements*/ :not(p) { } How to write multiple not /*Select the middle p element in the div that is neither the first nor the last*/ div p:not(:first-child):not(:last-child){ } The above is the full content of this article. I hope it will be helpful for everyone’s study. I also hope that everyone will support 123WORDPRESS.COM. |
<<: Design theory: the basics of font design
>>: Summary of MySQL logical backup and recovery testing
<br />What is web2.0? Web2.0 includes those ...
The specific code is as follows: <div id="...
Introduction: Compared with traditional image ver...
This effect is most common on our browser page. L...
Preface In the case of primary key conflict or un...
Table of contents 1. Constraint concepts and clas...
1. Unzip the downloaded MySQL compressed package ...
After installing MySQL, enter mysql -u root -p in...
After MySQL is installed, you can verify whether ...
Use div to create a mask or simulate a pop-up wind...
Table of contents Common functions of linux drive...
First time writing. Allow me to introduce myself....
Preface Bootstrap, the most popular front-end dev...
Table of contents Inheritance ES5 prototype inher...
In the previous article, we played with timeouts ...