Changeset 9625
- Timestamp:
- 03/17/2015 06:42:02 PM (10 years ago)
- Location:
- trunk/src
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/bp-groups/bp-groups-functions.php
r9490 r9625 818 818 } 819 819 820 $path = bp_core_avatar_upload_path() . '/group-avatars/' . $group_id; 821 $newbdir = $path; 822 823 if ( !file_exists( $path ) ) 824 @wp_mkdir_p( $path ); 825 826 $newurl = bp_core_avatar_url() . '/group-avatars/' . $group_id; 820 $directory = 'group-avatars'; 821 $path = bp_core_avatar_upload_path() . '/' . $directory . '/' . $group_id; 822 $newbdir = $path; 823 $newurl = bp_core_avatar_url() . '/' . $directory . '/' . $group_id; 827 824 $newburl = $newurl; 828 $newsubdir = '/ group-avatars/' . $group_id;825 $newsubdir = '/' . $directory . '/' . $group_id; 829 826 830 827 /** … … 835 832 * @param array $value Array of parts related to the groups avatar upload directory. 836 833 */ 837 return apply_filters( 'groups_avatar_upload_dir', array( 'path' => $path, 'url' => $newurl, 'subdir' => $newsubdir, 'basedir' => $newbdir, 'baseurl' => $newburl, 'error' => false ) ); 834 return apply_filters( 'groups_avatar_upload_dir', array( 835 'path' => $path, 836 'url' => $newurl, 837 'subdir' => $newsubdir, 838 'basedir' => $newbdir, 839 'baseurl' => $newburl, 840 'error' => false 841 ) ); 838 842 } 839 843 -
trunk/src/bp-members/bp-members-functions.php
r9611 r9625 2160 2160 } 2161 2161 2162 $path = bp_core_avatar_upload_path() . '/avatars/signups/' . $bp->signup->avatar_dir; 2163 $newbdir = $path; 2164 2165 if ( ! file_exists( $path ) ) { 2166 @wp_mkdir_p( $path ); 2167 } 2168 2169 $newurl = bp_core_avatar_url() . '/avatars/signups/' . $bp->signup->avatar_dir; 2170 $newburl = $newurl; 2171 $newsubdir = '/avatars/signups/' . $bp->signup->avatar_dir; 2162 $directory = 'avatars/signups'; 2163 $path = bp_core_avatar_upload_path() . '/' . $directory . '/' . $bp->signup->avatar_dir; 2164 $newbdir = $path; 2165 $newurl = bp_core_avatar_url() . '/' . $directory . '/' . $bp->signup->avatar_dir; 2166 $newburl = $newurl; 2167 $newsubdir = '/' . $directory . '/' . $bp->signup->avatar_dir; 2172 2168 2173 2169 /** … … 2184 2180 'basedir' => $newbdir, 2185 2181 'baseurl' => $newburl, 2186 'error' => false2182 'error' => false 2187 2183 ) ); 2188 2184 } -
trunk/src/bp-xprofile/bp-xprofile-functions.php
r9471 r9625 681 681 } 682 682 683 $path = bp_core_avatar_upload_path() . '/' . $directory. '/' . $user_id; 684 $newbdir = $path; 685 686 if ( ! file_exists( $path ) ) { 687 @wp_mkdir_p( $path ); 688 } 689 683 $path = bp_core_avatar_upload_path() . '/' . $directory. '/' . $user_id; 684 $newbdir = $path; 690 685 $newurl = bp_core_avatar_url() . '/' . $directory. '/' . $user_id; 691 686 $newburl = $newurl;
Note: See TracChangeset
for help on using the changeset viewer.