djangosnippets.org: Latest snippets tagged with 'urlize'http://djangosnippets.org/tags/urlize/2011-08-24T14:54:31.949032-05:00ultralize
2011-08-24T14:54:31.949032-05:00catellarhttp://djangosnippets.org/snippets/2525/<p>This is a function based on django's urlize modified to show different media based on their url. It supports images, links, mp3/ogg links, youtube videos, vimeo videos and dailymotion videos.</p>
<p>I added a switch called mini to have two modes to show things in different places. When mini is activated …</p>
Freely redistributableurlize HTML
2010-06-18T18:51:01.277575-05:00maguspkhttp://djangosnippets.org/snippets/2072/<p>The default Django urlize filter does not work with html nicely so here I've used an HTML parser <a href="http://www.crummy.com/software/BeautifulSoup/">BeautifulSoup</a> to quickly search through each text node and run the django urlize filter on it. </p>
<p>Optimizations could be made to include a regex in the soup.findAll() method's text argument to only …</p>
Freely redistributableyoutubize template tag
2007-05-03T06:55:36.049612-05:00TheJesterhttp://djangosnippets.org/snippets/212/<p>This snippet is based on djangos urlize filter. It converts http:// links to youtube into youtube-embed statements, so that one can provide a simple link to a youtube video and this filter will embed it. I used it for a fun blog app.</p>
Freely redistributable