This is an archived snapshot of W3C's public bugzilla bug tracker, decommissioned in April 2019. Please see the home page for more details.

Bug 3448 - nested tags should be flaged as invalid
Summary: nested tags should be flaged as invalid
Alias: None
Product: Validator
Classification: Unclassified
Component: check (show other bugs)
Version: HEAD
Hardware: All All
: P2 normal
Target Milestone: ---
Assignee: Terje Bless
QA Contact: qa-dev tracking
Depends on:
Reported: 2006-07-12 23:27 UTC by Ervin
Modified: 2006-07-21 02:26 UTC (History)
0 users

See Also:


Description Ervin 2006-07-12 23:27:05 UTC
Overview Description:
According to
a form tag cannot be a descendant of another form tag
However, a nested form validates correctly.

Steps to Reproduce:

Validate this test case:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
<html xmlns="" xml:lang="en">
<meta http-equiv="content-type" content="text/html; charset=iso-8859-1" />
<form id="f1" action="/action0">
<div><form  id="f2" action="/action1"><div>hello 1</div></form></div>

Actual Results:
Passed validation

Expected Results:
Failed validation, 1 error

Build & Date
Markup Validation Service v0.7.2 on 2006-07-12
Comment 1 Olivier Thereaux 2006-07-21 02:26:21 UTC
The nesting scenario you describe is indeed non conformant (as explained in ) but if you look at in the XHTML specification, you will see an explanation of why constraints regarding *any* nesting depth cannot be expressed in the formal grammar (DTD) used by XHTML 1.0, and therefore it can not be (in)validated.

I am setting this issue as "Later", knowing that this is the job for a conformance checker, not a mere validator.