I use httpful to send http request and get the response to display in request.php
include('httpful.phar');
$response = \Httpful\Request::get('http://domain/response.php')->send();
echo '<textarea rows="20" cols="100">';
echo $response;
echo '</textarea>';
In response.php, I use header to redirect the request to another page, but I cannot get the expected response.
header("HTTP/1.1 301 Moved Permanently");
header("Location:http://otherdomain/other_response.php");
echo 'internal response page'
I have also tried
header("HTTP/1.1 302 Found");
but it still only get the response 'internal response page'
what is the correct way to redirect/forward the request to other_response.php?