Server geändert

This commit is contained in:
aschwarz
2023-04-25 13:16:13 +02:00
parent acc225abac
commit faad1bfa71
966 changed files with 5193 additions and 5193 deletions

View File

@ -30,7 +30,7 @@ echo $response->getHeaderLine('content-type'); // 'application/json; charset=utf
echo $response->getBody(); // '{"id": 1420053, "name": "guzzle", ...}'
// Send an asynchronous request.
$request = new \GuzzleHttp\Psr7\Request('GET', 'http://httpbin.org');
$request = new \GuzzleHttp\Psr7\Request('GET', 'https://httpbin.org');
$promise = $client->sendAsync($request)->then(function ($response) {
echo 'I completed! ' . $response->getBody();
});
@ -42,9 +42,9 @@ $promise->wait();
We use GitHub issues only to discuss bugs and new features. For support please refer to:
- [Documentation](http://guzzlephp.org/)
- [Stack Overflow](http://stackoverflow.com/questions/tagged/guzzle)
- [#guzzle](https://app.slack.com/client/T0D2S9JCT/CE6UAAKL4) channel on [PHP-HTTP Slack](http://slack.httplug.io/)
- [Documentation](https://guzzlephp.org/)
- [Stack Overflow](https://stackoverflow.com/questions/tagged/guzzle)
- [#guzzle](https://app.slack.com/client/T0D2S9JCT/CE6UAAKL4) channel on [PHP-HTTP Slack](https://slack.httplug.io/)
- [Gitter](https://gitter.im/guzzle/guzzle)
@ -73,7 +73,7 @@ composer require guzzlehttp/guzzle
[guzzle-5-repo]: https://github.com/guzzle/guzzle/tree/5.3
[guzzle-6-repo]: https://github.com/guzzle/guzzle/tree/6.5
[guzzle-7-repo]: https://github.com/guzzle/guzzle
[guzzle-3-docs]: http://guzzle3.readthedocs.org
[guzzle-5-docs]: http://docs.guzzlephp.org/en/5.3/
[guzzle-6-docs]: http://docs.guzzlephp.org/en/6.5/
[guzzle-7-docs]: http://docs.guzzlephp.org/en/latest/
[guzzle-3-docs]: https://guzzle3.readthedocs.org
[guzzle-5-docs]: https://docs.guzzlephp.org/en/5.3/
[guzzle-6-docs]: https://docs.guzzlephp.org/en/6.5/
[guzzle-7-docs]: https://docs.guzzlephp.org/en/latest/

View File

@ -189,11 +189,11 @@ $client = new GuzzleHttp\Client(['handler' => $handler]);
## POST Requests
This version added the [`form_params`](http://guzzle.readthedocs.org/en/latest/request-options.html#form_params)
This version added the [`form_params`](https://guzzle.readthedocs.org/en/latest/request-options.html#form_params)
and `multipart` request options. `form_params` is an associative array of
strings or array of strings and is used to serialize an
`application/x-www-form-urlencoded` POST request. The
[`multipart`](http://guzzle.readthedocs.org/en/latest/request-options.html#multipart)
[`multipart`](https://guzzle.readthedocs.org/en/latest/request-options.html#multipart)
option is now used to send a multipart/form-data POST request.
`GuzzleHttp\Post\PostFile` has been removed. Use the `multipart` option to add
@ -209,7 +209,7 @@ The `base_url` option has been renamed to `base_uri`.
## Rewritten Adapter Layer
Guzzle now uses [RingPHP](http://ringphp.readthedocs.org/en/latest) to send
Guzzle now uses [RingPHP](https://ringphp.readthedocs.org/en/latest) to send
HTTP requests. The `adapter` option in a `GuzzleHttp\Client` constructor
is still supported, but it has now been renamed to `handler`. Instead of
passing a `GuzzleHttp\Adapter\AdapterInterface`, you must now pass a PHP
@ -575,7 +575,7 @@ You can intercept a request and inject a response using the `intercept()` event
of a `GuzzleHttp\Event\BeforeEvent`, `GuzzleHttp\Event\CompleteEvent`, and
`GuzzleHttp\Event\ErrorEvent` event.
See: http://docs.guzzlephp.org/en/latest/events.html
See: https://docs.guzzlephp.org/en/latest/events.html
## Inflection
@ -668,9 +668,9 @@ in separate repositories:
The service description layer of Guzzle has moved into two separate packages:
- http://github.com/guzzle/command Provides a high level abstraction over web
- https://github.com/guzzle/command Provides a high level abstraction over web
services by representing web service operations using commands.
- http://github.com/guzzle/guzzle-services Provides an implementation of
- https://github.com/guzzle/guzzle-services Provides an implementation of
guzzle/command that provides request serialization and response parsing using
Guzzle service descriptions.
@ -920,17 +920,17 @@ URLs no longer have a default path value of '/' if no path was specified.
Before:
```php
$request = $client->get('http://www.foo.com');
$request = $client->get('https://www.foo.com');
echo $request->getUrl();
// >> http://www.foo.com/
// >> https://www.foo.com/
```
After:
```php
$request = $client->get('http://www.foo.com');
$request = $client->get('https://www.foo.com');
echo $request->getUrl();
// >> http://www.foo.com
// >> https://www.foo.com
```
### Less verbose BadResponseException

View File

@ -13,7 +13,7 @@
"PSR-7",
"PSR-18"
],
"homepage": "http://guzzlephp.org/",
"homepage": "https://guzzlephp.org/",
"license": "MIT",
"authors": [
{

View File

@ -26,7 +26,7 @@ class Client implements ClientInterface, \Psr\Http\Client\ClientInterface
* default request options to apply to each request:
*
* $client = new Client([
* 'base_uri' => 'http://www.foo.com/1.0/',
* 'base_uri' => 'https://www.foo.com/1.0/',
* 'timeout' => 0,
* 'allow_redirects' => false,
* 'proxy' => '192.168.16.1:10'

View File

@ -5,9 +5,9 @@ namespace GuzzleHttp;
/**
* This class contains a list of built-in Guzzle request options.
*
* More documentation for each option can be found at http://guzzlephp.org/.
* More documentation for each option can be found at https://guzzlephp.org/.
*
* @link http://docs.guzzlephp.org/en/v6/request-options.html
* @link https://docs.guzzlephp.org/en/v6/request-options.html
*/
final class RequestOptions
{

View File

@ -179,7 +179,7 @@ No system CA bundle could be found in any of the the common system locations.
PHP versions earlier than 5.6 are not properly configured to use the system's
CA bundle by default. In order to verify peer certificates, you will need to
supply the path on disk to a certificate bundle to the 'verify' request
option: http://docs.guzzlephp.org/en/latest/clients.html#verify. If you do not
option: https://docs.guzzlephp.org/en/latest/clients.html#verify. If you do not
need a specific certificate bundle, then Mozilla provides a commonly used CA
bundle which can be downloaded here (provided by the maintainer of cURL):
https://curl.haxx.se/ca/cacert.pem. Once

View File

@ -3,8 +3,8 @@
All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/)
and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html).
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/)
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
## [Unreleased]
@ -117,7 +117,7 @@ Several other fixes and improvements.
doing some magic.
- `(new Uri)->withPath('foo')->withHost('example.com')` will throw an exception
because the path of a URI with an authority must start with a slash "/" or be empty
- `(new Uri())->withScheme('http')` will return `'http://localhost'`
- `(new Uri())->withScheme('http')` will return `'https://localhost'`
### Deprecated

View File

@ -1,6 +1,6 @@
# PSR-7 Message Implementation
This repository contains a full [PSR-7](http://www.php-fig.org/psr/psr-7/)
This repository contains a full [PSR-7](https://www.php-fig.org/psr/psr-7/)
message implementation, several stream decorators, and some helpful
functionality like query string parsing.
@ -65,7 +65,7 @@ then on disk.
```php
use GuzzleHttp\Psr7;
$original = Psr7\stream_for(fopen('http://www.google.com', 'r'));
$original = Psr7\stream_for(fopen('https://www.google.com', 'r'));
$stream = new Psr7\CachingStream($original);
$stream->read(1024);
@ -315,7 +315,7 @@ There are various functions available under the `GuzzleHttp\Psr7` namespace.
Returns the string representation of an HTTP message.
```php
$request = new GuzzleHttp\Psr7\Request('GET', 'http://example.com');
$request = new GuzzleHttp\Psr7\Request('GET', 'https://example.com');
echo GuzzleHttp\Psr7\str($request);
```
@ -329,7 +329,7 @@ UriInterface for the given value. If the value is already a `UriInterface`, it
is returned as-is.
```php
$uri = GuzzleHttp\Psr7\uri_for('http://example.com');
$uri = GuzzleHttp\Psr7\uri_for('https://example.com');
assert($uri === GuzzleHttp\Psr7\uri_for($uri));
```
@ -595,7 +595,7 @@ manually but instead is used indirectly via `Psr\Http\Message\UriInterface::__to
`public static function fromParts(array $parts): UriInterface`
Creates a URI from a hash of [`parse_url`](http://php.net/manual/en/function.parse-url.php) components.
Creates a URI from a hash of [`parse_url`](https://php.net/manual/en/function.parse-url.php) components.
### `GuzzleHttp\Psr7\Uri::withQueryValue`
@ -653,11 +653,11 @@ One use-case is to use the current request URI as base URI and then generate rel
to reduce the document size or offer self-contained downloadable document archives.
```php
$base = new Uri('http://example.com/a/b/');
echo UriResolver::relativize($base, new Uri('http://example.com/a/b/c')); // prints 'c'.
echo UriResolver::relativize($base, new Uri('http://example.com/a/x/y')); // prints '../x/y'.
echo UriResolver::relativize($base, new Uri('http://example.com/a/b/?q')); // prints '?q'.
echo UriResolver::relativize($base, new Uri('http://example.org/a/b/')); // prints '//example.org/a/b/'.
$base = new Uri('https://example.com/a/b/');
echo UriResolver::relativize($base, new Uri('https://example.com/a/b/c')); // prints 'c'.
echo UriResolver::relativize($base, new Uri('https://example.com/a/x/y')); // prints '../x/y'.
echo UriResolver::relativize($base, new Uri('https://example.com/a/b/?q')); // prints '?q'.
echo UriResolver::relativize($base, new Uri('https://example.org/a/b/')); // prints '//example.org/a/b/'.
```
## Normalization and Comparison
@ -681,7 +681,7 @@ of normalizations to apply. The following normalizations are available:
All letters within a percent-encoding triplet (e.g., "%3A") are case-insensitive, and should be capitalized.
Example: `http://example.org/a%c2%b1b``http://example.org/a%C2%B1b`
Example: `https://example.org/a%c2%b1b``https://example.org/a%C2%B1b`
- `UriNormalizer::DECODE_UNRESERVED_CHARACTERS`
@ -690,13 +690,13 @@ of normalizations to apply. The following normalizations are available:
not be created by URI producers and, when found in a URI, should be decoded to their corresponding unreserved
characters by URI normalizers.
Example: `http://example.org/%7Eusern%61me/``http://example.org/~username/`
Example: `https://example.org/%7Eusern%61me/``https://example.org/~username/`
- `UriNormalizer::CONVERT_EMPTY_PATH`
Converts the empty path to "/" for http and https URIs.
Example: `http://example.org``http://example.org/`
Example: `https://example.org``https://example.org/`
- `UriNormalizer::REMOVE_DEFAULT_HOST`
@ -710,14 +710,14 @@ of normalizations to apply. The following normalizations are available:
Removes the default port of the given URI scheme from the URI.
Example: `http://example.org:80/``http://example.org/`
Example: `https://example.org:80/``https://example.org/`
- `UriNormalizer::REMOVE_DOT_SEGMENTS`
Removes unnecessary dot-segments. Dot-segments in relative-path references are not removed as it would
change the semantics of the URI reference.
Example: `http://example.org/../a/b/../c/./d.html``http://example.org/a/c/d.html`
Example: `https://example.org/../a/b/../c/./d.html``https://example.org/a/c/d.html`
- `UriNormalizer::REMOVE_DUPLICATE_SLASHES`
@ -725,7 +725,7 @@ of normalizations to apply. The following normalizations are available:
and treat those URIs equivalent. But in theory those URIs do not need to be equivalent. So this normalization
may change the semantics. Encoded slashes (%2F) are not removed.
Example: `http://example.org//foo///bar.html``http://example.org/foo/bar.html`
Example: `https://example.org//foo///bar.html``https://example.org/foo/bar.html`
- `UriNormalizer::SORT_QUERY_PARAMETERS`

View File

@ -11,8 +11,8 @@ use Psr\Http\Message\StreamInterface;
* then appends the zlib.inflate filter. The stream is then converted back
* to a Guzzle stream resource to be used as a Guzzle stream.
*
* @link http://tools.ietf.org/html/rfc1952
* @link http://php.net/manual/en/filters.compression.php
* @link https://tools.ietf.org/html/rfc1952
* @link https://php.net/manual/en/filters.compression.php
*/
class InflateStream implements StreamInterface
{

View File

@ -138,7 +138,7 @@ class Request implements RequestInterface
$this->headerNames['host'] = 'Host';
}
// Ensure Host is the first header.
// See: http://tools.ietf.org/html/rfc7230#section-5.4
// See: https://tools.ietf.org/html/rfc7230#section-5.4
$this->headers = [$header => [$host]] + $this->headers;
}

View File

@ -182,7 +182,7 @@ class ServerRequest extends Request implements ServerRequestInterface
private static function extractHostAndPortFromAuthority($authority)
{
$uri = 'http://'.$authority;
$uri = 'https://'.$authority;
$parts = parse_url($uri);
if (false === $parts) {
return [null, null];

View File

@ -15,8 +15,8 @@ class Stream implements StreamInterface
*
* @var string
*
* @see http://php.net/manual/function.fopen.php
* @see http://php.net/manual/en/function.gzopen.php
* @see https://php.net/manual/function.fopen.php
* @see https://php.net/manual/en/function.gzopen.php
*/
const READABLE_MODES = '/r|a\+|ab\+|w\+|wb\+|x\+|xb\+|c\+|cb\+/';
const WRITABLE_MODES = '/a|w|r\+|rb\+|rw|x|c/';

View File

@ -236,8 +236,8 @@ class UploadedFile implements UploadedFileInterface
/**
* {@inheritdoc}
*
* @see http://php.net/is_uploaded_file
* @see http://php.net/move_uploaded_file
* @see https://php.net/is_uploaded_file
* @see https://php.net/move_uploaded_file
* @param string $targetPath Path to which to move the uploaded file.
* @throws RuntimeException if the upload was not successful.
* @throws InvalidArgumentException if the $path specified is invalid.
@ -287,7 +287,7 @@ class UploadedFile implements UploadedFileInterface
/**
* {@inheritdoc}
*
* @see http://php.net/manual/en/features.file-upload.errors.php
* @see https://php.net/manual/en/features.file-upload.errors.php
* @return int One of PHP's UPLOAD_ERR_XXX constants.
*/
public function getError()

View File

@ -357,7 +357,7 @@ class Uri implements UriInterface
* @param array $parts
*
* @return UriInterface
* @link http://php.net/manual/en/function.parse-url.php
* @link https://php.net/manual/en/function.parse-url.php
*
* @throws \InvalidArgumentException If the components do not form a valid URI.
*/

View File

@ -23,7 +23,7 @@ final class UriNormalizer
/**
* All letters within a percent-encoding triplet (e.g., "%3A") are case-insensitive, and should be capitalized.
*
* Example: http://example.org/a%c2%b1b → http://example.org/a%C2%B1b
* Example: https://example.org/a%c2%b1b → https://example.org/a%C2%B1b
*/
const CAPITALIZE_PERCENT_ENCODING = 1;
@ -34,14 +34,14 @@ final class UriNormalizer
* hyphen (%2D), period (%2E), underscore (%5F), or tilde (%7E) should not be created by URI producers and,
* when found in a URI, should be decoded to their corresponding unreserved characters by URI normalizers.
*
* Example: http://example.org/%7Eusern%61me/ → http://example.org/~username/
* Example: https://example.org/%7Eusern%61me/ → https://example.org/~username/
*/
const DECODE_UNRESERVED_CHARACTERS = 2;
/**
* Converts the empty path to "/" for http and https URIs.
*
* Example: http://example.org → http://example.org/
* Example: https://example.org → https://example.org/
*/
const CONVERT_EMPTY_PATH = 4;
@ -61,7 +61,7 @@ final class UriNormalizer
/**
* Removes the default port of the given URI scheme from the URI.
*
* Example: http://example.org:80/ → http://example.org/
* Example: https://example.org:80/ → https://example.org/
*/
const REMOVE_DEFAULT_PORT = 16;
@ -71,7 +71,7 @@ final class UriNormalizer
* Dot-segments in relative-path references are not removed as it would
* change the semantics of the URI reference.
*
* Example: http://example.org/../a/b/../c/./d.html → http://example.org/a/c/d.html
* Example: https://example.org/../a/b/../c/./d.html → https://example.org/a/c/d.html
*/
const REMOVE_DOT_SEGMENTS = 32;
@ -82,7 +82,7 @@ final class UriNormalizer
* But in theory those URIs do not need to be equivalent. So this normalization
* may change the semantics. Encoded slashes (%2F) are not removed.
*
* Example: http://example.org//foo///bar.html → http://example.org/foo/bar.html
* Example: https://example.org//foo///bar.html → https://example.org/foo/bar.html
*/
const REMOVE_DUPLICATE_SLASHES = 64;

View File

@ -18,7 +18,7 @@ final class UriResolver
* @param string $path
*
* @return string
* @link http://tools.ietf.org/html/rfc3986#section-5.2.4
* @link https://tools.ietf.org/html/rfc3986#section-5.2.4
*/
public static function removeDotSegments($path)
{
@ -57,7 +57,7 @@ final class UriResolver
* @param UriInterface $rel Relative URI
*
* @return UriInterface
* @link http://tools.ietf.org/html/rfc3986#section-5.2
* @link https://tools.ietf.org/html/rfc3986#section-5.2
*/
public static function resolve(UriInterface $base, UriInterface $rel)
{
@ -118,11 +118,11 @@ final class UriResolver
* One use-case is to use the current request URI as base URI and then generate relative links in your documents
* to reduce the document size or offer self-contained downloadable document archives.
*
* $base = new Uri('http://example.com/a/b/');
* echo UriResolver::relativize($base, new Uri('http://example.com/a/b/c')); // prints 'c'.
* echo UriResolver::relativize($base, new Uri('http://example.com/a/x/y')); // prints '../x/y'.
* echo UriResolver::relativize($base, new Uri('http://example.com/a/b/?q')); // prints '?q'.
* echo UriResolver::relativize($base, new Uri('http://example.org/a/b/')); // prints '//example.org/a/b/'.
* $base = new Uri('https://example.com/a/b/');
* echo UriResolver::relativize($base, new Uri('https://example.com/a/b/c')); // prints 'c'.
* echo UriResolver::relativize($base, new Uri('https://example.com/a/x/y')); // prints '../x/y'.
* echo UriResolver::relativize($base, new Uri('https://example.com/a/b/?q')); // prints '?q'.
* echo UriResolver::relativize($base, new Uri('https://example.org/a/b/')); // prints '//example.org/a/b/'.
*
* This method also accepts a target that is already relative and will try to relativize it further. Only a
* relative-path reference will be returned as-is.

View File

@ -632,7 +632,7 @@ function mimetype_from_filename($filename)
* @param $extension string The file extension.
*
* @return string|null
* @link http://svn.apache.org/repos/asf/httpd/httpd/branches/1.3.x/conf/mime.types
* @link https://svn.apache.org/repos/asf/httpd/httpd/branches/1.3.x/conf/mime.types
*/
function mimetype_from_extension($extension)
{