썸네일생성 후 지정 이미지 사이즈 유지되지 않는 오류 수정
This commit is contained in:
@ -21,16 +21,20 @@
|
||||
var width = $this.width();
|
||||
|
||||
$img.each(function() {
|
||||
$(this).removeAttr("width")
|
||||
.removeAttr("height")
|
||||
.css("width","")
|
||||
.css("height", "");
|
||||
|
||||
if($(this).data("width") == undefined)
|
||||
$(this).data("width", $(this).width());
|
||||
|
||||
if($(this).data("width") > width) {
|
||||
$(this).css("width", "100%");
|
||||
$(this).removeAttr("width")
|
||||
.removeAttr("height")
|
||||
.css("width","")
|
||||
.css("height", "");
|
||||
|
||||
if($(this).data("width") > width) {
|
||||
$(this).css("width", "100%");
|
||||
}
|
||||
} else {
|
||||
$(this).attr("width", $(this).data("width"));
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user