<?
if($result_code == '0000') {
    echo '0000|||||';
    if(count($list) > 0) {
        $i=1;
        $tag_count = count($list);
        foreach ($list as $val) {

            $head_title = '';
            if($val['head_title'] != '')    $head_title = '<span class="beachblue">['.$val['head_title'].']</span> ';
            $title = $head_title.$val['title'];

            $title_txt = mb_strimwidth($title, '0', '80', '..', 'utf-8');


            if($i%3==1) echo '<div class="channel_boxs">';
?>

            <div class="channel_con">
                <div class="art-img" onclick="location.href='/web/life/life_view/<?=$val['idx']?>'" style="cursor:pointer;width:304.58px;height:197.19px;background:url('<?=$val['main_img']?>') no-repeat center; background-size:cover;"></div>
                <p class="chtitle" style="height:57px"><a href="/web/life/life_view/<?=$val['idx']?>"><?=$title_txt?></a><span class="c_name"><a href="/web/life/editor/<?=$val['partner_idx']?>"><?=$val['editor_name']?></a></span><span class="checkno fr">조회 <?=number_format($val['hit_count'])?> </span></p>
            </div>

 <?

            if($i%3==0 || $tag_count==$i)    echo '</div>';

            $i++;
        }

    }

    echo '|||||'.$total_count.'|||||'.$more_list;

} else {
    echo $result_code.'|||||글가져오기에 실패했습니다.';

}
?>