title: symfony2 twig - raw & slice filter together doesn't work
body: <p>In my twig template I have the following code:</p>
  
  <pre><code>&lt;td&gt;{{ object.content|length &gt; 50 ? object.content|raw|slice(0, 50) ~ '...' : object.content|raw  }}&lt;/td&gt;
  </code></pre>
  
  <p>My object <code>object.content</code> is a string like this:</p>
  
  <pre><code>&lt;p&gt;Nullam quis risus eget urna mollis ornare vel eu leo. Donec ullamcorper nulla non metus auctor fringilla.&lt;/p&gt;
  </code></pre>
  
  <p>I would like to output the string without the <code>&lt;p&gt;, &lt;b&gt;, ..</code> tags. That's why I add the <code>|raw</code> filter. I also only want to output <strong>50 characters of the whole string</strong>. </p>
  
  <p>The slicing of 50 characters works but he still shows the <code>&lt;p&gt;, ..</code> tags.</p>
  
  <p>Now when I do this:</p>
  
  <pre><code>&lt;td&gt;{{ object.content|raw  }}&lt;/td&gt;
  </code></pre>
  
  <p>He shows the string without the <code>&lt;p&gt;</code> tags. But when I add the slice filter it doesn't work ... I also tried to set a variable before the output like this:</p>
  
  <pre><code>{% set rawcontent = object.content %}
  &lt;td&gt;{{ rawcontent|slice(0, 50) ~ '...'  }}&lt;/td&gt;
  </code></pre>
  
  <p>But same result... How can I fix this?</p>