Support » Plugin: BuddyPress XProfile Custom Image Field » Update to properly show field name in tags on frontend and admin forms.

  • Resolved Evan

    (@skysarwer)


    Hey there,

    I installed your plugin and noticed that the title for image fields was not rendering properly on the frontend forms or the admin forms. A quick inspection showed that regular xprofile fields show the name in <legend> tags, rather than the <label> tags that the plugin puts them in.

    I fixed this by going to /classes/class-bp-xprofile-field-type-image.php in the plugin directory and changing line 95 to the following code:

    <legend id="<?php bp_the_profile_field_input_name(); ?>-1"><?php bp_the_profile_field_name(); ?> <?php if ( bp_get_the_profile_field_is_required() ) : ?><?php _e( '(required)', 'bp-xprofile-image-field' ); ?><?php endif; ?></legend>

    Do you think you can roll this into the next update, so I do not need to worry about manually re-updating?

    Thank you so much! Love the plugin.

    Best regards,
    Evan

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Author Alex Githatu

    (@kalengi)

    Hi Evan,

    Thank you for using my plugin.

    Were you able to capture any screenshots of the BEFORE and AFTER? These would be great for me to see the difference.

    I’ll definitely include this in the next update.

    Kind regards,

    Alex

    Thread Starter Evan

    (@skysarwer)

    Hey Alex,

    Sure. I have the before / after screenshots, jsut give me an email I can send them to.

    I also added the following code to line 117 to show the field description:

    echo '<p id="'.bp_get_the_profile_field_input_name().'-3" class="description">'.bp_get_the_profile_field_description().'</p>';

    Would be great to include that in future updates as well! Thank you!

    There are other small details default BP markup adds to xprofile fields, you might want to add, such as the “described-by” parameter in the legend, that you might be interested in studying – but they aren’t super relevant for my use case so I didn’t bother with them.

    • This reply was modified 6 months, 1 week ago by Evan.
    • This reply was modified 6 months, 1 week ago by Evan.
    Plugin Author Alex Githatu

    (@kalengi)

    Hi Evan,

    Great! Send the screenshots to mp90wa6j5koe@beconfidential.com. You can also share your email address there so I can reach you privately for any clarification.

    I’ll also look into the latest suggestions for inclusion in the next update.

    Kind regards,

    Alex

    Plugin Author Alex Githatu

    (@kalengi)

    Hi Evan,

    I have updated the plugin with the suggested code.

Viewing 4 replies - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.