title: symfony extract data from entity
body: <p>Hello i have a problem i would like to retrieve data from my entity in Symfony here is the code:</p>
  
  <pre><code>  public function indexAction(Request $request , $id)
      {
  
          $getDoctrine = $this-&gt;getDoctrine()-&gt;getManager();
  
          $email = $getDoctrine-&gt;getRepository('desplayBundle:people')-&gt;find($id);
          dump($email);
  
          return $this-&gt;render('emailBundle:Default:index.html.twig', array());
      }
  </code></pre>
  
  <p>I would like to retrieve the data inside my controller and not in twig.</p>