title: Symfony2 hook after template render
body: <p>I've got a small question here: is there a way to do some actions after a template has been rendered ? A sort of Listener or hook which is called after a specific template has been rendered ?</p>
  
  <p>In my case I want to know the last datetime the user visited the homepage. If I persist this value in the Controller, so before the rendering of the corresponding template, I won't be able to use my app.user.getLastHomepageVisit datetime variable in the twig template, as the value of the latter variable would be 'now' which is not what I want. I want to update and persist this value to 'now' <em>after</em> the page has been rendered.</p>
  
  <p>Thanks!</p>