src/View/Requirements_Backend.php
protected function pathForFile($fileOrUrl)
    {
        // Since combined urls could be root relative, treat them as urls here.
        if (preg_match('{^(//)|(http[s]?:)}', $fileOrUrl) || Director::is_root_relative_url($fileOrUrl)) {
            return $fileOrUrl;
        } else {
            return Injector::inst()->get(ResourceURLGenerator::class)->urlForResource($fileOrUrl);
        }
    }
protected function pathForFile($fileOrUrl)
    {
        // Since combined urls could be root relative, treat them as urls here.
        if (preg_match('{^(//)|(http[s]?:)}', $fileOrUrl) || Director::is_root_relative_url($fileOrUrl)) {
            return $fileOrUrl;
        } else {
            return Injector::inst()->get(ResourceURLGenerator::class)->urlForResource($fileOrUrl);
        }
    }
protected function pathForFile ( $ fileOrUrl ) { // Since combined urls could be root relative, treat them as urls here. if ( preg_match ( '{^(//)|(http[s]?:)}' , $ fileOrUrl ) || Director :: is_root_relative_url ( $ fileOrUrl ) ) { return $ fileOrUrl ; } else { return Injector :: inst ( ) -> get ( ResourceURLGenerator :: class ) -> urlForResource ( $ fileOrUrl ) ; } }
Finds the path for specified file

@param string $fileOrUrl
@return string|bool
Finds the path for specified file