Getting a White Space after XML Transformation

Many of you might have come across a situation where you transformed an XML file using XSL and finally when you get the output, you find there are some white spaces appearing in certain places. It might be quite frustrating at times especially when you feel that you have done everything possible to make it work correctly.

There is a reason why this is happening. We know that we have to create templates in order for the XML to get transformed. But there are some tags in XML which do not have templates. There could be many, some of them are- <Rows>, <dsQueryResponse>. So for the ones which do not have a template, XSL generates a white space for that particular line of code. Sound’s weird Right?? But that is unfortunately how it works.

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s