Fancy Box - how to refresh parent page when close iframe popup?

前端 未结 12 914
逝去的感伤
逝去的感伤 2020-12-28 19:16

I want my parent page to refresh when I close a Fancy Box popup frame. I have a login page inside the popup, so I need the parent page to refresh to show the new login state

12条回答
  •  难免孤独
    2020-12-28 20:01

    You just need to write two lines to close the fancybox and after close to reload the parent page on which you have opened your fancybox.

    One thing to be notices is that if you will try it with window.opener it not going to work as fancybox is not treated as a child window of the parent when it comes to window.opener

    One more thing is that window.opener is not going to work for windows phone and also with IE, as IE is already stupid.

    
    

提交回复
热议问题