Return-Path: Delivered-To: apmail-forrest-dev-archive@www.apache.org Received: (qmail 46723 invoked from network); 2 May 2005 15:39:06 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 2 May 2005 15:39:06 -0000 Received: (qmail 58060 invoked by uid 500); 2 May 2005 15:40:31 -0000 Delivered-To: apmail-forrest-dev-archive@forrest.apache.org Received: (qmail 58009 invoked by uid 500); 2 May 2005 15:40:30 -0000 Mailing-List: contact dev-help@forrest.apache.org; run by ezmlm Precedence: bulk list-help: list-unsubscribe: List-Post: Reply-To: dev@forrest.apache.org Delivered-To: mailing list dev@forrest.apache.org Received: (qmail 57993 invoked by uid 99); 2 May 2005 15:40:30 -0000 X-ASF-Spam-Status: No, hits=0.1 required=10.0 tests=FORGED_RCVD_HELO X-Spam-Check-By: apache.org Received-SPF: neutral (hermes.apache.org: local policy) Received: from natsmtp00.rzone.de (HELO natsmtp00.rzone.de) (81.169.145.165) by apache.org (qpsmtpd/0.28) with ESMTP; Mon, 02 May 2005 08:40:30 -0700 Received: from 192.168.2.3 (80-28-200-151.adsl.nuria.telefonica-data.net [80.28.200.151]) by post.webmailer.de (8.13.1/8.13.1) with ESMTP id j42FccVb021882; Mon, 2 May 2005 17:38:44 +0200 (MEST) Subject: Re: view/viewHelper XHTML code generation From: Thorsten Scherler To: Diwaker Gupta Cc: forrest dev In-Reply-To: <1b0b4557050501225122689ae@mail.gmail.com> References: <1b0b4557050501225122689ae@mail.gmail.com> Content-Type: text/plain Date: Mon, 02 May 2005 17:38:17 +0200 Message-Id: <1115048297.4570.32.camel@localhost.localdomain> Mime-Version: 1.0 X-Mailer: Evolution 2.0.2 Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N Just a quick reply because I am just coming from the beach and have to tranquilize my sunburn ASAP. ;-) All questions already answered by Ross I will not answer. ;-) On Sun, 2005-05-01 at 22:51 -0700, Diwaker Gupta wrote: > Hi everyone, > > There are a number of small but important problems with the > view/viewHelper XHTML code generation. Actually, my guess is that this > is not really a problem of the plugin, since I believe the contract > definition delegates the actual XHTML generation to Cocoon? > > Anyways, basically I took one of the generated pages and ran it > through W3's validator. Here are some of the major problems, and each > one of them should be easily fixable. I'm happy to prepare a patch, > only that I'm not very familiar with the code that does XHTML > generation. So if someone can point me to it, I'll be glad to help. > :) It is mainly produced in the contracts which resides in {viewHelper}/templates. > o generated XHTML starts with an expected behavior. IIRC documents should start with the DOCTYPE tag. > In the current setup, the validator returns a "DTD did not contain > element declaration for document type name" error > > o Then the root element of the XHTML seems to be a tag. There > is NO such tag. Documents *must* have as the root element. > There are no attributes such as xmlns:forrest and xmlns:xi either. Why > do we need them in the generated XHTML anyways? > I will fix that after the sunburn. ;-) > o Many of the "" type tags generated (eg: for section > headings) contain invalid characters. At some places spaces have been > converted to "%". At other places, a long title has been shorted to 2 > words joined together by a "+" sign to generate the value of the > 'name' attribute -- again, XHTML strict does not allow '+' sign in > this context. Why go through all this trouble for character > substitution? Just use spaces :) > That is an old problem that we need to fix as well in views. > o The feedback contract generates a div tag with an attribute > xmlns:jx, which is again invalid. Why is this needed? > This is from an old experiment of mine. ...anyway namespaces *are allowed* in xhtml. http://www.w3.org/TR/xhtml1/#well-formed > Finally, validation will go a lot smoother if we just use XHTML > transitional instead of XHTML strict for now. Once we validate > transitional, we can push for strict. Though I'm all for aiming for > strict from the beginning! > :) I will help you with the patch and if you want to start with transitional that is fine with me (we just have to try going for strict before 0.8 gets out). > cheers, > Diwaker Thanks for your work. salu2 -- thorsten "Together we stand, divided we fall!" Hey you (Pink Floyd)