The PHP refresh after 5 seconds didn't work for me when opening a Save As dialogue to save a file: (header('Content-type: text/plain'); header("Content-Disposition: attachment; filename=$filename>");)
After the Save As link was clicked, and file was saved, the timed refresh stopped on the calling page.
However, thank you very much, ibu's javascript solution just kept on ticking and refreshing my webpage, which is what I needed for my specific application. So thank you ibu for posting javascript solution to php problem here.
You can use javascript to redirect after some time
setTimeout(function () {
window.location.href = 'http://www.google.com';
},5000); // 5 seconds