Custom profile properties
-
Hello,
Currently I try to style page Profile > Edit (located in theme/members/single/profile/edit.php). But I faced with problem, all layout is hidden in plugin and cannot be really customized.
But I managed to find this topic with following code
<?php if ( 'textbox' == bp_get_the_profile_field_type() ) : ?> <?php if ( 'Name' == bp_get_the_profile_field_name() ) : ?> <!-- Don't allow users to edit their names. --> <label for="<?php bp_the_profile_field_input_name(); ?>"><?php bp_the_profile_field_name(); ?> <?php if ( bp_get_the_profile_field_is_required() ) : ?><?php _e( '(required)', 'buddypress' ); ?><?php endif; ?></label> <!-- Dummy input, disabled in CSS, because otherwise saving anything causes the user's full name to be overwritten with the username. --> <input type="text" name="<?php bp_the_profile_field_input_name(); ?>" id="<?php bp_the_profile_field_input_name(); ?>" value="<?php bp_the_profile_field_edit_value(); ?>" <?php if ( bp_get_the_profile_field_is_required() ) : ?>aria-required="true"<?php endif; ?> style="display: none;"/> <!-- The thing that actually displays. --> <p id="name"><?php bp_the_profile_field_edit_value();?></p> <?php else : ?> <label for="<?php bp_the_profile_field_input_name(); ?>"><?php bp_the_profile_field_name(); ?> <?php if ( bp_get_the_profile_field_is_required() ) : ?><?php _e( '(required)', 'buddypress' ); ?><?php endif; ?></label> <input type="text" name="<?php bp_the_profile_field_input_name(); ?>" id="<?php bp_the_profile_field_input_name(); ?>" value="<?php bp_the_profile_field_edit_value(); ?>" <?php if ( bp_get_the_profile_field_is_required() ) : ?>aria-required="true"<?php endif; ?>/> <?php endif; ?> <?php endif; ?>
This code gives ability to style as you wish which is perfect for me, but I faced with problem – for some reason dropdowns in <select> tag do not shown. Can someone tell me at least right path how to fix it? I’ve tried to pull what I could, but with no luck so far.
Thanks
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
- You must be logged in to reply to this topic.