original_string: protected static function resolveUrl($url)
      {
          $url = trim($url);
          if (strlen($url)) {
              if (preg_match('%^https?\:\/\/%', $url)) {
                  return $url;
              }
              $absScript = GeneralUtility::getFileAbsFileName($url);
              if (is_file($absScript)) {
                  return substr($absScript, strlen(PATH_site));
              }
          }
  
          return null;
      }
code: protected static function resolveUrl($url)
      {
          $url = trim($url);
          if (strlen($url)) {
              if (preg_match('%^https?\:\/\/%', $url)) {
                  return $url;
              }
              $absScript = GeneralUtility::getFileAbsFileName($url);
              if (is_file($absScript)) {
                  return substr($absScript, strlen(PATH_site));
              }
          }
  
          return null;
      }
code_tokens: protected static function resolveUrl ( $ url ) { $ url = trim ( $ url ) ; if ( strlen ( $ url ) ) { if ( preg_match ( '%^https?\:\/\/%' , $ url ) ) { return $ url ; } $ absScript = GeneralUtility :: getFileAbsFileName ( $ url ) ; if ( is_file ( $ absScript ) ) { return substr ( $ absScript , strlen ( PATH_site ) ) ; } } return null ; }
docstring: Resolve a URL
  
  @param string $url URL
  
  @return bool|string Resolved URL
docstring_tokens: Resolve a URL