Browse files

Fixed #11364 -- Modified the jsi18n example to use the {% url %} tag …

…rather than a placeholder. Thanks to jcassee for the suggestion.

git-svn-id: bcc190cf-cafb-0310-a4f2-bffc1f526a37
  • Loading branch information...
1 parent 75514ab commit 3c6036a5b4a5c8ef921b71c1752abcda9728afb5 @freakboy3742 freakboy3742 committed Jul 15, 2009
Showing with 4 additions and 4 deletions.
  1. +4 −4 docs/topics/i18n.txt
@@ -959,11 +959,11 @@ Using the JavaScript translation catalog
To use the catalog, just pull in the dynamically generated script like this::
- <script type="text/javascript" src="/path/to/jsi18n/"></script>
+ <script type="text/javascript" src="{% url django.views.i18n.javascript_catalog %}"></script>
-This is how the admin fetches the translation catalog from the server. When the
-catalog is loaded, your JavaScript code can use the standard ``gettext``
-interface to access it::
+This uses reverse URL lookup to find the URL of the JavaScript catalog view.
+When the catalog is loaded, your JavaScript code can use the standard
+``gettext`` interface to access it::
document.write(gettext('this is to be translated'));

0 comments on commit 3c6036a

Please sign in to comment.