If I use node.removeChild(Node) to modify XML and then write it to disk using javax.xml.transform.Transformer, I end up with blank lines where the nodes were deleted. Is there any way to keep the blank lines from bring printed?
For example, the XML may look like this:
If I use the apache classes XMLSerializer and OutputFormat, the blank lines aren't printed. But I'd like to find a way to use the JDK classes (javax.xml.transform.Transformer, etc.)
I'm writing the XML as follows:
If somebody says you look familiar, tell them you are in porn. Or in these tiny ads:
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koop