Inpsyde\MultilingualPress\API\WPDBSiteRelations::get_all_relations PHP 메소드

get_all_relations() 공개 메소드

Returns an array with site IDs as keys and arrays with the IDs of all related sites as values.
부터: 3.0.0
public get_all_relations ( ) : int[]
리턴 int[] The array with site IDs as keys and arrays with the IDs of all related sites as values.
    public function get_all_relations()
    {
        $query = "SELECT site_1, site_2 FROM {$this->table} ORDER BY site_1 ASC, site_2 ASC";
        $rows = $this->db->get_results($query, ARRAY_A);
        return $rows ? $this->get_site_relations_from_query_results($rows) : [];
    }