Return-Path: Delivered-To: apmail-cocoon-users-archive@www.apache.org Received: (qmail 92909 invoked from network); 24 Nov 2004 08:47:04 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur-2.apache.org with SMTP; 24 Nov 2004 08:47:04 -0000 Received: (qmail 62829 invoked by uid 500); 24 Nov 2004 08:46:59 -0000 Delivered-To: apmail-cocoon-users-archive@cocoon.apache.org Received: (qmail 62785 invoked by uid 500); 24 Nov 2004 08:46:58 -0000 Mailing-List: contact users-help@cocoon.apache.org; run by ezmlm Precedence: bulk list-help: list-unsubscribe: list-post: Reply-To: users@cocoon.apache.org Delivered-To: mailing list users@cocoon.apache.org Received: (qmail 62769 invoked by uid 99); 24 Nov 2004 08:46:58 -0000 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests=FORGED_RCVD_HELO X-Spam-Check-By: apache.org Received-SPF: neutral (hermes.apache.org: local policy) Received: from [195.130.132.56] (HELO adicia.telenet-ops.be) (195.130.132.56) by apache.org (qpsmtpd/0.28) with ESMTP; Wed, 24 Nov 2004 00:46:55 -0800 Received: from localhost (localhost.localdomain [127.0.0.1]) by adicia.telenet-ops.be (Postfix) with SMTP id 408904414D for ; Wed, 24 Nov 2004 09:46:40 +0100 (MET) Received: from 192.168.2.9 (d51A4D9C0.kabel.telenet.be [81.164.217.192]) by adicia.telenet-ops.be (Postfix) with ESMTP id 2928F44042 for ; Wed, 24 Nov 2004 09:46:40 +0100 (MET) Subject: Re: Using htmlArea 'output' with SVG From: Bruno Dumon To: users@cocoon.apache.org In-Reply-To: <41A4455D.6060108@cbim.it> References: <41A4455D.6060108@cbim.it> Content-Type: text/plain Organization: Outerthought Date: Wed, 24 Nov 2004 09:44:28 +0100 Message-Id: <1101285868.6532.158.camel@yum.site> Mime-Version: 1.0 X-Mailer: Evolution 2.0.2 Rubber Turnip www.usr-local-bin.org Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N On Wed, 2004-11-24 at 09:25 +0100, Ugo Cei wrote: > Derek Hohls wrote: > > Brunor - I thought Ugo was the once who came up > > with the code we were talking about - its called "HTMLparser" > > (was attached to a previous email) ... what is the difference > > between these two?? > > Without having seen Bruno's code, the difference is probably that mine > is a quick and dirty solution that got the job done for me when I needed > it, whereas Bruno's is a reusable, well-documented, efficient component :) Nah, the HtmlCleaner serves a different purpose alltogether. It starts with parsing the input using NekoHTML, but then performs further filtering, conversion and restructuring on it to have a nice output, limitted to a subset of the HTML dtd. At the end it serializes it pretty, ie whitespace collapsing, line breaks at a certain width, etc. One consequence is that if you enter the same text in Mozilla or IE, you'll get the same textual output (there's still some small things left that need to be fixed), allowing to do source-diffs on the edited content. Thus the end result is a string (or byte array) which will need to be parsed again. If you want to allow any HTML, not limited to a certain (configurable) subset of the HTML DTD, simply use plain NekoHTML. -- Bruno Dumon http://outerthought.org/ Outerthought - Open Source, Java & XML Competence Support Center bruno@outerthought.org bruno@apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org For additional commands, e-mail: users-help@cocoon.apache.org