W3C home > Mailing lists > Public > html-tidy@w3.org > April to June 2002

Tidy adding returns between xml elements

From: Howard, Kipp (LNG-CL) <Kipp.Howard@lexisnexis.com>
Date: Wed, 19 Jun 2002 11:49:13 -0400 (EDT)
Message-ID: <5150922C4A9FFE4DA2F658016BF9FA3C08A560@lnxseamail01.lexisnexis.com>
To: html-tidy@w3.org




Tidy seems to be adding a return between empty elements.  Is there any way
to prevent this?

XML file I'm sending into tidy (b.xml):

<?xml version="1.0"?>
<root>
  <empty/>
  <empty></empty>
</root>

Using the following command line:
  tidy.exe -config tidy.ini b.xml

and the following tidy.ini:

output-xml: yes
input-xml: yes
indent: yes
indent-cdata: no
wrap: 0
escape-cdata: yes
markup: yes
clean: yes

I get the following output:

<?xml version="1.0"?>
<root>
<empty />


<empty>
</empty>

 </root>

Note the return that is put in the 2nd empty node.

I'm using tidy release: "(release date: 1st May 2002; built on May  7 2002,
at 20:00:42)"

I've tried a number of options but I cannot get tidy to produces something
more like this:

<?xml version="1.0"?>
<root>
<empty />
<empty />
 </root>

I really don't care about the empty space between nodes, but the return that
gets put in the 2nd empty node is causing me problems.  Is there anything I
can do to fix this problem?

Thanks.
-- 
Kipp E. Howard - Sr. Software Engineer @ LexisNexis CourtLink
kipp.howard@courtlink.com   
(425) 372-1837 or (800) 774-7317 ext 1837
Received on Wednesday, 26 June 2002 01:06:09 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Tuesday, 3 April 2012 06:13:52 GMT