Skip to content

SID is deprecated #5937

Open
Open

Description

@hjberven

Affected page

https://www.php.net/manual/en/function.session-id.php

Issue description

On the page, it says: "The constant SID can also be used to retrieve the current name and session id as a string suitable for adding to URLs. See also Session handling."

But on this other page, it says "Warning. This constant has been deprecated as of PHP 8.4.0."

Other page is https://www.php.net/manual/en/session.constants.php#constant.sid

Steps to reproduce

  1. Visit the page https://www.php.net/manual/en/session.constants.php#constant.sid
  2. Note how the constant SID is deprecated
  3. Visit the page https://www.php.net/manual/en/function.session-id.php
  4. Note how the page suggests that in addition to session_id(), the constant SID can also be used.

Suggested fix

Rewrite page https://www.php.net/manual/en/function.session-id.php so that it says:

Prior to PHP version 8.4.0, the constant SID could also be used to retrieve the current name and session id as a string suitable for adding to URLs. See also Session handling.

Activity

  1. added
    bugDocumentation contains incorrect information
    on Oct 12, 2026
  2. kamil-tekiela commented on Oct 13, 2026

    @kamil-tekiela
    Member

    It can still be used. There's no bug here yet. At some point in the future, it will be removed but that hasn't happened yet. I'm not sure we need to touch this just yet.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugDocumentation contains incorrect information

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions