Where is the Â (C2) coming from
<p>For some reason a piece of code replaces spaces with <code>\u00A0</code> - i.e. a <a href="https://en.wikipedia.org/wiki/Non-breaking_space" rel="noreferrer">Non-breaking space</a>. This code is then used to <em>sanitize</em> a URL (yes I know that is very bad - in many ways). Strangely, when these are displayed in my test jsp a rogue <code>Â</code> appears - why?</p>

<p>Sample JSP to demonstrate the issue.</p>

<pre><code>&lt;%@page contentType="text/html" pageEncoding="UTF-8"%&gt;
&lt;!DOCTYPE html&gt;
&lt;html&gt;
  &lt;head&gt;
    &lt;meta http-equiv="Content-Type" content="text/html; charset=UTF-8"&gt;
    &lt;title&gt;JSP Page&lt;/title&gt;
    &lt;%
      String[] parameters = request.getParameterValues("p");
      if (parameters == null || parameters.length == 0) {
        parameters = new String[]{""};
      }
    %&gt;
  &lt;/head&gt;
  &lt;body&gt;
    &lt;h1&gt;Hello World!&lt;/h1&gt;
    &lt;a href='index.jsp?p=&lt;%="Hello\u00A0there"%&gt;'&gt;A Link&lt;/a&gt;
    &lt;p&gt;&lt;%=parameters[0]%&gt;&lt;/p&gt;
  &lt;/body&gt;
&lt;/html&gt;
</code></pre>

<p>Why is the parameter showing as <code>HelloÂ there</code>? Where is the <code>c2</code> coming from?</p>

<p><strong>Added</strong></p>

<p>BTW: The hex of the <code>parameter</code> is <code>48 65 6c 6c 6f c2 a0 74 68 65 72 65</code> showing the <code>c2</code> in-situ.</p>