Bug 8426

Summary: CSS: last-child pseudo-class doesn't work correctly
Product: WebKit Reporter: Thomas Steinacher <eggdrop>
Component: CSSAssignee: Nobody <webkit-unassigned>
Status: RESOLVED DUPLICATE    
Severity: Normal    
Priority: P2    
Version: 420+   
Hardware: Mac   
OS: OS X 10.4   

Thomas Steinacher
Reported 2006-04-16 12:59:37 PDT
In the following example, "GREEN" should be green, "BLACK" should be black and "RED" should be red. However, in Safari everything is red. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html> <head> <style> #c div:first-child { color:green; } #c div:last-child { color:red; } </style> </head> <body> <div id="c"><div>GREEN</div> <div>BLACK</div> <div>RED</div></div> </body> </html>
Attachments
mitz
Comment 1 2006-04-16 13:12:54 PDT
Dupe of bug 4812. *** This bug has been marked as a duplicate of 4812 ***
Note You need to log in before you can comment on or make changes to this bug.