fo bo 머지작업 - 오류수정

This commit is contained in:
jazz
2025-12-01 12:04:52 +09:00
parent 99eb2d1e58
commit 23028a50fe
7 changed files with 170 additions and 152 deletions

View File

@@ -39,7 +39,7 @@
</c:when>
<c:otherwise>
<div class="sub-wrapper">
<jsp:include page="/WEB-INF/views/html/pc/DT/brandStory.jsp"/>
<jsp:include page="/WEB-INF/views/html/pc/DT/brandStory.jsp"/>
</div>
</c:otherwise>
</c:choose>
@@ -51,57 +51,57 @@
<script>
$(document).ready(function (){
$("#myiframe").on('load', function() {
var iframe = $(this);
const sopmalCd = '<c:out value="${sopmalCd}"/>';
let height = '';
//아이프레임 높이값 고정
if(sopmalCd === 'JM' || sopmalCd === 'AF' || sopmalCd === 'DT'){
height = '3293';
}else if ( sopmalCd === 'BD') {
height = '3000';
}else if (sopmalCd === 'DL' ){
height = '1200';
}else if (sopmalCd === 'NB'){
url = document.getElementById("myiframe").contentWindow.location.href;
if(url.indexOf('selectNbPromiseHtml') > 0){
height = '1800';
}else if (url.indexOf('selectNbIngredientHtml') > 0){
height = '1600';
}else {
height = '4600';
}
}else if (sopmalCd === 'PL'){
height = '1800';
}else if (sopmalCd === 'TZ'){
height = '2600';
const dv = '<c:out value="${dv}"/>';
if(dv === 'production'){
height = '2200';
}else if (dv === 'way'){
height = '1800';
}
}else if (sopmalCd === 'CH'){
const dv = $("#myiframe").attr("chDv");
if(dv ==='company'){
$("#myiframe").css('height', '2000px');
} else if (dv === 'ceo') {
$("#myiframe").css('height', '800px');
} else if (dv === 'technology') {
$("#myiframe").css('height', '21285px');
} else if (dv === 'history') {
$("#myiframe").css('height', '2180px');
} else if (dv === 'map') {
$("#myiframe").css('height', '1000px');
} else if (dv === 'way') {
$("#myiframe").css('height', '1300px');
} else if (dv === 'script') {
$("#myiframe").css('height', '4300px');
}
}
if(!fn_is_empty(height)){
iframe.css('height', height+ 'px');
}
});
var iframe = $(this);
const sopmalCd = '<c:out value="${sopmalCd}"/>';
let height = '';
//아이프레임 높이값 고정
if(sopmalCd === 'JM' || sopmalCd === 'AF' || sopmalCd === 'DT'){
height = '3293';
}else if ( sopmalCd === 'BD') {
height = '3000';
}else if (sopmalCd === 'DL' ){
height = '1200';
}else if (sopmalCd === 'NB'){
url = document.getElementById("myiframe").contentWindow.location.href;
if(url.indexOf('selectNbPromiseHtml') > 0){
height = '1800';
}else if (url.indexOf('selectNbIngredientHtml') > 0){
height = '1600';
}else {
height = '4600';
}
}else if (sopmalCd === 'PL'){
height = '1800';
}else if (sopmalCd === 'TZ'){
height = '2600';
const dv = '<c:out value="${dv}"/>';
if(dv === 'production'){
height = '2200';
}else if (dv === 'way'){
height = '1800';
}
}else if (sopmalCd === 'CH'){
const dv = $("#myiframe").attr("chDv");
if(dv ==='company'){
$("#myiframe").css('height', '2000px');
} else if (dv === 'ceo') {
$("#myiframe").css('height', '800px');
} else if (dv === 'technology') {
$("#myiframe").css('height', '21285px');
} else if (dv === 'history') {
$("#myiframe").css('height', '2180px');
} else if (dv === 'map') {
$("#myiframe").css('height', '1000px');
} else if (dv === 'way') {
$("#myiframe").css('height', '1300px');
} else if (dv === 'script') {
$("#myiframe").css('height', '4300px');
}
}
if(!fn_is_empty(height)){
iframe.css('height', height+ 'px');
}
});
// iframe 메시지 수신 핸들러(iframe 높이 맞추기)
window.addEventListener('message', (event) => {