 
 Data Structure Data Structure
 Networking Networking
 RDBMS RDBMS
 Operating System Operating System
 Java Java
 MS Excel MS Excel
 iOS iOS
 HTML HTML
 CSS CSS
 Android Android
 Python Python
 C Programming C Programming
 C++ C++
 C# C#
 MongoDB MongoDB
 MySQL MySQL
 Javascript Javascript
 PHP PHP
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
CSS Articles - Page 129 of 160
 
 
			
			200 Views
Use the CSS :first-child selector to style every elements that is the first child of its parent.ExampleYou can try to run the following code to implement the :first-child selectorLive Demo p:first-child { background-color: orange; } Heading This is demo text. This is demo text, with the first child of its parent div. This is demo text, but not the first child.
 
 
			
			263 Views
The position: absolute; property allows you to position element relative to the nearest positioned ancestor.ExampleYou can try to run the following code to implement CSS position: absolute;Live Demo div.one { position: relative; width: 500px; height: 150px; border: 2px solid blue; } div.two { position: absolute; top: 70px; right: 0; width: 300px; height: 50px; border: 2px solid yellow; } position: absolute; The position: absolute; property allows you to position element relative to the nearest positioned ancestor. div has position: relative; div has position: absolute;
 
 
			
			975 Views
To style every element that has no children with CSS, use the: empty selector t. You can try to run the following code to implement the: empty selectorExampleLive Demo p.demo { width: 300px; height: 20px; background: gray; } p:empty { width: 150px; height: 20px; background: orange; } This is demo text. Below is empty text.
 
 
			
			234 Views
Use the matrix3d(n,n,n,n,n,n,n,n,n,n,n,n,n,n,n,n) method to transform the element using 16 values of matrix.Let us see the syntaxmatrix3d(a1, b1, c1, d1, a2, b2, c2, d2, a3, b3, c3, d3, a4, b4, c4, d4)Here, a1 b1 c1 d1 a2 b2 c2 d2 a3 b3 c3 d3 d4 are numbers showing the linear transformationa4 b4 c4 are numbers describing the translation to apply.
 
 
			
			214 Views
Use the CSS :empty selector to style every element that has no children with CSS. You can try to run the following code to implement the :empty selector −ExampleLive Demo p.demo { width: 300px; height: 20px; background: gray; } p:empty { width: 150px; height: 20px; background: orange; } This is demo text. Below is empty text.



