-
Notifications
You must be signed in to change notification settings - Fork 0
/
functions.php
41 lines (30 loc) · 966 Bytes
/
functions.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
<?php
// Exit if accessed directly
defined('ABSPATH') || exit;
// includes
$techflyte_includes = array(
'/setup.php',
'/includes/front/enqueue.php',
'/includes/customizer.php',
'includes/cpts/team/team-cpt.php',
'includes/cpts/faq/faq-cpt.php',
'includes/cpts/benefits/benefits-cpt.php',
'includes/cpts/partner/partner-cpt.php',
);
foreach($techflyte_includes as $file){
require_once(get_theme_file_path($file));
}
// hook
$techflyte_init_hooks = array(
'tech_team_cpt_init',
'tech_faq_cpt_init',
'tech_benefits_cpt_init',
'tech_partner_cpt_init',
);
foreach($techflyte_init_hooks as $flyte_hook){
add_action('init',$flyte_hook);
}
add_action( 'wp_enqueue_scripts', 'tech_enqueue_files' );
add_action( 'after_setup_theme', 'tech_setup_theme');
add_action( 'customize_register', 'mytheme_customize_register');
add_action('after_switch_theme','my_rewrite_flush');