Skip to:
Content
Pages
Categories
Search
Top
Bottom

Re: How to get ‘edit profile’, ‘change avatar’, ‘notification settings’ etc on the same page?


Boone Gorges
Keymaster

@boonebgorges

The markup for the edit profile page is in the theme directory, members/single/profile/edit.php. The change avatar page is right next to it, members/single/profile/change-avatar.php. The markup for the settings screens is created in bp_core_screen_general_settings(), located in buddypress/bp-core/bp-core-settings.php. It’s possible in theory to move all of this markup to the same file – say, edit.php.

Then you’ll have to combine the form data handlers, which might be more tricky. When you save your settings panels, they are run through bp_core_screen_general_settings; you can find the code you need there. When you save the Edit Profile screen, it gets run through xprofile_screen_edit_profile() in buddypress/bp-xprofile.php. And the first stop for the Change Avatar page is xprofile_screen_change_avatar(), also in bp-xprofile.php. You’d have to merge all of these handlers somehow in order to get them to process data from the same HTML form.

Good luck.

Skip to toolbar