Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. Cookie.php

function Cookie::withValue

Creates a cookie copy with a new value.

File

vendor/symfony/http-foundation/Cookie.php, line 119

Class

Cookie
Represents a cookie.

Namespace

Symfony\Component\HttpFoundation

Code

public function withValue(?string $value) : static {
    $cookie = clone $this;
    $cookie->value = $value;
    return $cookie;
}

API Navigation

  • Drupal Core 11.1.x
  • Topics
  • Classes
  • Functions
  • Constants
  • Globals
  • Files
  • Namespaces
  • Deprecated
  • Services
RSS feed
Powered by Drupal