How to completely remove a dialog on close

前端 未结 7 2111
深忆病人
深忆病人 2020-12-02 05:56

When an ajax operation fails, I create a new div with the errors and then show it as a dialog. When the dialog is closed I would like to completely destroy and remove the di

相关标签:
7条回答
  • 2020-12-02 06:44
    $(dialogElement).empty();
    
    $(dialogElement).remove();
    

    this fixes it for real

    0 讨论(0)
提交回复
热议问题