| 1 |
<?php |
| 2 |
/** |
| 3 |
* Declare class Config |
| 4 |
* |
| 5 |
* @package Config |
| 6 |
*/ |
| 7 |
|
| 8 |
namespace LassoLite\Classes; |
| 9 |
|
| 10 |
/** |
| 11 |
* Config |
| 12 |
*/ |
| 13 |
class Config { |
| 14 |
/** |
| 15 |
* Track whether we opened the layout wrapper in get_header(). |
| 16 |
* |
| 17 |
* @var bool |
| 18 |
*/ |
| 19 |
private static $layout_wrapper_open = false; |
| 20 |
|
| 21 |
/** |
| 22 |
* Print header html |
| 23 |
*/ |
| 24 |
public static function get_header() { |
| 25 |
self::$layout_wrapper_open = true; |
| 26 |
echo '<div class="lasso-lite-layout">'; |
| 27 |
require_once SIMPLE_URLS_DIR . '/admin/views/header.php'; |
| 28 |
} |
| 29 |
|
| 30 |
/** |
| 31 |
* Print footer html |
| 32 |
*/ |
| 33 |
public static function get_footer() { |
| 34 |
require_once SIMPLE_URLS_DIR . '/admin/views/footer.php'; |
| 35 |
if ( self::$layout_wrapper_open ) { |
| 36 |
echo '</div>'; |
| 37 |
self::$layout_wrapper_open = false; |
| 38 |
} |
| 39 |
} |
| 40 |
} |
| 41 |
|