What are some alternative methods to using headers for page redirection in PHP, and how do they compare in terms of performance and reliability?

When redirecting a user to another page in PHP, the most common method is to use the header() function with the Location header. However, there are alternative methods such as using JavaScript or HTML meta tags for redirection. These alternatives can be useful in situations where using headers is not possible or preferred, but they may have implications on performance and reliability.

// Using JavaScript for redirection
echo '<script>window.location.replace("http://www.example.com");</script>';

// Using HTML meta tag for redirection
echo '<meta http-equiv="refresh" content="0;url=http://www.example.com">';