<w:r> <w:t><xsl:value-of select="normalize-space(firstname)" /> <xsl:value-of select="lastname" /></w:t> </w:r>This is good. It trims the spaces in first name. But, I need to insert a space between the first name and the last name. In this approach the space is not processed.