title: Running python in template
body: <p>I have an <code>Applicant</code> model containing <code>title</code>, <code>first_name</code> and <code>surname</code> and I am passing a list of them to a template here:</p>
  
  <pre><code> {% for applicant in applicants %}
     &lt;tr&gt;
       &lt;td&gt;{{ applicant.id }}&lt;/td&gt;
       &lt;td&gt;{{ applicant.title.replace('^','') }} {{ applicant.first_name }} {{ ed {% 
     &lt;/tr&gt;
   {% endfor %}
  </code></pre>
  
  <p>The problem is that the titles contain dodgy characters (<code>^</code>) that I need to replace in python</p>
  
  <pre><code>applicant.title.replace('^','')
  </code></pre>
  
  <p>But this causes the template to break</p>
  
  <pre><code>Could not parse the remainder: '('^','')' from 'applicant.title.replace('^','')'
  </code></pre>
  
  <p>How can I run python on a template variable without causing this error?</p>