Uploading a new profile picture programatically by Aya Ashraf - Sunday, 30 May 2021, 5:53 PM Number of replies: 1 Hey ,i'm using moodle 3.9 .i want to upload a new user profile picture using my code any ideas about how to reach that ? Average of ratings: - Permalink Reply In reply to Aya Ashraf Re: Uploading a new profile picture programatically by Howard Miller - Sunday, 30 May 2021, 11:28 PM From where? Is this a Moodle plugin you are writing or from code external to Moodle? If the latter, use the web service core_user_update_picture. Otherwise, I would look at how the code for that works, which you can find at https://github.com/moodle/moodle/blob/MOODLE_39_STABLE/lib/classes/user.php#L590 Average of ratings: - Permalink Show parent Reply
In reply to Aya Ashraf Re: Uploading a new profile picture programatically by Howard Miller - Sunday, 30 May 2021, 11:28 PM From where? Is this a Moodle plugin you are writing or from code external to Moodle? If the latter, use the web service core_user_update_picture. Otherwise, I would look at how the code for that works, which you can find at https://github.com/moodle/moodle/blob/MOODLE_39_STABLE/lib/classes/user.php#L590 Average of ratings: - Permalink Show parent Reply