채택완료

모바일 최신글 질문좀 드리겠습니다

2017-05-12 (금) 10:18:20 5,458

모바일 이미지 최신글인데요 ㅠㅠ 

메인에서 새로고침 하면 보였다가 또 어쩔땐 안보였다 그러는데 왜그런걸까요 

[code]

<?php

if (!defined('_GNUBOARD_')) exit; // 개별 페이지 접근 불가

include_once(G5_LIB_PATH.'/thumbnail.lib.php');

include_once(G5_THEME_LIB_PATH.'/thumbnail2.lib.php');

// add_stylesheet('css 구문', 출력순서); 숫자가 작을 수록 먼저 출력됨

add_stylesheet('<link rel="stylesheet" href="'.$latest_skin_url.'/style.css">', 0);

$thumb_width  = isset($options['thumb_width']) ? $options['thumb_width'] : $board['bo_gallery_width'];

$thumb_height = isset($options['thumb_height']) ? $options['thumb_height'] : $board['bo_gallery_height'];

$content_length = isset($options['content_length']) ? $options['content_length'] : 30;

?>

<!-- <?php echo $bo_subject; ?> 최신글 시작 { -->

<div class="lt_gal">

     <div class="lt_gal_Box">

        <ul>

            <?php

            for ($i=0; $i<count($list); $i++) {

                $thumb = get_list_thumbnail($bo_table, $list[$i]['wr_id'], $thumb_width, $thumb_height);

                if($thumb['src']) {

                    $img_content = '<img src="'.$thumb['src'].'" alt="'.$thumb['alt'].'" width="'.$thumb_width.'" height="'.$thumb_height.'">';

                } else {

                    $noimg = $latest_skin_path.'/img/no_img.gif';

                     $img_content = '<span>'.get_noimage_thumbnail($bo_table, $noimg, $thumb_width, $thumb_height, $class='no_img').'</span>';

                }

            ?>

                <li>

                    <a href="<?php echo $list[$i]['href']; ?>" class="lt_image"><?php echo $img_content; ?></a>

                    <?php

                    echo "<a href=\"".$list[$i]['href']."\" class=\"lt_tit\">";

                    if ($list[$i]['is_notice'])

                        echo "<strong>".$list[$i]['subject']."</strong>";

                    else

                        echo $list[$i]['subject'];

                    echo "</a>";

                     ?>

                     <p class="lt_detail"><?php echo get_text(cut_str(strip_tags($list[$i]['wr_content']), $content_length), 1); ?></p>

                     <span></span>

                </li>

            <?php }  ?>

        </ul>

    </div>

 </div>

[code]

|

답변 1개

채택된 답변
+20 포인트

<p class="lt_detail"><?php echo get_text(cut_str(strip_tags($list[$i]['wr_content']), $content_length), 1); ?></p>

                     <span></span>
이것때문에 문제가 발생하는지 코드를 삭제해보시고 테스트해보세요 

답변을 작성하려면 로그인이 필요합니다.