PluginProbe
Friends / 2.8.9
Friends v2.8.9
4.3.2 4.3.1 4.3.0 4.2.2 4.2.1 4.2.0 4.1.0 2.7.4 2.7.5 2.7.6 2.7.7 2.7.8 2.7.9 2.8.0 2.8.1 2.8.2 2.8.3 2.8.4 2.8.5 2.8.6 2.8.7 2.8.8 2.8.9 2.9.0 2.9.1 All 88 releases
friends / includes / class-template-loader.php

class-template-loader.php in Friends 2.8.9, at includes/class-template-loader.php

73 lines 1.6 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 /**
3 * Template Loader for Plugins.
4 *
5 * @package Gamajo_Template_Loader
6 * @author Gary Jones
7 * @link http://github.com/GaryJones/Gamajo-Template-Loader
8 * @copyright 2013 Gary Jones
9 * @license GPL-2.0-or-later
10 * @version 1.3.1
11 */
12
13 namespace Friends;
14
15 if ( ! class_exists( '\Gamajo_Template_Loader_1_4_0' ) ) {
16 require __DIR__ . '/class-gamajo-template-loader-1-4-0.php';
17 }
18 /**
19 * Template loader.
20 *
21 * Originally based on functions in Easy Digital Downloads (thanks Pippin!).
22
23 * @package Friends
24 * @author Alex Kirk
25 */
26 class Template_Loader extends \Gamajo_Template_Loader_1_4_0 {
27 /**
28 * Prefix for filter names.
29 *
30 * @since 1.0.0
31 *
32 * @var string
33 */
34 protected $filter_prefix = 'friends';
35
36 /**
37 * Directory name where custom templates for this plugin should be found in the theme.
38 *
39 * For example: 'your-plugin-templates'.
40 *
41 * @since 1.0.0
42 *
43 * @var string
44 */
45 protected $theme_template_directory = 'friends';
46
47 /**
48 * Reference to the root directory path of this plugin.
49 *
50 * Can either be a defined constant, or a relative reference from where the subclass lives.
51 *
52 * e.g. YOUR_PLUGIN_TEMPLATE or plugin_dir_path( dirname( __FILE__ ) ); etc.
53 *
54 * @since 1.0.0
55 *
56 * @var string
57 */
58 protected $plugin_directory = FRIENDS_PLUGIN_DIR;
59
60 /**
61 * Directory name where templates are found in this plugin.
62 *
63 * Can either be a defined constant, or a relative reference from where the subclass lives.
64 *
65 * e.g. 'templates' or 'includes/templates', etc.
66 *
67 * @since 1.1.0
68 *
69 * @var string
70 */
71 protected $plugin_template_directory = 'templates';
72 }
73