It may be needed that you need to give a close link in the popup you created. The window.close () method could be used to close a window.