Closed Bug 287312 Opened 19 years ago Closed 19 years ago

unnecessary/wrong elements in external css file will cause the first style to be ignored

Categories

(Core :: CSS Parsing and Computation, defect)

x86
Windows XP
defect
Not set
minor

Tracking

()

RESOLVED INVALID

People

(Reporter: tender-edge, Assigned: dbaron)

References

Details

User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 5.1; zh-CN; rv:1.7.6) Gecko/20050226 Firefox/1.0.1 (ax)
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; zh-CN; rv:1.7.6) Gecko/20050226 Firefox/1.0.1 (ax)

/////////////////begin css file////////////////
anything wrong


body {  font-family: "arial, 宋体"; font-size: 9pt; line-height: 13pt;
background-color: #E5EFE0;}
table {  font-family: "arial, 宋体";font-size: 9pt; line-height: 13pt;}

/////////////////end css file////////////////

above is a sample css file, there is an unecessary/wrong enlement "anything
wrong" on top, this will cause the first style -- "body" be ignored by firefox,
adding blank lines after the wrong line won't fix.

if we modify it to

/////////////////begin css file////////////////
anythingwrong
wrong again

dummy {}
body {  font-family: "arial, 宋体"; font-size: 9pt; line-height: 13pt;
background-color: #E5EFE0;}
table {  font-family: "arial, 宋体";font-size: 9pt; line-height: 13pt;}

/////////////////end css file////////////////

then every style seem to be processed, so I conclude that the first style be
ingnored/wrongly processed by the processor, and also adding any more wrong
lines won't cause more style to be ignored.

Reproducible: Always

Steps to Reproduce:
1. add any wrong lines in front of an external css file
I changed the Severity to "minor", sine it should be a fault-tolerance function
Severity: normal → minor
how are you proposing that Firefox determine where the unnecessary stuff ends
and the first style begins?
Assignee: firefox → dbaron
Component: General → Style System (CSS)
Product: Firefox → Core
QA Contact: general → ian
Version: unspecified → Trunk
This is invalid. See bug 149466, bug 221274, bug 234508 and bug 274012.
Status: UNCONFIRMED → RESOLVED
Closed: 19 years ago
Resolution: --- → FIXED
Status: RESOLVED → UNCONFIRMED
Resolution: FIXED → ---
Status: UNCONFIRMED → RESOLVED
Closed: 19 years ago19 years ago
Resolution: --- → INVALID
*** Bug 293142 has been marked as a duplicate of this bug. ***
You need to log in before you can comment on or make changes to this bug.