title: accessing project url in django template
body: <blockquote>
    <p><strong>Possible Duplicate:</strong><br>
    <a href="https://stackoverflow.com/questions/433162/can-i-access-constants-in-settings-py-from-templates-in-django">Can I access constants in settings.py from templates in Django?</a>  </p>
  </blockquote>
  
  
  
  <p>I am trying to create a template , which contains some hyperlinks and  redirect url. I have seperate production and staging server .  I have already tried <code>request.get_full_path</code> on template but it is  rendering query string rather than domain name. Any idea?</p>
  
  <p>in settings.py i did following </p>
  
  <pre><code>TEMPLATE_CONTEXT_PROCESSORS = (
       "django.core.context_processors.request",
       "django.contrib.auth.context_processors.auth"
  
       )
  </code></pre>
  
  <p>My template is as follows</p>
  
  <pre><code>&lt;form action="https://www.sandbox.paypal.com/cgi-bin/webscr" method="post"&gt;
      &lt;input type="hidden" name="cmd" value="_xclick"&gt;
      &lt;input type="hidden" name="business" value="sumit_1349250468_per@ersumit.com"&gt;
      &lt;input type="hidden" name="item_name" value="registration charge {{ request.session.username }}"&gt;
      &lt;input type="hidden" name="item_number" value="{{ request.session.userid }}"&gt;
      &lt;input type="hidden" name="amount" value="9.00"&gt;
      &lt;input type="hidden" name="no_shipping" value="0"&gt;
      &lt;input type="hidden" name="no_note" value="1"&gt;
      &lt;input type="hidden" name="currency_code" value="USD"&gt;
      &lt;input type="hidden" name="lc" value="AU"&gt;
      &lt;input type="hidden" name="bn" value="PP-BuyNowBF"&gt;
      &lt;input type="image" src="https://www.paypal.com/en_AU/i/btn/btn_buynow_LG.gif" border="0" name="submit" alt="PayPal - The safer, easier way to pay online."&gt;
      &lt;img alt="" border="0" src="https://www.paypal.com/en_AU/i/scr/pixel.gif" width="1" height="1"&gt;
      &lt;input type="hidden" name="return" value="{{ request.get_full_path}}accounts/success"&gt;
      &lt;input type="hidden" name="cancel_return" value="{{ request.get_full_path}}/accounts/sorry"&gt;
  
  &lt;/form&gt;
  </code></pre>
  
  <p><strong>I don't want to create any custom views</strong> </p>