<?
if($result_code == '0000') {
    echo '0000|||||';
    $row_count = count($list);
    if($row_count > 0) {
        foreach ($list as $val) {
            switch ($val['content_type']) {
                case '1':	$view_url = '/web/news/news_view/'.$val['idx']; 	$share_id_name = "news_".$val['idx'];
                            break;
                case '2': 	$view_url = '/web/news/column_view/'.$val['idx']; 	$share_id_name = "column_".$val['idx'];
                            break;
                case '3': 	$view_url = '/web/life/life_view/'.$val['idx'];		$share_id_name = "life_".$val['idx'];
                            break;
            }

            $title = $val['title'];
            $bookmark_date	= $val['bookmark_date'];
            $bookmark_date_txt = substr($bookmark_date, 0, 10);
            $bookmark_date_txt = str_replace('-', '.', $bookmark_date_txt);

            $title_txt = mb_strimwidth($title, '0', '80', '..', 'utf-8');
            $content = strip_tags($val['content']);
            $content_txt = mb_strimwidth($content, '0', '200', '..', 'utf-8');

            $share_title 	= str_replace("'", "\\'", $title);
            $share_title  	= str_replace('"', '\\"', $share_title);
            $share_content  = mb_strimwidth($content, '0', '250', '..', 'utf-8');
            $share_content  = htmlspecialchars($share_content);
            $share_content  = str_replace("'", "\\'", $share_content);
            $share_content  = str_replace('”', '"', $share_content);

            $main_img = $val['main_img'];

    ?>
            <div class="mypage_list_cont">
                <input type="hidden" name="content_<?=$share_id_name?>" id="content_<?=$share_id_name?>" value="<?=$share_content?>">
                <input type="hidden" name="title_<?=$share_id_name?>" id="title_<?=$share_id_name?>" value="<?=$share_title?>">
                <input type="hidden" name="copy_url_<?=$share_id_name?>" id="copy_url_<?=$share_id_name?>" value="<?=WWW_CROSSMAP?><?=$view_url?>">
                <input type="hidden" name="img_url_l<?=$share_id_name?>" id="img_url_<?=$share_id_name?>" value="<?=WWW_CROSSMAP?><?=$main_img?>">
                <div class="btn-input bookmark_checkbox" style="display:none"><input type="checkbox" name="is_del[]" value="<?=$val['bookmark_idx']?>" onclick="bookmark_del_count();"></div>
                <div class="art-img" onclick="location.href='<?=$view_url?>'" style="cursor:pointer;width:89px;height:61px;background:url('<?=$val['main_img']?>') no-repeat center; background-size:cover;"></div>
                <div class="art-info">
                    <h2 class="art-title"><a href="<?=$view_url?>"><?=$title_txt?></a><span class="beachblue"><span class="company"><span class="beachblue"><?=$val['content_name']?></span></span></span></h2>
                    <p class="art-link"><a href="<?=$view_url?>"><?=WWW_CROSSMAP?><?=$view_url?></a></p>
                    <p class="art-sum"><span id="content_<?=$val['bookmark_idx']?>" style="display:none"><a href="<?=$view_url?>"><?=$content_txt?></a></span></p>
                </div>
                <div class="art-menu fr">
                    <div style="padding-bottom:5px; float:right">
                        <span><a href="javascript:;"  class="btn btn-default br5" onclick="share_box(this);" id="share_box_btn<?=$val['bookmark_idx']?>" style="border-radius:5px 0 0 5px !important;float:left;padding: 5px 6px 5px 9px;" strA="<?=$share_id_name?>"><img src="/img/web/img_upload.gif"></a></span>
                        <span><a href="javascript:bookmark_del('<?=$val['bookmark_idx']?>')" class="btn btn-default br5" style="border-radius:0 5px 5px 0 !important; border-left:0 !important;padding: 5px 6px"><img src="/img/web/img_x.gif"></a></span>
                    </div>
                    <div class="date" style="padding:15px 0 10px;text-align:right; padding-right:5px; font-size:12px"><?=$bookmark_date_txt?></div>
                    <div class="bttn2"><span><a href="javascript:content_more('<?=$val['bookmark_idx']?>')" class="btn btn-default br5 fr arrow_down" id="arrow_img_<?=$val['bookmark_idx']?>">자세히</a></span></div>
                </div>
            </div>
<?	    }
    }

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

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

}
?>