"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "system/src/Grav/Common/GPM/Response.php" between
grav-v1.6.25.zip and grav-v1.6.26.zip

About: Grav is a fast, simple, and flexible flat-file based CMS platform (using YAML and PHP). Contents are just simple markdown files in folders with optional extensions via API and hooks.

Response.php  (grav-v1.6.25):Response.php  (grav-v1.6.26)
skipping to change at line 411 skipping to change at line 411
do { do {
curl_setopt($rch, CURLOPT_URL, $uri); curl_setopt($rch, CURLOPT_URL, $uri);
$header = curl_exec($rch); $header = curl_exec($rch);
if (curl_errno($rch)) { if (curl_errno($rch)) {
$code = 0; $code = 0;
} else { } else {
$code = (int)curl_getinfo($rch, CURLINFO_HTTP_CODE); $code = (int)curl_getinfo($rch, CURLINFO_HTTP_CODE);
if ($code === 301 || $code === 302 || $code === 303) { if ($code === 301 || $code === 302 || $code === 303) {
preg_match('/Location:(.*?)\n/', $header, $matches); preg_match('/(?:^|\n)Location:(.*?)\n/i', $header, $matches) ;
$uri = trim(array_pop($matches)); $uri = trim(array_pop($matches));
} else { } else {
$code = 0; $code = 0;
} }
} }
} while ($code && --$max_redirects); } while ($code && --$max_redirects);
curl_close($rch); curl_close($rch);
if (!$max_redirects) { if (!$max_redirects) {
 End of changes. 1 change blocks. 
1 lines changed or deleted 1 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)