Skip to:
Content
Pages
Categories
Search
Top
Bottom

change bp_xprofile_fields table based on condition


  • itsabhist
    Participant

    @itsabhist

    i want to change bp_xprofile_fields name & discriptio based on condition selected by user .
    for that i want create muliple bp_xprofile_fields table with _suffix

    and when user select option based on that bp_xprofile_fields_suffix shoud activate

    please guid how to achive

    class BP_XProfile_Component extends BP_Component {
    public function setup_globals( $args = array() ) 
    
    		$global_tables = array(
    			'table_name_data'   => $bp->table_prefix . 'bp_xprofile_data',
    			'table_name_groups' => $bp->table_prefix . 'bp_xprofile_groups',
    			'table_name_fields' => $bp->table_prefix . 'bp_xprofile_fields',
    			'table_name_meta'   => $bp->table_prefix . 'bp_xprofile_meta',
    		);

    to

    $global_tables = array(
    			'table_name_data'   => $bp->table_prefix . 'bp_xprofile_data',
    			'table_name_groups' => $bp->table_prefix . 'bp_xprofile_groups',
    			'table_name_fields' => $bp->table_prefix . 'bp_xprofile_fields<strong>_hi</strong>',
    			'table_name_meta'   => $bp->table_prefix . 'bp_xprofile_meta',
    		);
  • You must be logged in to reply to this topic.
Skip to toolbar