Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Request::createFromGlobals() doesn't work #59533

@starline

Description

@starline

Symfony version(s) affected

6.4.17

Description

Image

php version: 8.1.7

$_GET is empty
$_POST is empty

How to reproduce

i have HTTP 500 Internal Server Error when try to get Request by Request::createFromGlobals()

Possible Solution

add additional type (array|null) of variables $query and $query and $cookies

like that:
private static function createRequestFromFactory(array|null $query = [], array|null $request = [], array $attributes = [], array $cookies = [], array $files = [], array $server = [], $content = null): stat

Additional Context

No response

Metadata

Metadata

Assignees

No one assigned

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions