Verzeichnisstruktur phpBB-3.3.16


Veröffentlicht
27.04.2026

So funktioniert es


Auf das letzte Element klicken. Dies geht jeweils ein Schritt zurück

Auf das Icon klicken, dies öffnet das Verzeichnis. Nochmal klicken schließt das Verzeichnis.
Auf den Verzeichnisnamen klicken, dies zeigt nur das Verzeichnis mit Inhalt an

      (Beispiel Datei-Icons)

Auf das Icon klicken um den Quellcode anzuzeigen

UriComparator.php

Zuletzt modifiziert: 01.05.2026, 11:26 - Dateigröße: 1.15 KiB


 01  <?php
 02   
 03  namespace GuzzleHttp\Psr7;
 04   
 05  use Psr\Http\Message\UriInterface;
 06   
 07  /**
 08   * Provides methods to determine if a modified URL should be considered cross-origin.
 09   *
 10   * @author Graham Campbell
 11   */
 12  final class UriComparator
 13  {
 14      /**
 15       * Determines if a modified URL should be considered cross-origin with
 16       * respect to an original URL.
 17       *
 18       * @return bool
 19       */
 20      public static function isCrossOrigin(UriInterface $original, UriInterface $modified)
 21      {
 22          if (\strcasecmp($original->getHost(), $modified->getHost()) !== 0) {
 23              return true;
 24          }
 25   
 26          if ($original->getScheme() !== $modified->getScheme()) {
 27              return true;
 28          }
 29   
 30          if (self::computePort($original) !== self::computePort($modified)) {
 31              return true;
 32          }
 33   
 34          return false;
 35      }
 36   
 37      /**
 38       * @return int
 39       */
 40      private static function computePort(UriInterface $uri)
 41      {
 42          $port = $uri->getPort();
 43   
 44          if (null !== $port) {
 45              return $port;
 46          }
 47   
 48          return 'https' === $uri->getScheme() ? 443 : 80;
 49      }
 50   
 51      private function __construct()
 52      {
 53          // cannot be instantiated
 54      }
 55  }
 56