fewbricks\bricks\demo_flexible_columns::get_brick_html PHP Method

get_brick_html() protected method

protected get_brick_html ( ) : string
return string
    protected function get_brick_html()
    {
        $nr_of_columns = $this->get_field('nr_of_columns');
        $column_classes = $this->get_column_classes($nr_of_columns);
        $html = '
        <div class="row">
        ';
        for ($column_nr = 1; $column_nr <= $nr_of_columns; $column_nr++) {
            $html .= '<div class="' . $column_classes . '">';
            $html .= $this->get_child_brick('demo_flexible_brick', 'fb' . $column_nr)->get_html();
            $html .= '</div>';
        }
        $html .= '
        </div>
        ';
        return $html;
    }