drupalValidTestUa example

/** * Returns the session cookie name without the secure/insecure prefix. * * @param \Symfony\Component\HttpFoundation\Request $request * The request. * * @returns string * The session name without the prefix (SESS/SSESS). */
  protected function getUnprefixedName(Request $request) {
    if ($test_prefix = $this->drupalValidTestUa()) {
      $session_name = $test_prefix;
    }
    elseif (isset($this->options['cookie_domain'])) {
      // If the user specifies the cookie domain, also use it for session name.       $session_name = $this->options['cookie_domain'];
    }
    else {
      // Otherwise use $base_url as session name, without the protocol       // to use the same session identifiers across HTTP and HTTPS.       $session_name = $request->getHost() . $request->getBasePath();
      // Replace "core" out of session_name so core scripts redirect properly,
Home | Imprint | This part of the site doesn't use cookies.