function setIframeHeight(iframeName) {   
var iframeEl = parent.document.getElementById? parent.document.getElementById(iframeName): parent.document.all? parent.document.all[iframeName]: null;

 if (iframeEl) {
 iframeEl.style.height = "auto";
// need to add to height to be sure it will all show
 alertSize(iframeName);

 }
}

function alertSize(frameId) { 
var myHeight = 0;
frame =  document.getElementById(frameId);
if( typeof( window.innerWidth ) == 'number' ) {
//Non-IE
var getFFVersion=navigator.userAgent.substring(navigator.userAgent.indexOf("Firefox")).split("/")[1];
var FFextraHeight=parseFloat(getFFVersion)>=0.1? 16 : 0;
myHeight=frame.contentDocument.documentElement.scrollHeight+FFextraHeight+20;
myWidth =frame.contentDocument.documentElement.scrollWidth+FFextraHeight;

} else if( document.documentElement && ( document.documentElement.clientWidth || document.documentElement.clientHeight ) ) {
//IE 6+ in 'standards compliant mode'

innerDoc = (frame.contentDocument) ? frame.contentDocument : frame.contentWindow.document; ;
myHeight= innerDoc.body.scrollHeight +20;
myWidth = document.body.scrollWidth;
//myHeight = document.documentElement.clientHeight;
} else if( document.body && ( document.body.clientWidth || document.body.clientHeight ) ) {
//IE 4 compatible
myHeight = document.body.clientHeight;
myHeight = document.body.clientWidth;
 }
//window.alert( 'Height = ' + myHeight );
//return myHeight;
frame.style.height =myHeight + "px";
frame.style.width =myWidth + "px";
}
