跳转到主要内容

包括软件许可证

大多数 WordPress 插件都是在GPL下发布的,这与WordPress 本身使用的许可证相同 。但是,还有其他兼容选项可用。最好清楚地表明您的插件使用的许可证。

“标头要求”部分中,我们简要提到了如何在插件标头注释中指示插件的许可证。另一种常见且鼓励的做法是在主插件文件顶部附近放置许可证块注释(与具有插件标头注释的文件相同)。

该许可证块注释通常如下所示:

/*
{Plugin Name} is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 2 of the License, or
any later version.

{Plugin Name} is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with {Plugin Name}. If not, see {URI to Plugin License}.
*/