<?php
$columns = $bloc['column'];
if(count($columns)==3){
    $col_class = 'col-lg-4';
}else{
    $col_class = 'col-lg-6';
}
?>

<div  class="container py-2 py-md-5 columns_content">
    <div class="row">
        <?php
        foreach ($columns as $column){
        ?>
        <div class="col-12 <?php echo $col_class;?> post_content">
            <h2><?php echo $column['title'];?></h2>
            <?php echo $column['txt'];?>
        </div>
        <?php } ?>
    </div>
</div>
