Forum Moderators: coopster
echo '<script type="text/javascript">document.location = "http://www.example.com";</script>';
Should work, however, I would change the header location if you can. This isn't the best way to redirect a page.
Just note that you may run into issues with those that have javascript disabled.