Commits

Anonymous committed 5ec386e

[1.2.X] Tweaked language markers in i18n topic document for better Sphinx syntax highlighting.

Comments (0)

Files changed (1)

docs/topics/i18n/internationalization.txt

 Working with lazy translation objects
 -------------------------------------
 
-.. highlightlang:: python
-
 Using ``ugettext_lazy()`` and ``ungettext_lazy()`` to mark strings in models
 and utility functions is a common operation. When you're working with these
 objects elsewhere in your code, you should ensure that you don't accidentally
 Specifying translation strings: In JavaScript code
 ==================================================
 
+.. highlightlang:: python
+
 Adding translations to JavaScript poses some problems:
 
     * JavaScript code doesn't have access to a ``gettext`` implementation.
 Using the JavaScript translation catalog
 ----------------------------------------
 
-To use the catalog, just pull in the dynamically generated script like this::
+.. highlightlang:: javascript
+
+To use the catalog, just pull in the dynamically generated script like this:
+
+.. code-block:: html+django
 
     <script type="text/javascript" src="{% url django.views.i18n.javascript_catalog %}"></script>
 
 The ``set_language`` redirect view
 ==================================
 
+.. highlightlang:: python
+
 .. function:: set_language(request)
 
 As a convenience, Django comes with a view, :meth:`django.views.i18n.set_language`,