Last active
July 17, 2022 13:20
-
-
Save frontend-coder/ba155dc496e44c372a4bc5209f3efad9 to your computer and use it in GitHub Desktop.
38. Як створити ядро-плагин для теми #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
Створити каталог в папке plugins | |
Назвати його domain-core | |
Створити в ньому файл domain-core | |
До нього підключити робочі файли | |
<?php | |
/* | |
Plugin Name: domein core | |
Plugin URI: https://www.facebook.com/frontendercode/ | |
Description: Used for support my personal Wordpress theme. | |
Version: 4.2.1 | |
Author: Vasilchenko Ihor | |
Author URI: https://www.facebook.com/frontendercode/ | |
License: GPLv2 or later | |
Text Domain: domain | |
*/ | |
if(!function_exists('add_action')) { | |
echo 'Hi there I\'m just a plugin, not much I can do when called directly.'; | |
exit; | |
} | |
require plugin_dir_path( __FILE__ ) . 'inc/widget-about.php'; | |
require plugin_dir_path( __FILE__ ) . 'inc/metaboxes.php'; | |
require plugin_dir_path( __FILE__ ) . 'inc/acf.php'; | |
require plugin_dir_path( __FILE__ ) . 'inc/custom_post_type.php'; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment