Notifications
Clear all

wpForo 1.x.x [Closed] Way to Disable 'Website' and 'About Me' Column in Account?

2 Posts
2 Users
1 Reactions
2,524 Views
Posts: 18
Topic starter
(@kyotomizuko)
Eminent Member
Joined: 6 years ago

Anyway to remove or disable 'website' and 'about me' column in account?

1 Reply
Robert
Posts: 10591
Admin
(@robert)
Support Team
Joined: 9 years ago

Hi @kyotomizuko,

You can disable the Website and About Me fields using this script:

function my_custom_wpforo_account_fields( $fields ){
    $remove_fields = array('site', 'about');
    if( !empty($fields) ){
        foreach( $fields as $r => $rows ){
            foreach( $rows as $c => $cols ){
                foreach( $cols as $f => $field ){
                    if( $field && in_array($field, $remove_fields) ){
                        unset($fields[$r][$c][$f]);
                    }
                }
            }
        }
    }
    return $fields;
}
add_filter( 'wpforo_get_account_fields', 'my_custom_wpforo_account_fields');

Put this code in current active WordPress theme functions.php file.

How to Easily Add Custom Code in WordPress (without Breaking Your Site)