Cannot upload or change profile pictures

Cannot upload or change profile pictures

by Dave Ang -
Number of replies: 4

Anyone can help me. My user can't change their profile picture.  They got this error 


Forbidden

You don't have permission to access /moodle/user/edit.php on this server.

Additionally, a 403 Forbidden error was encountered while trying to use an ErrorDocument to handle the request.

 

How can I solve this?  Thanks in advance

Average of ratings: -
In reply to Dave Ang

Re: Cannot upload or change profile pictures

by Suraj Kumar -

Dear Dave,

I guess that authenticated user already has this capability  - 'moodle/user:editownprofile' set to allow and users are getting 'Edit profile' link in the administration block.  (if this permission is not set to allow, please set this capability to allow for authenticated users)

I suggest to check your htaccess file and apache for RewriteRule (if any) for this concern.

Do you have written any htaccess RewriteRule in .htaccess file to restrict access of this file (user/edit.php) from browser?

Do you have wriiten any RewriteRule on web server to restrict this page from browser?

For example -

This is pure mod_rewrite based solution either in apache/.htaccess:

RewriteRule ^(submit\.php) - [F,L,NC]

This will show forbidden error to use if URI contains submit.php

Please check if you have any RewriteRule(s).




In reply to Suraj Kumar

Re: Cannot upload or change profile pictures

by Dave Ang -
Thanks Sujar,  


Sorry where can i check the  htaccess file and apache for RewriteRule?

In reply to Dave Ang

Re: Cannot upload or change profile pictures

by Suraj Kumar -

The rules of .htaccess files are followed by files and child directories of parent recursively where it is kept until new htaccess rules is overridden in child directory. It is hidden file so list it with a proper command (ls -la in linux).

Possibly .htaccess file might be avalable in

  1. root directory of moodle
  2. user directory of moodle
  3. public_html (document root) directory of web server

You may find .htaccess file in root directory of moodle or under user directory of moodle (moodle/user).


Regarding, apache files, access rules might have been written in 

  1. apache config file (httpd.conf under <Directory > or <Files > diective
  2. any included virtual conf file

You may contact your server admin.

Can you please share your screen shots of error message and url having administration block of moodle?

Thanks.

Suraj

In reply to Suraj Kumar

Re: Cannot upload or change profile pictures

by Saayeel Kalekar -

Hi there, I just created a new user field in my form named UID and marked it required.
Now if i click anywhere on site administration it redirects me to this link
edit.php?id=2&course=1  and asks me to update UID
and when i try to do it it says

Forbidden

You don't have permission to access /user/edit.php on this server.

Additionally, a 403 Forbidden error was encountered while trying to use an ErrorDocument to handle the request.
Please help me out.