Mercurial > public > sg101
changeset 352:a321685505cc
Fixing #163; make plain links linkable in Markdown. Use an extension found here: https://github.com/r0wb0t/markdown-urlize.
author | Brian Neal <bgneal@gmail.com> |
---|---|
date | Wed, 02 Mar 2011 03:16:19 +0000 (2011-03-02) |
parents | b783a555cd87 |
children | 6a686ffb6609 |
files | gpp/core/markup.py |
diffstat | 1 files changed, 2 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/gpp/core/markup.py Wed Mar 02 02:51:00 2011 +0000 +++ b/gpp/core/markup.py Wed Mar 02 03:16:19 2011 +0000 @@ -10,7 +10,7 @@ """ This is a thin wrapper around the Markdown class which deals with the differences in Markdown versions on the production and development server. - This code was inspired by the code in + This code was inspired by the code in django/contrib/markup/templatetags/markup.py. Currently, we only have to worry about Markdown 1.6b and 2.0. """ @@ -18,7 +18,7 @@ # Unicode support only in markdown v1.7 or above. Version_info # exists only in markdown v1.6.2rc-2 or above. self.unicode_support = getattr(_markdown, "version_info", None) >= (1, 7) - self.md = _markdown.Markdown(safe_mode=safe_mode) + self.md = _markdown.Markdown(safe_mode=safe_mode, extensions=['urlize']) def convert(self, s): if self.unicode_support: