原理是这样的,当alert弹出框点击确定以后,再让页面重新加载一下就可以,具体代码如下:
添加个绝对居中样式{margin: auto;position: absolute;top: 0;left: 0;bottom: 0;right: 0;}