php - Is it possible to read response headers server side? -
hey if have laravel 5 apps, & b
i want set header paramaters on , redirect b , read headers in app b.
redirect()->to($url)->headers('key', $key);
this sends headers in response , thats fine how read them server side?
thanks
this not seem possible flow is:
1) browser -[request]-> 2) browser <-[redirect]- 3) browser -[request]-> b 4) browser <-[content]- b
your response headers on step 2 not automatically sent server b in next request (that automatically executed browser due redirect).
a workaround comes mind add key $url parameter this:
$url = $url.'?key='.urlencode($key);
on application b can redirect remove 'key' parameter address bar, when set.
Comments
Post a Comment