[buddypress-trac] [BuddyPress Trac] #6570: Add UI for adding Profile Header Images for Users and Groups

buddypress-trac noreply at wordpress.org
Sat Oct 3 22:42:03 UTC 2015


#6570: Add UI for adding Profile Header Images for Users and Groups
-------------------------------------------+------------------
 Reporter:  mercime                        |       Owner:
     Type:  enhancement                    |      Status:  new
 Priority:  normal                         |   Milestone:  2.4
Component:  API                            |     Version:
 Severity:  normal                         |  Resolution:
 Keywords:  dev-feedback has-patch commit  |
-------------------------------------------+------------------

Comment (by imath):

 In [changeset:"10178"]:
 {{{
 #!CommitTicketReference repository="" revision="10178"
 Make sure uploaded images are oriented the right way.

 When using a mobile device to set an avatar or a cover image, there are
 cases when the image can be saved upside down. We need to check the exif
 Orientation of uploaded images and rotate them if needed.

 Introduce 2 new methods into the `BP_Attachment` class:
 - `BP_Attachment->get_image_data()` to get an array of all image datas
 (including exif datas)
 - `BP_Attachment->edit_image()` to edit the image orientation and/or
 resize the image.

 Use these two new methods within the `BP_Attachment_Avatar->shrink()` and
 `BP_Attachment_Cover_Image()->fit()` methods.

 Finally include a unit test for the `BP_Attachment->get_image_data()`
 method to check we get the orientation meta for all supported WorPress
 versions.

 Props modemlooper, shanebp, r-a-y, DJPaul

 Fixes #5089
 See #6570
 }}}

--
Ticket URL: <https://buddypress.trac.wordpress.org/ticket/6570#comment:65>
BuddyPress Trac <http://buddypress.org/>
BuddyPress Trac


More information about the buddypress-trac mailing list