$stamp1 = microtime(true);
- $a = get_app();
+ $a = \get_app();
$parts = parse_url($url);
$path_parts = explode('/', defaults($parts, 'path', ''));
return CurlResult::createErrorCurl($url);
}
- $a = get_app();
+ $a = \get_app();
$ch = curl_init($url);
if (($redirects > 8) || (!$ch)) {
/// @TODO Really suppress function outcomes? Why not find them + debug them?
$h = @parse_url($url);
- if ((is_array($h)) && (@dns_get_record($h['host'], DNS_A + DNS_CNAME) || filter_var($h['host'], FILTER_VALIDATE_IP) )) {
+ if (!empty($h['host']) && (@dns_get_record($h['host'], DNS_A + DNS_CNAME) || filter_var($h['host'], FILTER_VALIDATE_IP) )) {
return $url;
}
*/
public static function finalUrl($url, $depth = 1, $fetchbody = false)
{
- $a = get_app();
+ $a = \get_app();
$url = self::stripTrackingQueryParams($url);