답변 1개
main.10.skin.php 파일 기준으로 설명드립니다.
1. 이미지 흑백으로 바꾸는 스타일 추가
<style type="text/css">
.sct_img_gray img{
filter: url("data:image/svg+xml;utf8,<svg xmlns=\'http://www.w3.org/2000/svg\">http://www.w3.org/2000/svg\'><filter id=\'grayscale\'><feColorMatrix type=\'matrix\' values=\'0.3333 0.3333 0.3333 0 0 0.3333 0.3333 0.3333 0 0 0.3333 0.3333 0.3333 0 0 0 0 0 1 0\'/></filter></svg>#grayscale"); /* Firefox 10+, Firefox on Android */
filter: gray; /* IE6-9 */
-webkit-filter: grayscale(100%); /* Chrome 19+, Safari 6+, Safari 6+ iOS */
}
</style>
2. main.10.skin.php 파일
echo "<li class=\"sct_li {$sct_last}\" style=\"width:{$this->img_width}px\">\n";
if ($this->href) {
if($row['it_soldout'] == '1' && $row['it_tel_inq'] !== '1') { //품절이면
$add_class = " sct_img_gray"; //클래스 추가
} else {
$add_class = "";
}
echo "<div class=\"sct_img{$add_class}\"><a href=\"{$this->href}{$row['it_id']}\" class=\"sct_a\">\n";
}
3. 솔드아웃은 2번 방법 참고해서 div absolute로 이미지나 글자 띄우면 됩니다.
답변에 대한 댓글 2개
댓글을 작성하려면 로그인이 필요합니다.
답변을 작성하려면 로그인이 필요합니다.
로그인