views:

279

answers:

1

I'm using xalan with the following xsl header:

<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
    version="1.0"
    xmlns:redirect="http://xml.apache.org/xalan/redirect"
    extension-element-prefixes="redirect"
    xmlns:xalan="http://xml.apache.org/xalan"&gt;
<xsl:output method="text" indent="yes" xalan:indent-amount="4"/>

And the output is not indented.

Anyone with ideas?

A: 

I guess you have to set the method to xml. If that does not work, try the following:

<?xml version="1.0" encoding="UTF-8"?>

<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:xalan="http://xml.apache.org/xalan"&gt;

<xsl:output method="xml" encoding="UTF-8" indent="yes" xalan:indent-amount="4"/>
thelost
unfortunately it doesn't work :(
Vincent
Is is possible that you are viewing the xml with an application that does not render properly the content ?
thelost
I'm outputting the transformation on the console
Vincent
I guest this is a bug.
Vincent