var ResizeIframe = {    
  wrapperId : "tinc_content",
                
  resize : function ( oDoc, sId ) 
  {
    if ( window.addEventListener )
      {
        var iframeDoc = oDoc.getElementById( sId ).contentDocument;
        var pv = iframeDoc.defaultView.getComputedStyle( iframeDoc.body, "" ).getPropertyValue;
        var height = iframeDoc.body.clientHeight
        + parseInt( iframeDoc.defaultView.getComputedStyle( iframeDoc.body, "" ).getPropertyValue( "margin-top" ) )
        + parseInt( iframeDoc.defaultView.getComputedStyle( iframeDoc.body, "" ).getPropertyValue( "margin-bottom" ) )
        + parseInt( iframeDoc.defaultView.getComputedStyle( iframeDoc.body, "" ).getPropertyValue( "padding-top" ) )
        + parseInt( iframeDoc.defaultView.getComputedStyle( iframeDoc.body, "" ).getPropertyValue( "padding-bottom" ) );
      } else if ( window.attachEvent ) {
      var iframeDoc = oDoc.frames[ sId ].document;
      var wrapper = iframeDoc.getElementById( this.wrapperId );
      wrapper.style.height = "0px"; 
      var bodystyle = iframeDoc.body.style;
      var height = wrapper.offsetHeight + wrapper.offsetTop + 1;
    }
    oDoc.getElementById( sId ).setAttribute("height", height);    
  }
};
