首页 WordPress函数大全 get_file_data()

get_file_data()

2020-05-01 / 3326阅 / 悠然

如何你看完本文还不知道如何使用该函数,可以联系我定制视频教程,50元/个函数,学不会全额退款

get_file_data( string $file, array $default_headers, string $context = '' )

Retrieve metadata from a file.

描述

Searches for metadata in the first 8 KB of a file, such as a plugin or theme. Each piece of metadata must be>

参数

$file

(string)
(Required)
Absolute path to the file.

$default_headers

(array)
(Required)
List of headers, in the format array( 'HeaderKey' => 'Header Name' ).

$context

(string)
(Optional)
If specified adds filter hook 'extra_$context_headers'.

Default value: ''

返回

(string[]) Array of file header values keyed by header name.

大家谈论
    我的见解