did you tried so:

import sys
reload(sys)
sys.setdefaultencoding('utf-8')

or something similar?

On Sun, Jun 13, 2010 at 1:25 AM, MichaleHjulskov <needb...@gmail.com> wrote:

> Hi Bjørn
>
> I have allready # -*- encoding: utf-8 -*-# in top of my settings.py
> and models.py
>
> Should I put it in all my .py files?
>
> Thanks :o)
>
>
> On 12 Jun., 17:06, Bjørn Høj Jakobsen <bhjakob...@gmail.com> wrote:
> > Hi
> >
> > Try and put "# -*- encoding: utf-8 -*-#" in the top of the py script.
> >
> > These danish characters really are a pain the ass.
> >
> > Regards
> >
> > Bjørn
> >
> > On 12 Jun., 14:37, MIL <needb...@gmail.com> wrote:
> >
> > > I experience problem with special chars like æøå in filename when
> > > using models.ImageField.
> >
> > > What am I doing wrong?
> >
> > > models.py
> > >    picture = models.ImageField(upload_to='pics', blank=True,
> > > verbose_name='Picture of you')
> >
> > > Using model forms
> >
> > > Let say I want to upload picture named "æøå.jpg"
> >
> > > If I do that, I get the following error msg:
> > > 'ascii' codec can't encode characters in position 59-61: ordinal not
> > > in range(128)
> >
> > > Django ver 1.2 Alpha
> >
> > > Please help me thanks
> >
> >
>
> --
> You received this message because you are subscribed to the Google Groups
> "Django users" group.
> To post to this group, send email to django-us...@googlegroups.com.
> To unsubscribe from this group, send email to
> django-users+unsubscr...@googlegroups.com<django-users%2bunsubscr...@googlegroups.com>
> .
> For more options, visit this group at
> http://groups.google.com/group/django-users?hl=en.
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.

Reply via email to