Bug 164687 - Syntax Errors on fedora.redhat.com.
Syntax Errors on fedora.redhat.com.
Product: Fedora Infrastructure
Classification: Retired
Component: website (Show other bugs)
All Linux
medium Severity medium
: ---
: ---
Assigned To: Greg DeKoenigsberg
Elliot Lee
Depends On:
  Show dependency treegraph
Reported: 2005-07-30 05:45 EDT by Terje Bless
Modified: 2007-04-18 13:30 EDT (History)
2 users (show)

See Also:
Fixed In Version: 20051115
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2005-11-15 18:38:43 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Terje Bless 2005-07-30 05:45:38 EDT
The markup on <http://fedora.red.hat.com/> has several syntax errors
(cf. the URL field).

The code for the navigation menu tries to embed an UL inside a P -- 
which isn't allowed; P cannot contain block level elements such as UL --
and the second news item contains a botched end tag for the STRONG element
('<strong') which, while technically valid SGML, isn't supported by UAs.

There are also several uses of physical markup -- such as HR and BR --
which is unfortunate. The markup for news items should probably be changed
to something like:

  <div class="newsitem">
    <h2>Fedora Core 4 Available!</h2>
Comment 1 Patrick Barnes 2005-11-15 16:17:45 EST
I've corrected the navigation menu to use a <div> element instead of a <p>
element.  While both of these elements are block-level elements, the <p> element
should not contain other block-level elements.  The <div> element can.


The <strong> closing tag has been fixed, I've also ensured that the other tags
match case, and added embedded closing tags to some of the includes (eg. <img
... />) that put the code more inline to newer standards.

I have not changed the structure of anything, nor will I at this time.  I have
left the <hr> and <br> tags as they are.  Restructuring doesn't seem logical
considering the plans currently in place for fedora.redhat.com.

I'm closing this bug as CURRENTRELEASE.  Standards compliance is an ongoing
effort that we should pay attention to as we move forward.  Thank you for your
Comment 2 Terje Bless 2005-11-15 16:58:43 EST
(In reply to comment #1)
> [I've] added embedded closing tags to some of the includes (eg. <img
> ... />) that put the code more inline to newer standards.

Unfortunately, that construct is incorrect in HTML 4.01 so this actually
introduces new syntax errors.

The "meta" (and "link", for that matter) element is defined in the DTD as

  <!ELEMENT META - O EMPTY               -- generic metainformation -->

which means the element has its "declared content" set to "EMPTY" and
thus the end tag (even a minimized one) must be omitted.
Comment 3 Patrick Barnes 2005-11-15 17:18:47 EST
If we are going to keep the infrastructure for fedora.redhat.com as it currently
is, then it would be nice to migrate it to XHTML (where the closing tags would
be required).  You are correct that it is not technically accurate to use
closing tags with HTML 4.01.  I will keep this issue in mind for the near
future, and I will bring everything in line with one or the other once the fate
of fedora.redhat.com is decided.  Either direction still needs a bit of work. 
Although removing the closing tags would allow the front page of the site to
validate using the W3C's SGML validator, there are other issues elsewhere in the
site and beyond the validator's detection that could also use some love.
Comment 4 Terje Bless 2005-11-15 17:39:22 EST
For several reasons, some of which are enumerated or alluded to here
<http://www.hixie.ch/advocacy/xhtml>, I would strongly suggest avoiding
XHTML for the time being.
Comment 5 Patrick Barnes 2005-11-15 18:21:20 EST
I acknowledge that mixing standards to make things work right invalidates their
initial purpose.  We have the capability to use XHTML properly, and I think we
should prepare ourselves to use it.  Whether or not we should make this change
now or later is a subject that could spark significant debate.  I will agree
that my placement of the closing tags in a document using the HTML DTD and
mimetype was not correct by standards, I'm just really more interested in the
best long-term solution than with nitpicking against the current, stale site.

Overall, I think the best solution for the site is to abstract content from
structure as much as possible.  The Documentation Project already achieves this
using DocBook.  Use of XML and related technologies on the server side,
intelligent scripting, and careful attention to standards would provide us with
a powerful and versatile solution.  I would certainly go along with the use of
scripting to parse XML data (our content) and, based upon the HTTP request
header, send the output as one of HTML, XHTML, or XML, as appropriate.  If we
abstract the content in this matter, it also becomes easy to use other formats
as well.

Either way we go, I don't want to devote too much time or too many resources to
fedora.redhat.com until its fate is decided.
Comment 6 Patrick Barnes 2005-11-15 18:38:43 EST
Alright, I've made sufficient changes for the page to validate.  This will
suffice until any larger venture begins.

I'm once again closing this bug.  Any further issues with standards compliance
should be discussed at fedora-websites-list@redhat.com.

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