Move z_fetch_url

move z_fetch_url method
This commit is contained in:
Adam Magness 2018-01-26 23:18:38 -05:00
commit 2f9642392d
14 changed files with 58 additions and 60 deletions

View file

@ -12,6 +12,7 @@
use Friendica\App;
use Friendica\Core\Addon;
use Friendica\Util\Network;
use Friendica\Util\ParseUrl;
require_once("include/items.php");
@ -60,7 +61,7 @@ function parse_url_content(App $a) {
// the URL with the corresponding BBCode media tag
$redirects = 0;
// Fetch the header of the URL
$result = z_fetch_url($url, false, $redirects, ["novalidate" => true, "nobody" => true]);
$result = Network::zFetchURL($url, false, $redirects, ["novalidate" => true, "nobody" => true]);
if($result["success"]) {
// Convert the header fields into an array
$hdrs = [];