fixing XML printing