#54914 closed defect (bug) (fixed)
Deprecation warning for PHP 8.1 setcookie
| Reported by: | shenyanzhi | Owned by: | SergeyBiryukov |
|---|---|---|---|
| Priority: | normal | Milestone: | 6.1 |
| Component: | Options, Meta APIs | Version: | 4.0 |
| Severity: | normal | Keywords: | php81 has-patch |
| Cc: | Focuses: |
Description (last modified by )
Deprecated: setcookie(): Passing null to parameter #5 ($domain) of type string is deprecated in .../wp-includes/option.php on line 1109
Change History (7)
This ticket was mentioned in PR #2800 on WordPress/wordpress-develop by ocean90.
4 years ago
#3
- Keywords has-patch added
#4
@
4 years ago
- Component General → Options, Meta APIs
- Milestone Awaiting Review → 6.1
- Severity major → normal
- Version 5.9 → 4.0
SergeyBiryukov commented on PR #2800:
4 years ago
#6
Thanks for the PR! Merged in https://core.trac.wordpress.org/changeset/53490.
Note:
See TracTickets
for help on using tickets.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)
$domainshould be a string and not null to avoid the PHP 8.2 deprecation: _setcookie():Passing null to parameter #5 ($domain) of type string is deprecated_
Introduced in https://github.com/WordPress/wordpress-develop/commit/b343d482215025aa7da34c71219796361b9b4f7e / https://core.trac.wordpress.org/changeset/29478.
Trac ticket: https://core.trac.wordpress.org/ticket/54914