Thank you for you reply. Now I have slove the problem. But the
solution is very strange.
In fact, there is a clean function in my update form, as following:
def clean_user_avatar(self):
if not self.cleaned_data["user_avatar"]:
raise forms.ValidationError("Image Path is in n
2009/4/1 TTear1943 <1943@gmail.com>
>
> I seems it doesnot work when update an ImageField.
>
Certainly ImageFields can be updated.
You've omitted from the code you posted what exactly is done by the function
user.handle_upload_user_avatar(), which is my first guess as to where the
problem is
I seems it doesnot work when update an ImageField.
On 4月1日, 下午5时37分, TTear1943 <1943@gmail.com> wrote:
> Hi, I encounter a problem.
> In my user models there is an atrrbution: user.avatar = ImageField
> ('avatar', upload_to=AVATAR_TEMP_DIR, blank=True, null=True)
> then i use a modelform as a
Hi, I encounter a problem.
In my user models there is an atrrbution: user.avatar = ImageField
('avatar', upload_to=AVATAR_TEMP_DIR, blank=True, null=True)
then i use a modelform as an create user form. And the avatar is
uploaded corrcet. Which upload to AVATAR_TEMP_DIR, then I move the
avatar into
4 matches
Mail list logo