Friday, May 23, 2014

HTML TUTORIAL PART 58

HTML TUTORIAL PART 58

PROBLEM:
LOOK AT THE FOLLOWING:

This is some text.
This is some text.
Note: For :first-child to work in IE8 and earlier, a DOCTYPE must be declared.

SOLVED:
THE CODE BELOW MADE THE HTML TIP:

<!DOCTYPE html>
<html>
<head>
<style>
p:first-child
{
color:blue;
}
</style>
</head>

<body>
<p>This is some text.</p>
<p>This is some text.</p>
<p><b>Note:</b> For :first-child to work in IE8 and earlier, a DOCTYPE must be declared.</p>
</body>
</html>

No comments:

Post a Comment