Django

Code

Changeset 3901

Show
Ignore:
Timestamp:
10/13/06 09:26:08 (2 years ago)
Author:
russellm
Message:

Fixes #2384,#2566 -- Clarify the role that TEMPLATE_STRING_IF_INVALID plays in the template system, and the problems that can occur if it is used on a production site.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • django/trunk/docs/templates_python.txt

    r3883 r3901  
    213213applied to invalid variables within these template tags. 
    214214 
     215.. admonition:: For debug purposes only! 
     216 
     217    While ``TEMPLATE_STRING_IF_INVALID`` can be a useful debugging tool,  
     218    it is a bad idea to turn it on as a 'development default'.  
     219     
     220    Many templates, including those in the Admin site, rely upon the  
     221    silence of the template system when a non-existent variable is  
     222    encountered. If you assign a value other than ``''`` to 
     223    ``TEMPLATE_STRING_IF_INVALID``, you will experience rendering  
     224    problems with these templates and sites. 
     225     
     226    Generally, ``TEMPLATE_STRING_IF_INVALID`` should only be enabled  
     227    in order to debug a specific template problem, then cleared  
     228    once debugging is complete. 
     229         
    215230Playing with Context objects 
    216231----------------------------