PluginProbe
Datafeedr API / 1.0.125
Datafeedr API v1.0.125
1.4.3 1.4.2 1.0.125 1.0.13 1.0.14 1.0.15 1.0.16 1.0.17 1.0.18 1.0.19 1.0.2 1.0.20 1.0.21 1.0.22 1.0.23 1.0.24 1.0.25 1.0.26 1.0.27 1.0.28 1.0.29 1.0.3 1.0.30 1.0.31 1.0.32 All 182 releases
datafeedr-api / Wuwei / Framework / Templates / Generic.php

Generic.php in Datafeedr API 1.0.125, at Wuwei/Framework/Templates/Generic.php

38 lines 775 B
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php namespace Datafeedr\Api\Wuwei\Templates;
2
3 /**
4 * Template_Generic class.
5 *
6 * Extends the Template_Abstract class. Handles the get_file() and get_data() requests.
7 *
8 * @since 2.0.0
9 */
10 class Generic extends Template {
11
12 /**
13 * Returns full path to generic template file.
14 *
15 * @since 2.0.0
16 *
17 * @return string Full path to template file.
18 */
19 public function get_file() {
20 $ds = \DIRECTORY_SEPARATOR;
21 $path = realpath( __DIR__ . '/..' ) . $ds . 'Views' . $ds . 'generic' . $ds; // Requires PHP 5.3+
22 $file = $path . $this->name;
23
24 return $file;
25 }
26
27 /**
28 * Returns the array of data to use in our templates.
29 *
30 * @since 2.0.0
31 *
32 * @return array The data for use in our template file.
33 */
34 public function get_data() {
35 return $this->data;
36 }
37 }
38