xiaomlove / nexusphp

A private tracker application base on NexusPHP
https://nexusphp.org
GNU General Public License v2.0
856 stars 178 forks source link

.png in avatar upload = invalid extension error #122

Closed BeAristobule closed 1 year ago

BeAristobule commented 1 year ago

Hi,

In the bitbucket-upload.php I have this line : $imgtypes = array (null,'gif','jpg','jpeg','png');

But when I try to upload a .png picture, this error is showed: Invalid extension: gif, jpg or png only!

Thanks.

xiaomlove commented 1 year ago

It's OK, you can check on demo site.

BeAristobule commented 1 year ago

I had to remove the . jpeg extension here :

$imgtypes = array (null,'gif','jpg','jpeg','png'); is now: $imgtypes = array (null,'gif','jpg','png');

Now the .png extension is accepted. Do you know why?

xiaomlove commented 1 year ago

please upload the same png image on demo site, is the problem exists?

BeAristobule commented 1 year ago

On demo site it works, but you probably don’t have the . jpeg extension in the bitbucket-upload.php code because it’s not normally there.