Last modified: 2012-04-12 13:54:27 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T31480, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 29480 - "Content" word in heading gets rendered with id="content"
"Content" word in heading gets rendered with id="content"
Status: RESOLVED DUPLICATE of bug 7356
Product: MediaWiki
Classification: Unclassified
Parser (Other open bugs)
1.16.x
All All
: Unprioritized trivial (vote)
: ---
Assigned To: Nobody - You can work on this!
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2011-06-18 19:06 UTC by gennady
Modified: 2012-04-12 13:54 UTC (History)
4 users (show)

See Also:
Web browser: Google Chrome
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments
a = content = markup turns into a content border (13.18 KB, image/jpeg)
2011-06-18 19:06 UTC, gennady
Details

Description gennady 2011-06-18 19:06:53 UTC
Created attachment 8680 [details]
a = content = markup turns into a content border

A heading named content is attributed with an id of "content", the CSS for which has a border, etc.

= content =
== content ==
=== content ===

Temporary workarounds include = content  = (tested) and adding #content to the Common.css probably (not tested)

Thank you.
Comment 1 Subfader 2011-06-18 19:30:45 UTC
Problem: = content = produses an a tag with id="content" which is used by a layout div already.

Solution: The skins' main.css files need be more precise using e.g. div#content instead of #content.
Comment 2 gennady 2011-06-18 19:37:47 UTC
An HTML page should not have two of the same id attributes on one page, so CSS selector specificity is a good workaround but not a good fix. The bug produces two id="content" elements, apart from W3C non-conformance, nothing bad will happen unless one tries to traverse the DOM with two elements with asme id attributes. Trivial, slim chances of that ever happening.
Comment 3 Subfader 2011-06-18 19:49:22 UTC
The css uses div#content already in 1.17.0rc1.
Comment 4 Roan Kattouw 2011-06-18 20:26:06 UTC

*** This bug has been marked as a duplicate of bug 7356 ***
Comment 5 Krinkle 2011-06-21 23:57:21 UTC
(In reply to comment #1)
> Problem: = content = produses an a tag with id="content" which is used by a
> layout div already.
> 
> Solution: The skins' main.css files need be more precise using e.g. div#content
> instead of #content.
No need for an extra specific selector. #content is just fine, adding div in front of it adds more weight and could cause problems in other skins that are making assumptions on the cascading effects of CSS.

(In reply to comment #2)
> The bug produces
> two id="content" elements, apart from W3C non-conformance, nothing bad will
> happen unless one tries to traverse the DOM with two elements with asme id
> attributes. Trivial, slim chances of that ever happening.
Not trivial at all in my opinion. #content is one of the few elements that has a consistent ID in all skins, There are a huge amount of scripts referring to it through JavaScript DOM traversal.

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links