Prev Demo
CSS3
>
First-Of-Type Selector
Next Demo
Write code here
J
|
B
|
A
<!DOCTYPE html> <html> <head> <title>Demo</title> </head> <body> <style> p:first-of-type { color:blue; background-color:orange; font-family:20px; } </style> <strong>This is Strong Statement</strong> <p>This is 1st paragraph.</p> <p>This is 2nd paragraph.</p> <b>This is Bold.</b> <div> <p>This is the first pargarph in div.</p> <p>This is the second paragraph in div.</p> </div> </body> </html>
Note: We DO NOT save your trial code in our database.
Output