mirror of
				https://github.com/django/django.git
				synced 2025-11-04 13:39:16 +00:00 
			
		
		
		
	Fixed #13961 - note that reverse URL lookups can't be done within a blocktrans tag. Thanks garrison for the report and richardb and zerok for work on the patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@15100 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
		
							parent
							
								
									ca292f125b
								
							
						
					
					
						commit
						aa1b537b11
					
				
					 1 changed files with 8 additions and 0 deletions
				
			
		| 
						 | 
				
			
			@ -500,6 +500,14 @@ apply.
 | 
			
		|||
.. note:: The previous more verbose format is still supported:
 | 
			
		||||
   ``{% blocktrans with book|title as book_t and author|title as author_t %}``
 | 
			
		||||
 | 
			
		||||
Reverse URL lookups cannot be carried out within the ``blocktrans`` and should
 | 
			
		||||
be retrieved (and stored) beforehand::
 | 
			
		||||
 | 
			
		||||
    {% url path.to.view arg arg2 as the_url %}
 | 
			
		||||
    {% blocktrans %}
 | 
			
		||||
    This is a URL: {{ the_url }}
 | 
			
		||||
    {% endblocktrans %}
 | 
			
		||||
 | 
			
		||||
.. _template-translation-vars:
 | 
			
		||||
 | 
			
		||||
Other tags
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue