original_string: public static function getBasicPath() {
          $s = &$_SERVER;
          $ssl = (!empty($s['HTTPS']) && $s['HTTPS'] == 'on') ? true : false;
          $sp = strtolower($s['SERVER_PROTOCOL']);
          $protocol = substr($sp, 0, strpos($sp, '/')) . (($ssl) ? 's' : '');
          $port = $s['SERVER_PORT'];
          $port = ((!$ssl && $port == '80') || ($ssl && $port == '443')) ? '' : ':' . $port;
          $host = isset($s['HTTP_X_FORWARDED_HOST']) ? $s['HTTP_X_FORWARDED_HOST'] : (isset($s['HTTP_HOST']) ? $s['HTTP_HOST'] : null);
          $host = isset($host) ? $host : $s['SERVER_NAME'] . $port;
          $uri = $protocol . '://' . $host;
          return $uri;
      }
code: public static function getBasicPath() {
          $s = &$_SERVER;
          $ssl = (!empty($s['HTTPS']) && $s['HTTPS'] == 'on') ? true : false;
          $sp = strtolower($s['SERVER_PROTOCOL']);
          $protocol = substr($sp, 0, strpos($sp, '/')) . (($ssl) ? 's' : '');
          $port = $s['SERVER_PORT'];
          $port = ((!$ssl && $port == '80') || ($ssl && $port == '443')) ? '' : ':' . $port;
          $host = isset($s['HTTP_X_FORWARDED_HOST']) ? $s['HTTP_X_FORWARDED_HOST'] : (isset($s['HTTP_HOST']) ? $s['HTTP_HOST'] : null);
          $host = isset($host) ? $host : $s['SERVER_NAME'] . $port;
          $uri = $protocol . '://' . $host;
          return $uri;
      }
code_tokens: public static function getBasicPath ( ) { $ s = & $ _SERVER ; $ ssl = ( ! empty ( $ s [ 'HTTPS' ] ) && $ s [ 'HTTPS' ] == 'on' ) ? true : false ; $ sp = strtolower ( $ s [ 'SERVER_PROTOCOL' ] ) ; $ protocol = substr ( $ sp , 0 , strpos ( $ sp , '/' ) ) . ( ( $ ssl ) ? 's' : '' ) ; $ port = $ s [ 'SERVER_PORT' ] ; $ port = ( ( ! $ ssl && $ port == '80' ) || ( $ ssl && $ port == '443' ) ) ? '' : ':' . $ port ; $ host = isset ( $ s [ 'HTTP_X_FORWARDED_HOST' ] ) ? $ s [ 'HTTP_X_FORWARDED_HOST' ] : ( isset ( $ s [ 'HTTP_HOST' ] ) ? $ s [ 'HTTP_HOST' ] : null ) ; $ host = isset ( $ host ) ? $ host : $ s [ 'SERVER_NAME' ] . $ port ; $ uri = $ protocol . '://' . $ host ; return $ uri ; }
docstring: Get basic path
  @return string URL
docstring_tokens: Get basic path