【问题标题】:Scrollbars & resizable are not appearing in onclick="window.open"滚动条和可调整大小未出现在 onclick="window.open" 中
【发布时间】:2016-04-18 15:27:44
【问题描述】:

由于某种原因,我正在尝试使用 onclick="window.open" 打开一个新窗口,滚动条和可调整大小在 IE11 中不起作用,它在 Chrome 中可以正常工作,但可以正常工作。

<div class="editor-field editorholder" style="height: auto;">
<a href="@Url.Action("QuickView", "Home", new { id = @Model.UniqueKey })" class="btn-mvc" onclick="window.open(this.href,'targetWindow','toolbar=0','location=0','status=0','menubar=0,','scrollbars=yes','resizable=yes','width=100','height=100'); return false;">
  <span class="glyphicon glyphicon-folder-open" aria-hidden="true"></span>
 </a>
</div>

【问题讨论】:

  • 我尝试使用 'scrollbars=1','resizable=1' 但没有任何变化..请帮助...谢谢
  • 'location=0','status=0','menubar=0,','scrollbars=yes','resizable=yes','width=100','height=100' 应该是一个字符串,类似于'location=0,status=0,menubar=0,scrollbars=yes,resizable=yes,width=100,height=100'
  • 很遗憾没有工作。

标签: javascript asp.net-mvc


【解决方案1】:

同时添加:

scrolling=yes, scrollbars=yes 

【讨论】:

    【解决方案2】:

    终于找到了解决办法:

    onclick="window.open(this.href, 'popupwindow', 'width=1280  height=800 resizable scrollbars menubar=yes'); return false;"
    

    谢谢

    【讨论】:

      猜你喜欢
      • 2019-04-07
      • 1970-01-01
      • 2020-07-09
      • 1970-01-01
      • 2014-05-05
      • 1970-01-01
      • 2019-08-13
      • 2012-05-20
      • 2018-05-11
      相关资源
      最近更新 更多