[buddypress-trac] [BuddyPress Trac] #5896: xprofile field visibility label doesn't change until after saving changes

buddypress-trac noreply at wordpress.org
Mon Sep 22 20:10:02 UTC 2014


#5896: xprofile field visibility label doesn't change until after saving changes
--------------------------+------------------------------
 Reporter:  jreeve        |       Owner:
     Type:  defect (bug)  |      Status:  new
 Priority:  normal        |   Milestone:  Awaiting Review
Component:  Core          |     Version:
 Severity:  normal        |  Resolution:
 Keywords:                |
--------------------------+------------------------------

Comment (by jreeve):

 You can fix this with the following jQuery code:

 {{{
 function update_visibility_fields() {
         /* jQuery hack to make visibility label change
          * when the user changes it */

         $('.field-visibility-settings
 input[type=radio]').click(function(){
                 $(this).parents('.field-visibility-settings').siblings
 ('.field-visibility-settings-toggle').children('.current-visibility-
 level').html($(this).parent().find('span').text());
         });
 }
 }}}

 I'll submit a patch for this if I can get it to enqueue properly and load
 when profiles are being viewed.

 Also, I'm no expert at jQuery, so if anyone has suggestions for improving
 this code, please let me know.

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


More information about the buddypress-trac mailing list