묻고답하기
page_full_width" class="col-xs-12" |cond="$__Context->page_full_width">
이 소스를 사용할려면 어떻게 해야할까요..?
2004.07.03 09:24
function is_str(str){
if ( typeof str == "undefined") return false;
return str.length > 0;
}
var frmMinWidth;
var frmMinHeight;
var minSizeVal = false;
var frmMaxWidth;
var frmMaxHeight;
var maxSizeVal = false;
function setMinFrameSize(width, height)
{
frmMinWidth = width;
frmMinHeight = height
minSizeVal = true;
}
function setMaxFrameSize(width, height)
{
frmMaxWidth = width;
frmMaxHeight = height
maxSizeVal = true;
}
function setScrollTop(){
if (document.location.search.indexOf("26") != -1) document.body.scrollTop = 0;
return false;
}
function resizeIframe(name){
if (!is_str(name)) name = "mainiframe";
try
{
var oBody = document.frames(name).document.body;
var oFrame= document.all(name);
var frmWidth = oBody.scrollWidth;
var frmHeight = oBody.scrollHeight;
if (minSizeVal)
{
frmWidth = Math.max(frmWidth, frmMinWidth);
frmHeight = Math.max(frmHeight, frmMinHeight);
}
if (maxSizeVal)
{
frmWidth = Math.min(frmWidth, frmMaxWidth);
frmHeight = Math.min(frmHeight, frmMaxHeight);
}
setScrollTop();
oFrame.style.height = frmHeight + 10;
oFrame.style.width = frmWidth;
}
catch(e){
}
}
위가 소스입니다.......... 정확히 어떻게 사용할 방법을 모르겠네요...
iframe의 스크롤바를 전체로 리사이즈...(?)하는 기능인데요..
사용하는 방법을 모르겠어요~~알려주세요.
if ( typeof str == "undefined") return false;
return str.length > 0;
}
var frmMinWidth;
var frmMinHeight;
var minSizeVal = false;
var frmMaxWidth;
var frmMaxHeight;
var maxSizeVal = false;
function setMinFrameSize(width, height)
{
frmMinWidth = width;
frmMinHeight = height
minSizeVal = true;
}
function setMaxFrameSize(width, height)
{
frmMaxWidth = width;
frmMaxHeight = height
maxSizeVal = true;
}
function setScrollTop(){
if (document.location.search.indexOf("26") != -1) document.body.scrollTop = 0;
return false;
}
function resizeIframe(name){
if (!is_str(name)) name = "mainiframe";
try
{
var oBody = document.frames(name).document.body;
var oFrame= document.all(name);
var frmWidth = oBody.scrollWidth;
var frmHeight = oBody.scrollHeight;
if (minSizeVal)
{
frmWidth = Math.max(frmWidth, frmMinWidth);
frmHeight = Math.max(frmHeight, frmMinHeight);
}
if (maxSizeVal)
{
frmWidth = Math.min(frmWidth, frmMaxWidth);
frmHeight = Math.min(frmHeight, frmMaxHeight);
}
setScrollTop();
oFrame.style.height = frmHeight + 10;
oFrame.style.width = frmWidth;
}
catch(e){
}
}
위가 소스입니다.......... 정확히 어떻게 사용할 방법을 모르겠네요...
iframe의 스크롤바를 전체로 리사이즈...(?)하는 기능인데요..
사용하는 방법을 모르겠어요~~알려주세요.