Warning: file_get_contents(/data/phpspider/zhask/data//catemap/3/html/86.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Html 谷歌+;follow按钮在firefox的引导模式中未正确显示_Html_Css_Twitter Bootstrap_Google Plus - Fatal编程技术网

Html 谷歌+;follow按钮在firefox的引导模式中未正确显示

Html 谷歌+;follow按钮在firefox的引导模式中未正确显示,html,css,twitter-bootstrap,google-plus,Html,Css,Twitter Bootstrap,Google Plus,我有一个引导模式里面,我有谷歌+跟随按钮,它是正确显示在谷歌浏览器,但不显示在firefox。我试着把正常的页面和它的工作良好,但我希望它在模态框 这是我的密码 <div class="modal fade" id="sharing_modal" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true"> <div class="modal-dialog"

我有一个引导模式里面,我有谷歌+跟随按钮,它是正确显示在谷歌浏览器,但不显示在firefox。我试着把正常的页面和它的工作良好,但我希望它在模态框

这是我的密码

    <div class="modal fade" id="sharing_modal" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">   
      <div class="modal-dialog">
        <div class="modal-content sharing-wrapper">

          <div class="modal-body sharing-body">
                <img src="/assets/google-round.png" width="80px;" class="img-centered">

            <script src="https://apis.google.com/js/platform.js" async defer></script>

            <div class="g-follow" data-annotation="vertical-bubble" data-height="24" data-href="https://plus.google.com/104729765568883320527" data-rel="publisher"></div>
          </div>

        </div>
      </div>
   </div>

问题在于引导模式的样式“display:none”。正因为如此,google+follow按钮在Firefox中无法计算正确的大小

作为一种解决方法,您可以将css样式覆盖为“display:block”,并在页面加载后将其设置回“display:none”

CSS示例:

#sharing_modal
{
    display: block;
}
示例JS(JQuery):

看这把小提琴:

$( document ).ready(function() {
    $('#sharing_modal').css('display', 'none');
});