I am trying to fix on some content that is generated by a remote server I have no control over.
Here are the contents:
<span>
<span>Text 1</span> additional text1 <---- notice there is one additional space after text1
<span>Text 2</span>
<span>Text 3</span>
<span>Text 4</span>
</span>
The problem here is I want to show:
Text 1 additional text1Text 2
instead of:
Text 1 additional text1 Text2
For some reason, the remote server generates one additional whitespace character. Is there a way to remove that space?