title: Get controller name in TWIG template
body: <p>I am learning symfony2.3, and I am getting an error when I try to get controller name in twig template.</p>
  
  <p>Controller:</p>
  
  <pre><code>namespace Acme\AdminBundle\Controller;
  
  use Symfony\Bundle\FrameworkBundle\Controller\Controller;
  use Symfony\Component\HttpFoundation\Request;
  
  class DefaultController extends Controller
  {
      public function indexAction($name)
      {
          return $this-&gt;render('AcmeAdminBundle:Default:index.html.twig', array('name' =&gt; $name));
      }
  }
  </code></pre>
  
  <p>In my TWIG template:</p>
  
  <pre><code>{% extends '::base.html.twig' %}
  {% block body %}
   {{ app.request.get('_template').get('controller') }}
   Hello {{ name }}!!!
  {% endblock %}
  </code></pre>
  
  <p>Output:</p>
  
  <pre><code>Impossible to invoke a method ("get") on a NULL variable ("") in AcmeAdminBundle:Default:index.html.twig at line 3 
  </code></pre>
  
  <p>I want output as "Default"</p>
  
  <p>I am using symfony 2.3, I have also tried on symfony 2.1 but on both version generates the same error.</p>