public function Request::setHost

Set the host of the request. Including a port in the host will modify the port of the request.

Parameters

string $host Host to set (e.g. www.yahoo.com, www.yahoo.com:80):

Return value

RequestInterface

Overrides RequestInterface::setHost

1 call to Request::setHost()
Request::changedHeader in drupal/core/vendor/guzzle/http/Guzzle/Http/Message/Request.php
Check to see if the modified headers need to reset any of the managed headers like cache-control

File

drupal/core/vendor/guzzle/http/Guzzle/Http/Message/Request.php, line 320

Class

Request
HTTP request class to send requests

Namespace

Guzzle\Http\Message

Code

public function setHost($host) {
  $this->url
    ->setHost($host);
  $this
    ->setPort($this->url
    ->getPort());
  return $this;
}