게시판 첨부파일 최신글 썸네일로 가져올 때 ㅜㅜ
게시판 첨부파일 최신글 썸네일로 뽑아오면 자꾸 이미지 원본 양옆에 여백이 생깁니다..
add_stylesheet('<link rel="stylesheet" href="'.$latest_skin_url.'/style.css">', 0);
$thumb_width = 683;
$thumb_height = 503;
$list_count = (is_array($list) && $list) ? count($list) : 0;
?>
설정해주었는데 썸네일 부모 크기만 해당 크기로 되고 빨간색으로 색칠한 여백 부분이 왜 생길까요 ㅠㅠ 이거 어디서 수정하나요 제발 도와주세요 ㅠㅠ
add_stylesheet('<link rel="stylesheet" href="'.$latest_skin_url.'/style.css">', 0);
$thumb_width = 683;
$thumb_height = 503;
$list_count = (is_array($list) && $list) ? count($list) : 0;
?>
설정해주었는데 썸네일 부모 크기만 해당 크기로 되고 빨간색으로 색칠한 여백 부분이 왜 생길까요 ㅠㅠ 이거 어디서 수정하나요 제발 도와주세요 ㅠㅠ
|
답변 1개
https://ysmoto.kr/ys2/bbs/board.php?bo_table=basict3000&sfl=wr_subject%7C%7Cwr_content%7C%7Cwr_10%7C%7Cwr_3&stx=%EA%B8%80%EC%93%B0%EA%B8%B0&sop=and&device=pc
https://sir.kr/google-search?q=%EC%97%AC%EB%B0%B1+%EC%97%86%EC%9D%B4#gsc.tab=0&gsc.q=%EC%97%AC%EB%B0%B1%20%EC%97%86%EC%9D%B4&gsc.page=1
/* 썸네일 이미지 */
.latest_skin_img_tag { /* 스킨의 이미지 클래스명 변경 */
width: 100% !important;
height: 100% !important;
object-fit: cover; /* 여백 없이 채움 */
}
$thumb = get_list_thumbnail($bo_table, $list[$i]['wr_id'], $thumb_width, $thumb_height, true, true);
<img src="<?php echo $img; ?>" style="width:150px; height:150px; object-fit:cover;">
https://sir.kr/google-search?q=%EC%97%AC%EB%B0%B1+%EC%97%86%EC%9D%B4#gsc.tab=0&gsc.q=%EC%97%AC%EB%B0%B1%20%EC%97%86%EC%9D%B4&gsc.page=1
/* 썸네일 이미지 */
.latest_skin_img_tag { /* 스킨의 이미지 클래스명 변경 */
width: 100% !important;
height: 100% !important;
object-fit: cover; /* 여백 없이 채움 */
}
$thumb = get_list_thumbnail($bo_table, $list[$i]['wr_id'], $thumb_width, $thumb_height, true, true);
<img src="<?php echo $img; ?>" style="width:150px; height:150px; object-fit:cover;">
답변을 작성하려면 로그인이 필요합니다.