Changing photo within profile

Changing photo within profile

by Les Lusk -
Number of replies: 4

I am putting the finishing touches on my three Moodle courses for the new semester and decided that I needed to update my photo (I'm much better looking now than 3 weeks ago!).  For some reason, it wouldn't allow me to change the photo.  I am able to update any of the other material, but the photo stayed the same.  I finally just deleted my profile and recreated it with the new photo.  Any idea what's up?

BTW - after posting this topic, I decided to try and change my photo here on the Moodle site.  It also didn't work.   There was an error message that flashed by very quickly.  I think it had something to do with chmod.  When I went back to the profile area the old image was still there.  When I checked back a few moments later to try and recreate the error message - there was the new image!  (and no, I don't have the cache turned on my browser)

Average of ratings: -
In reply to Les Lusk

Re: Changing photo within profile

by Gustav W Delius -
This delay before the new picture is visible is by design. Have a look at cvs:/moodle/user/pix.php. It is there for efficiency but if it annoys you you could change the value of  $lifetime.
In reply to Gustav W Delius

Re: Changing photo within profile

by Les Lusk -
Could you please enlighten me as to why the delay is desired?  It seems to me that students (and myself for that matter) will be confused (and frustrated) as to why the upload isn't working.
In reply to Les Lusk

Re: Changing photo within profile

by Martin Dougiamas -
Picture of Core developers Picture of Documentation writers Picture of Moodle HQ Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers
It's not really an explicit delay as such. Basically Moodle tells the browser that user profile images are valid for 24 hours. This causes most browsers not to keep downloading the same image over and over - it just caches it locally and reuses the file it has.

This makes pages load fast and reduces load on the server and network.

When you change an image, the browser doesn't necessarily know about it - it's still using the old image which it believes is valid.

You can force the browser to reload everything fresh by holding down the shift key and then pressing the reload button. We could put some text to this effect in the interface to make it more explicit.  And as Gustav said, you can easily change the value to zero or something.
In reply to Martin Dougiamas

Re: Changing photo within profile

by Jason Hando -
Just a quick note to say a big thank you for your feedback, especially Martin's last explanation, on this matter.

We were having troubles with this issue and a quick search of the forums showed this discussion and now I am able to explain the problem to our 600 students using moodle!

Isn't moodle a fantastic community based solution approve