title: Should I use the same variable name for my Twig template as the one I have in my controller?
body: <p>I'm going through Symfony2 start guide and my question is:</p>
  
  <p>I have a database with columns: price,description,id,name
  Then in my controller I fetch these columns and display them via a twig template.
  Within my controller I do:</p>
  
  <pre><code>public function showAction($id)
      {
          $product = $this-&gt;getDoctrine()
              -&gt;getRepository('AcmeStoreBundle:Product')
              -&gt;find($id);
  
          if (!$product) {
              throw $this-&gt;createNotFoundException(
                  'No product found for id '.$id
              );
          }
  
          $price = $product -&gt; getPrice();
          $description = $product -&gt; getDescription();
          return $this-&gt;render(
          'AcmeStoreBundle:Store:index.html.twig',
          array('id' =&gt; $id, 'price' =&gt; $price, 'description' =&gt; $description)
          );
      }
  </code></pre>
  
  <p>My question is, can I change $price,$description to call it whatever else...? or am I forced to keep mentioning these variables like they're named within the database?</p>
  
  <p>basically, can I do:</p>
  
  <pre><code>$foo = $product -&gt; getPrice();
  $bar = $product -&gt; getDescription();
  </code></pre>
  
  <p>And then in my render function do:</p>
  
  <pre><code>   return $this-&gt;render(
          'AcmeStoreBundle:Store:index.html.twig',
          array('uniquecode' =&gt; $id, 'cost' =&gt; $foo, 'message' =&gt; $bar)
          );
  </code></pre>
  
  <p>My question is two fold : 1) can I do it 2) is it a good practice to do it?</p>