试试这个
1) 首先为插件元添加新标题:
add_filter(\'extra_plugin_headers\', \'add_extra_headers\');
function add_extra_headers(){
return array(\'Author2\');
}
2)下一步过滤输出上的作者元行:
add_filter(\'plugin_row_meta\', \'filter_authors_row_meta\', 1, 4);
function filter_authors_row_meta($plugin_meta, $plugin_file, $plugin_data, $status ){
if(empty($plugin_data[\'Author\'])){
return $plugin_meta;
}
if ( !empty( $plugin_data[\'Author2\'] ) ) {
$plugin_meta[1] = $plugin_meta[1] . \', \' . $plugin_data[\'Author2\'];
}
return $plugin_meta;
}
3)创建插件时,添加新的元键和值。。示例:
/**
* Plugin Name: My Plugin
* Plugin URI:http://myplugin.com
* Description: My Plugin is the Best!
* Version: 1.0
* Author: <a href="#">Author One Name</a>
* Author2: <a href="#">Author Two Name</a>
*/