Ticket #10296: files.diff

File files.diff, 791 bytes (added by Masklinn, 16 years ago)
  • django/db/models/fields/files.py

     
    1010from django.utils.functional import curry
    1111from django.db.models import signals
    1212from django.utils.encoding import force_unicode, smart_str
     13from django.utils.http import urlquote
    1314from django.utils.translation import ugettext_lazy, ugettext as _
    1415from django import forms
    1516from django.db.models.loading import cache
     
    5455
    5556    def _get_url(self):
    5657        self._require_file()
    57         return self.storage.url(self.name)
     58        return urlquote(self.storage.url(self.name), safe='/:')
    5859    url = property(_get_url)
    5960
    6061    def _get_size(self):
Back to Top