Last active
November 17, 2022 01:17
-
-
Save kobaatsu/e7d7b17c9bed6ac7f7c5383b663c4461 to your computer and use it in GitHub Desktop.
プラグイン一覧 #wordpress
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!-- https://nelog.jp/get_plugins --> | |
<textarea cols="16" rows="10"> | |
<?php | |
$all = ''; | |
//plugin.phpを読み込む | |
include_once ABSPATH . 'wp-admin/includes/plugin.php'; | |
$plugins = get_plugins(); | |
if (!empty($plugins)) { | |
$all .= '有効化済みのプラグイン:' . PHP_EOL; | |
foreach ($plugins as $path => $plugin) { | |
if (is_plugin_active($path)) { | |
$all .= $plugin['Name']; | |
$all .= "\n" . $plugin['PluginURI']; | |
$all .= "\n" . $plugin['Version'] . PHP_EOL; | |
} | |
} | |
echo $all; | |
} | |
?> | |
</textarea> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment