doudi1979 2011-03-24 09:21
浏览 63
已采纳

如何将div拆分到单独的窗口?

I have a web application with a split screen. On one side there is a specific functionality which is linked to the functionality on the right side of the screen.

I need to 'undock' the right side of the screen so the undocked div can be moved (even outside of the browser). This will be a functionality which users with dual screens will largely benefit from.

I managed to do this using a popup window. However, I am not liking the solution. The primary reason is that the popup window is not linked to the main application.

What I mean by not linked is that whenever I click on something from the left pane, its respective page must be popped out in this popup window. However, When I do this, the popup window is closing and opening another one (because of the same ID). This way, I cannot set a boolean variable to set it as false when the popup is closed, because it will be set to false whenever another popup is opened.

Is there a way of knowing when the popup's close button has been clicked from the parent window? That would solve me problems!

Is there a better solution of achieving this without using popup windows. I don't think its possible since when you use modals or functionalities of this sort, the modal will be a child of the parent container and therefore, is an instance in the same browser.

As a side note, this system is implementing with PHP/jQuery

Please let me know your ideas.

  • 写回答

1条回答 默认 最新

  • doufuxing8691 2011-03-24 12:10
    关注

    whenever I click on something from the left pane, its respective page must be popped out in this popup window

    It obviously depends on your technical solution. You can handle clicks in the main window and access the DOM in your "undocked" window, so you can get the DIV too and handle it just the way you handled the DIV when it was in your original document.

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论

报告相同问题?

悬赏问题

  • ¥15 用windows做服务的同志有吗
  • ¥60 求一个简单的网页(标签-安全|关键词-上传)
  • ¥35 lstm时间序列共享单车预测,loss值优化,参数优化算法
  • ¥15 Python中的request,如何使用ssr节点,通过代理requests网页。本人在泰国,需要用大陆ip才能玩网页游戏,合法合规。
  • ¥100 为什么这个恒流源电路不能恒流?
  • ¥15 有偿求跨组件数据流路径图
  • ¥15 写一个方法checkPerson,入参实体类Person,出参布尔值
  • ¥15 我想咨询一下路面纹理三维点云数据处理的一些问题,上传的坐标文件里是怎么对无序点进行编号的,以及xy坐标在处理的时候是进行整体模型分片处理的吗
  • ¥15 一直显示正在等待HID—ISP
  • ¥15 Python turtle 画图