在Iframe中使用Jquery Fancybox自动高度? [英] Using Jquery Fancybox auto height within an Iframe?

查看:392
本文介绍了在Iframe中使用Jquery Fancybox自动高度?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用Fancybox iframe表单。
表格高度350px
完成表格时结果只有两行。

I'm using Fancybox iframe form. form height 350px when finish form the result is just two lines.

任何人都可以告诉我如何为窗口制作自动高度

could any one tell me how to make auto height for the window

我的javascript代码是

my javascript code is

$(document).ready(function() {      
    $("#send_friend").fancybox({
        'width'             : 310,
        'height'            : 350,
        'autoScale'         : false,
        'transitionIn'      : 'none',
        'transitionOut'     : 'none',
        'type'              : 'iframe',
        'showCloseButton'       :false,
        'padding'           : 0,
        'margin'            : 0,
        'transitionIn'      : 'elastic',
        'transitionOut'     : 'elastic',    
        'overlayOpacity':'0.3', 
    });

});

提前致谢

推荐答案

尝试给iframe一个匹配的高度和宽度(见下文),但更重要的是给完成表单屏幕一个坚固的高度和宽度,如果需要,将它包装在DIV标签中。

Try giving the iframe a matching height and width (see below), but more importantly give the finish form screen a firm height and width as well, if needed by wrapping it in a DIV tag.

<iframe style="height: 350px; width 350px;" />
...
<div style="height: 350px; width 350px;">
<form>
Thank you for sending to a friend.
</form>
</div>

这篇关于在Iframe中使用Jquery Fancybox自动高度?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆