auth_cookie_malformed
云策文档标注
概述
auth_cookie_malformed 是一个 WordPress 钩子,当认证 cookie 格式错误时触发。它允许开发者处理 cookie 验证失败的情况。
关键要点
- 钩子名称:auth_cookie_malformed
- 触发条件:认证 cookie 格式错误时
- 参数:$cookie(格式错误的认证 cookie 字符串)和 $scheme(认证方案,如 'auth'、'secure_auth' 或 'logged_in')
- 相关函数:wp_validate_auth_cookie() 用于验证认证 cookie
- 引入版本:WordPress 2.7.0
原文内容
Fires if an authentication cookie is malformed.
Parameters
$cookiestring-
Malformed auth cookie.
$schemestring-
Authentication scheme. Values include
'auth','secure_auth', or'logged_in'.
Source
do_action( 'auth_cookie_malformed', $cookie, $scheme );
Changelog
| Version | Description |
|---|---|
| 2.7.0 | Introduced. |