Not allowing to upload profile photo
-
Hello. In my site I using plugin which I made by code which I finded in internet to replace file title to hash during upload. Code looks like this `function so_3261107_hash_filename( $filename ) {
$info = pathinfo( $filename );
$ext = empty( $info[‘extension’] ) ? ” : ‘.’ . $info[‘extension’];
$name = basename( $filename, $ext );return md5( $name ) . $ext;
}add_filter( ‘sanitize_file_name’, ‘so_3261107_hash_filename’, 10 );`
With page photos in page editor and favicon upload in theme settings it works fine, but it somehow blocking user profile photo upload, because if this plugin enabled I can select file, it allows me to crop, but when I press crop, then as it must apears message that photo successfuly uploaded but problem is that this photo not apears as profile photo. And if I try to upload with plugin dissabled it working as it must to. Can someone help me?
- You must be logged in to reply to this topic.