title: Wrong encoding in Spring portlet via ajax(Liferay)
body: <p>Have a simple Spring MVC portlet, and from one of portal pages I have to load content using AJAX.</p>
  
  <pre><code>  $.ajax({
          type:"POST",
          url:ajaxlink,
          data:"lastnumber=" + lastnumber,
          cache:false,
          success:function (htmlanswer) {
  
              $("#cityspeakcontent").append(htmlanswer);
  
  
          }
      });
  </code></pre>
  
  <p>The result of request is in wrong encoding: "Ð–ÐÐ’ÐžÐ ÐžÐÐžÐš, Ð¶Ð°Ð²Ñ€Ð¾Ð½Ð¾Ðº Ð¼. Ð¿Ð¾Ð"(must be utf-8)</p>
  
  <p>At jsp page i have</p>
  
  <pre><code>&lt;%@ page contentType="text/html; charset=utf-8" pageEncoding="UTF-8" %&gt;
  </code></pre>
  
  <p>Also tried to add filter:</p>
  
  <pre><code>    &lt;filter&gt;
      &lt;filter-name&gt;encodingFilter&lt;/filter-name&gt;
      &lt;filter-class&gt;org.springframework.web.filter.CharacterEncodingFilter&lt;/filter-class&gt;
      &lt;init-param&gt;
          &lt;param-name&gt;encoding&lt;/param-name&gt;
          &lt;param-value&gt;UTF-8&lt;/param-value&gt;
      &lt;/init-param&gt;
      &lt;init-param&gt;
          &lt;param-name&gt;forceEncoding&lt;/param-name&gt;
          &lt;param-value&gt;true&lt;/param-value&gt;
      &lt;/init-param&gt;
  &lt;/filter&gt;
  
  &lt;filter-mapping&gt;
      &lt;filter-name&gt;encodingFilter&lt;/filter-name&gt;
      &lt;url-pattern&gt;/*&lt;/url-pattern&gt;
  &lt;/filter-mapping&gt;
  </code></pre>
  
  <p>There is no result.</p>
  
  <p>And when in ajax request I add </p>
  
  <pre><code>contentType: "charset=utf-8"
  </code></pre>
  
  <p>there is an Exception generating by Liferay with very large stacktrace=) (As I understand Exception in doFilter method of com.liferay.portal.kernel.servlet.BaseFilter)</p>
  
  <p>WTF i'm doing wrong?</p>