Changes between Initial Version and Version 1 of Ticket #14497, comment 12


Ignore:
Timestamp:
Feb 4, 2015, 7:07:28 AM (10 years ago)
Author:
Tim Graham

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #14497, comment 12

    initial v1  
    11Let me suggest a small adding. Usually is not necessary to show the complete path, but just the file name. This is trivial by "import os.path" and applying "os.path.basename" as below:
    2 
     2{{{
    33            return mark_safe(u'<a href="%s">%s</a>'
    44                % (escape(value.url),
    55                    os.path.basename(force_unicode(value))))
     6}}}
Back to Top