Doesn't handle correctly multiple external stylesheets when title attribute used in html <link> tag




14 years ago
14 years ago


(Reporter: markus, Assigned: bugzilla)


Firefox Tracking Flags

(Not tracked)




14 years ago
User-Agent:       Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7.5) Gecko/20041107 Firefox/1.0
Build Identifier: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7.5) Gecko/20041107 Firefox/1.0

If I have an (x)html page (which validates) having multiple references to
external style sheets and all or more than one of them has title attribute in
<link> tag, firefox reads and uses only the first one of stylesheets having
title attribute in referring <link> tag. Example:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"

<html xmlns="">
  <meta name="generator" content="Vi IMproved" />
  <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
  <link rel="stylesheet" type="text/css" href="vuoret.css" />
  <link rel="stylesheet" title="vieraskirja" type="text/css"
href="vieraskirja.css" />
  <link rel="stylesheet" title="lomake" type="text/css" href="lomake.css" />

In the example above only the vuoret.css and vieraskirja.css are used. However,
if I remove the 'title="vieraskirja"' attribute, all the css files are used and
page works correctly.

Reproducible: Always

Steps to Reproduce:
Write an xhtml page having multiple references to external css files and all the
<link> tags having title attributes. Try the page with Firefox.
Actual Results:  
One or more external stylesheets are not used and page shows up incorrectly.

Expected Results:  
Show page having css displayed correctly.

Comment 1

14 years ago
By adding a title you are designated the stylesheet as the preferred stylesheet,
and there can only be one of those per document.  So the rest are disregarded. 
So what you are seeing is what should happen.
Last Resolved: 14 years ago
Resolution: --- → INVALID
You need to log in before you can comment on or make changes to this bug.