-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathfunctions.php
More file actions
executable file
·137 lines (110 loc) · 4.24 KB
/
Copy pathfunctions.php
File metadata and controls
executable file
·137 lines (110 loc) · 4.24 KB
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
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
<?php
// Theme support options
require_once(get_template_directory().'/assets/functions/theme-support.php');
// WP Head and other cleanup functions
require_once(get_template_directory().'/assets/functions/cleanup.php');
// Register scripts and stylesheets
require_once(get_template_directory().'/assets/functions/enqueue-scripts.php');
// Register custom menus and menu walkers
require_once(get_template_directory().'/assets/functions/menu.php');
require_once(get_template_directory().'/assets/functions/menu-walkers.php');
// Register sidebars/widget areas
require_once(get_template_directory().'/assets/functions/sidebar.php');
// Makes WordPress comments suck less
require_once(get_template_directory().'/assets/functions/comments.php');
// Replace 'older/newer' post links with numbered navigation
require_once(get_template_directory().'/assets/functions/page-navi.php');
// Adds support for multiple languages
require_once(get_template_directory().'/assets/translation/translation.php');
// Adds site styles to the WordPress editor
//require_once(get_template_directory().'/assets/functions/editor-styles.php');
// Related post function - no need to rely on plugins
// require_once(get_template_directory().'/assets/functions/related-posts.php');
// Use this as a template for custom post types
// require_once(get_template_directory().'/assets/functions/custom-post-type.php');
// Customize the WordPress login menu
// require_once(get_template_directory().'/assets/functions/login.php');
// Customize the WordPress admin
// require_once(get_template_directory().'/assets/functions/admin.php');
//Include Kirki framework
include_once( dirname(__FILE__) . '/vendor/kirki/kirki.php' );
require_once(get_template_directory().'/assets/functions/theme_opts.php');
function pftk_custom_breadcrumb() {
if(!is_home()) {
echo '<nav aria-label="You are here:" role="navigation">';
echo '<ul class="breadcrumbs">';
echo '<li><a href="'.home_url().'">Home</a></li>';
if (is_single()) {
echo '<li>';
the_category(', ');
echo '</li>';
if (is_single()) {
echo '<li>';
the_title();
echo '</li>';
}
} elseif (is_category()) {
echo '<li>';
single_cat_title();
echo '</li>';
} elseif (is_page()) {
echo '<li>';
the_title();
echo '</li>';
} elseif (is_tag()) {
echo '<li>Tag: ';
single_tag_title();
echo '</li>';
} elseif (is_day()) {
echo'<li>Archive for ';
the_time('F jS, Y');
echo'</li>';
} elseif (is_month()) {
echo'<li>Archive for ';
the_time('F, Y');
echo'</li>';
} elseif (is_year()) {
echo'<li>Archive for ';
the_time('Y');
echo'</li>';
} elseif (is_author()) {
echo'<li>Author Archives';
echo'</li>';
} elseif (isset($_GET['paged']) && !empty($_GET['paged'])) {
echo '<li>Blog Archives';
echo'</li>';
} elseif (is_search()) {
echo'<li>Search Results';
echo'</li>';
}
echo '</ul>';
echo '</nav>';
}
}
if ( ! isset( $content_width ) ) {
$content_width = 600;
}
//add tgm plugin
require_once get_template_directory() . '/vendor/tgm-plugin-activation/class-tgm-plugin-activation.php';
add_action( 'tgmpa_register', 'pftk_register_required_plugins' );
function pftk_register_required_plugins() {
$plugins = array(
array(
'name' => 'PressForward',
'slug' => 'pressforward',
'required' => false,
),
);
$config = array(
'id' => 'pressforward-turnkey-theme', // Unique ID for hashing notices for multiple instances of TGMPA.
'default_path' => '', // Default absolute path to bundled plugins.
'menu' => 'tgmpa-install-plugins', // Menu slug.
'has_notices' => true, // Show admin notices or not.
'dismissable' => true, // If false, a user cannot dismiss the nag message.
'dismiss_msg' => '', // If 'dismissable' is false, this message will be output at top of nag.
'is_automatic' => false, // Automatically activate plugins after installation or not.
'message' => '', // Message to output right before the plugins table.
);
tgmpa($plugins, $config);
}
?>