wpseek.com
WordPress开发者和主题制作者的搜索引擎



request_filesystem_credentials › WordPress过滤钩子

Since4.6.0
已弃用n/a
apply_filters( 'request_filesystem_credentials', '', $form_post, $type, $error, $context, $extra_fields, $allow_relaxed_file_ownership )
参数: (7)
  • (mixed) $credentials Credentials to return instead. Default empty string.
    Required: Yes
  • (string) $form_post The URL to post the form to.
    Required: Yes
  • (string) $type Chosen type of filesystem.
    Required: Yes
  • (bool|WP_Error) $error Whether the current request has failed to connect, or an error object.
    Required: Yes
  • (string) $context Full path to the directory that is tested for being writable.
    Required: Yes
  • (array) $extra_fields Extra POST fields.
    Required: Yes
  • (bool) $allow_relaxed_file_ownership Whether to allow Group/World writable.
    Required: Yes
定义在:
文档:

Filters the filesystem credentials.

Returning anything other than an empty string will effectively short-circuit output of the filesystem credentials form, returning that value instead.

A filter should return true if no filesystem credentials are required, false if they are required but have not been provided, or an array of credentials if they are required and have been provided.





源码

$req_cred = apply_filters( 'request_filesystem_credentials', '', $form_post, $type, $error, $context, $extra_fields, $allow_relaxed_file_ownership );