X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=include%2Fnetwork.php;h=f6e6cc2a30825c189ab77f196f0780b39ac80586;hb=5f1ef732e05c79584e6ea1cdb14360a7dd388a9d;hp=5877dda41b876651810cc8e76e3766b0bd475cb7;hpb=a6b1275f16ab67a26ac1a4cc18cffd3d454b0940;p=friendica.git diff --git a/include/network.php b/include/network.php index 5877dda41b..f6e6cc2a30 100644 --- a/include/network.php +++ b/include/network.php @@ -15,6 +15,9 @@ function fetch_url($url,$binary = false, &$redirects = 0, $timeout = 0, $accept_ @curl_setopt($ch, CURLOPT_HEADER, true); + @curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true); + @curl_setopt($ch, CURLOPT_MAXREDIRS, 5); + if (!is_null($accept_content)){ curl_setopt($ch,CURLOPT_HTTPHEADER, array ( "Accept: " . $accept_content