[buddypress-trac] [BuddyPress Trac] #6425: Avatar screen: Remove "Camera" tab if webcam not supported

buddypress-trac noreply at wordpress.org
Fri May 8 01:31:16 UTC 2015


#6425: Avatar screen: Remove "Camera" tab if webcam not supported
-----------------------------------+------------------
 Reporter:  r-a-y                  |       Owner:
     Type:  enhancement            |      Status:  new
 Priority:  normal                 |   Milestone:  2.3
Component:  API                    |     Version:
 Severity:  normal                 |  Resolution:
 Keywords:  has-patch ux-feedback  |
-----------------------------------+------------------
Changes (by r-a-y):

 * keywords:  has-patch ux-feedback 2nd-opinion => has-patch ux-feedback


Comment:

 > I think this is not a good idea

 Yeah, after thinking things through.  I agree.

 These are all the possible webcam scenarios:

 1. A user has Firefox / Chrome and has a webcam
 2. A user has Firefox / Chrome, but does not have a webcam
 3. A user has IE and has a webcam
 4. A user has IE and does not have a webcam

 modemlooper was discussing point 3; I was mostly talking about 2.

 For 2, instead of `01.patch`, we just need to improve the labels.

 For example, Twitter has a "`Take Photo`" option and when you click on it
 and if you do not have a webcam or if you do not give permission, this is
 the message that pops up:

 `Uh oh...it looks like you don't have a webcam or we were unable to get
 permission to use your webcam. Please close this window and upload a photo
 instead.`

 I'd also propose to change our tab names to from "`Upload`" and "`Camera`"
 to "`Upload Photo`" and "`Take Photo`".

 For 3 and 4, let's do what you recommend by not loading the webcam JS when
 IE is detected.

 For Twitter, the "`Take Photo`" option does not show up in IE.  So for BP,
 I'd be okay with not loading the webcam JS if IE is detected.  The only
 thing to worry about is when Microsoft Edge is released.

 With that said, `02.patch` changes the various labels and messages to make
 things a little clearer and also bails out of `bp_avatar_use_webcam()` if
 IE is detected via WP's `$is_IE` as you stated, imath.

 Let me know what you think.

 ----

 > If we are to do this (which is from my point of view a bad idea), this
 should be fixed on the server part to avoid the script to be loaded like
 i'm doing with `wp_is_mobile()` (see the `bp_avatar_use_webcam()`
 function).

 I was able to use the webcam for Firefox on Android even with
 `wp_is_mobile()`, but that's probably because I was using a user-agent
 plugin :)

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


More information about the buddypress-trac mailing list