1
我有一個父頁面和子頁面共享file.js文件爲jquery事件。通過按鈕關閉一個彈出式iframe類型的模式窗口
嗯,我正在與Magnific Popup
工作,我有:
$("#addDetailButton").magnificPopup({
items: {
src: 'someURL'
},
type: 'iframe',
enableEscapeKey: false,
modal: true
});
我的彈出是基於iframe
是modal
。如何使用button
html元素關閉模式窗口?我對StackOverflow和所有回覆進行了研究,並且基於inline
類型。
我已經試過
<input id="cancel" type="button" value="Cancel"/> // child page
$("#cancel").click(function(){
$.magnificPopup.close();
});
,我總是收到以下槽Firefox的Web控制檯:
TypeError: $.magnificPopup is undefined
謝謝
非常感謝你。 – 2014-09-25 23:01:04