Check is url absolute

@param string $_path
@return bool
514041
public static function isAbsoluteUrl($_path)
    {
        $url = parse_url($_path);

        return $url !== false && isset($url['scheme']) && $url['scheme'] != '';
    }
1017277
protected static function isValidPath($path)
    {
        if (strpos($path, '?') !== false) {
            return false;
        }
        if (strpos($path, '*') !== false) {
            return false;
        }
        if (strpos($path, ':') !== false) {
            return false;
        }
        if (strpos($path, '|') !== false) {
            return false;
        }
        if (strpos($path, '\\') !== false) {
            return false;
        }
        if (strpos($path, '<') !== false) {
            return false;
        }
        if (strpos($path, '>') !== false) {
            return false;
        }
        if (strpos($path, '"') !== false) {
            return false;
        }

        return true;
    }
197501
protected function validatePath($path)
    {
        if (empty($path)) {
            return false;
        }

        // we are always operating from root directory
        // so forbid relative paths
        if (false !== strpos($path, '..')) {
            return false;
        }

        return true;
    }
216439
def absolute(path = nil)
      return path if path && path[0] != '/'
      abs = if path
        [env['scorched.root_path'], path].join('/').gsub(%r{/+}, '/')
      else
        env['scorched.root_path']
      end
      abs.insert(0, '/') unless abs[0] == '/'
      abs
    end
596448
public static function isInternal($url)
    {
        $relative = static::makeRelative($url);

        if (substr($relative, 0, 1) !== '/') {
            return false;
        }

        $path = static::getInternalPath($relative);

        return !URLFacade::isAvailable($path);
    }
1133107
public function setPathAbsolute(string $path_absolute) {
        if(!$this->setModified('path_absolute', $path_absolute)->isModified()) {
            return $this;
        }
		$this->path_absolute = $path_absolute;
		return $this;
    }
551735
static function isAbsolute($path)
    {
        if (realpath($path) === $path) {
            return true;
        }

        if (empty($path)) {
            return false;
        }

        # Absolute Path (Unix) or Absolute UNC Path.
        if ($path[0] === '/' or $path[0] === '\\') {
            return true;
        }

        # If the path starts with a drive letter or "\\" (Windows):
        if (static::isWindows() and preg_match('#^([a-z]\:)?\\\\{1,2}#i', $path)) {
            return true;
        }
        return false;
    }
586132
def _path_is_abs(path):
    '''
    
    '''
    if path is None:
        return True
    try:
        return os.path.isabs(path)
    except AttributeError:
        # Non-string data passed
        return False
951188
public function fileExists($path) {

        $ch = curl_init($this->hostUrl . "/" . $this->siteFolder . $path);

        curl_setopt($ch, CURLOPT_NOBODY, true);

        $result = curl_exec($ch);
        $ret = false;

        if($result !== false) {
        $status = curl_getinfo($ch, CURLINFO_HTTP_CODE);

        if($status == 200) {
            $ret = true;
        }
        }

        curl_close($ch);

        return $ret;
    }
800420
public static boolean isAbsolutePath (final String path) {
        if (path == null || path.trim().length() == 0) {
            return false;
        }

        if (File.separator.equals(UNIX_SEPARATOR)) {
            return path.startsWith(UNIX_SEPARATOR);
        } else

        if (File.separator.equals(WINDOWS_SEPARATOR) && path.length() > 2) {
            return path.matches("([a-zA-Z]:|\\\\)\\\\.*");
        }

        return false;
    }
660102
public static function isAbsolutePath($path): bool
    {
        return strspn($path, '/\\', 0, 1)
            || (strlen($path) > 3 && ctype_alpha($path[0])
                && ':' === $path[1]
                && strspn($path, '/\\', 2, 1)
            )
            || null !== parse_url($path, PHP_URL_SCHEME);
    }
759186
public static function is_svg( $file_path ) {
		if ( ! isset( $file_path ) || '' === $file_path || ! file_exists( $file_path ) ) {
			return false;
		}

		if ( TextHelper::ends_with( strtolower($file_path), '.svg' ) ) {
			return true;
		}

		/**
		 * Try reading mime type.
		 *
		 * SVG images are not allowed by default in WordPress, so we have to pass a default mime
		 * type for SVG images.
		 */
		$mime = wp_check_filetype_and_ext( $file_path, basename( $file_path ), array(
			'svg' => 'image/svg+xml',
		) );

		return in_array( $mime['type'], array(
			'image/svg+xml',
			'text/html',
			'text/plain',
			'image/svg',
		) );
	}
862700
private static function isAbsolutePath($path): bool
    {
        // Path starting with a / is always absolute, on every system
        // On Windows also a path starting with a drive letter is absolute: X:/
        return ($path[0] ?? null) === '/'
            || static::isWindows() && (
                strpos($path, ':/') === 1
                || strpos($path, ':\\') === 1
            );
    }
1364557
function is_file($path) {

        $item = $this->gpi($path);

        if ($item === false) {
            return false;
        } else {
            return ($item['resourcetype'] != 'collection');
        }
    }
732190
public function checkPath($path)
    {
        $path = realpath($path);

        return ($path !== false && is_dir($path)) ? $path : false;
    }
14582
public static function isDir($path)
    {
        return (self::isPhar($path) === true) ? file_exists($path) : is_dir($path);
    }
408693
public static function is_abs_path($path)
    {
        $ds = array('\\' => 1, '/' => 2);
        if (isset($ds[substr($path, 0, 1)]) ||
            substr($path, 1, 1) == ':' && isset($ds[substr($path, 2, 1)])
        ) {
            return true;
        }
        if (($l = strpos($path, '://')) && $l < 32) {
            return $l;
        }

        return false;
    }