EXCEPTION: Unexpected token W in JSON at position 0
<p>I am trying to send the sentence "<code>How is weather in Tallinn?</code>"  with http get method to the back end.
It is important to send complete sentence with the spaces and the <code>?</code> sign.</p>

<p>Here is the code:</p>

<pre><code>import { Injectable } from '@angular/core';
import {Http} from '@angular/http';
import "rxjs/Rx";

@Injectable()
export class HttpService {

  constructor(private http:Http) { }
  getAnswer(par:string){
    const query=par;
    console.log("value is:"+par);
   return  this.http.get('http://localhost:8080/?question='+query).map((res)=&gt;res.json());
  }
}
</code></pre>

<p>but I think in line <code>res.json()</code> it complains with the error:</p>

<pre><code>Unexpected token W in JSON at position 0
</code></pre>

<p>The response is string <code>Weather in Tallinn? Tempeture:-2 and in gneral:Rainy</code>
So i think, it starts with <code>Weather</code> and then it cannot handle it.</p>

<p>So how can i fix it?</p>