Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

Added some documentation for truncatewords_html (added in [4468]).

git-svn-id: http://code.djangoproject.com/svn/django/trunk@4474 bcc190cf-cafb-0310-a4f2-bffc1f526a37
  • Loading branch information...
commit 1aa1c4672cf7213f1073a5ab5f7c1ac8bc78d19f 1 parent 766e339
Malcolm Tredinnick authored February 10, 2007

Showing 1 changed file with 10 additions and 0 deletions. Show diff stats Hide diff stats

  1. 10  docs/templates.txt
10  docs/templates.txt
@@ -1133,6 +1133,16 @@ Truncates a string after a certain number of words.
1133 1133
 
1134 1134
 **Argument:** Number of words to truncate after
1135 1135
 
  1136
+truncatewords_html
  1137
+~~~~~~~~~~~~~~~~~~
  1138
+
  1139
+Similar to ``truncatewords``, except that it is aware of HTML tags. Any tags
  1140
+that are opened in the string and not closed before the truncation point, are
  1141
+closed immediately after the truncation.
  1142
+
  1143
+This is less efficient than ``truncatewords``, so should only be used when it
  1144
+is being passed HTML text.
  1145
+
1136 1146
 unordered_list
1137 1147
 ~~~~~~~~~~~~~~
1138 1148
 

0 notes on commit 1aa1c46

Please sign in to comment.
Something went wrong with that request. Please try again.