Maybe I do something wrong, but I don't get the result that I want.
I declared the HTMLGenerator with jtidy-config property and created the
jtidy.properties
file in the same directory with the sitemap.xmap file.
In the jtidy.properties file I wrote the following lines:

output-xml=no
outpu-xhtml=yes
quote-marks=yes
uppercase-tags=no
doctype=transitional

The input html file is:

<html>
 <head>
  <title>Untitled</title>
 </head>
 <body>
  <p>some " text 's
 </body>
</html>

If I run Tidy externally (using tidyui program) with these properties set, I
get the following tidied file:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd";>

<html xmlns="http://www.w3.org/1999/xhtml";>
<head>
    <title>Untitled</title>
</head>

<body>
    <p>some &quot; text &#39;s</p>
</body>
</html>

and that's how I want HTMLGenerator in cocoon to return it too, but if I run
the same input file through cocoon pipeline with HTMLGenerator and serialize
the output as xml, that's what I get:

  <?xml version="1.0" encoding="utf-8" ?>
- <html>
- <head>
  <meta content="HTML Tidy, see www.w3.org" name="generator" />
  <title>Untitled</title>
  </head>
- <body>
  <p>some " text 's</p>
  </body>
  </html>

Maybe someone can explain me what am I doing wrong and how can I make
HTMLGenerator to tidy the input according given properties.

Please help me.
Thank you very much

Anna

----- Original Message -----
From: "Geoff Howard" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Monday, December 16, 2002 4:30 PM
Subject: RE: Configuring JTidy


should be in a file called jtidy.properties in the same directory as the
sitemap?  the properties file style would contain each name=value pair on a
separate line.

Geoff Howard
-----Original Message-----
From: Anna Afonchenko [mailto:[EMAIL PROTECTED]]
Sent: Monday, December 16, 2002 4:15 AM
To: cocoon-users
Subject: Configuring JTidy


Hi all.
I have a very  simple and stupid question.
In the 2.0.4 version of cocoon the HTMLGenerator now can accept a JTidy
configuration file.
The example that is given in the user documentation is:

  <map:generator type="html"
src="org.apache.cocoon.generation.HTMLGenerator">
    <jtidy-config>jtidy.properties</jtidy-config>
  </map:generator>

I am probably very stupid, but from this documentation I don't understand
where am I supposed to write the additional JTidy properties.
Let's say I want to set the following properties:
output-xml=no, output-xhtml=yes,quote-marks=yes
Can someone please give me an example of how am I defining HTMLGenerator to
use this properties when tidying the input file?

Thank you very much for help.

Anna


---------------------------------------------------------------------
Please check that your question  has not already been answered in the
FAQ before posting.     <http://xml.apache.org/cocoon/faq/index.html>

To unsubscribe, e-mail:     <[EMAIL PROTECTED]>
For additional commands, e-mail:   <[EMAIL PROTECTED]>


---------------------------------------------------------------------
Please check that your question  has not already been answered in the
FAQ before posting.     <http://xml.apache.org/cocoon/faq/index.html>

To unsubscribe, e-mail:     <[EMAIL PROTECTED]>
For additional commands, e-mail:   <[EMAIL PROTECTED]>

Reply via email to