Admin
5 months ago
Components
5 months ago
Form
1 day ago
Admin.php
4 years ago
IframeContentView.php
3 years ago
IframeView.php
1 year ago
Views.php
4 years ago
Views.php
47 lines
| 1 | <?php |
| 2 | |
| 3 | /** |
| 4 | * Admin Views Class |
| 5 | * |
| 6 | * @package Give |
| 7 | */ |
| 8 | |
| 9 | namespace Give\Views; |
| 10 | |
| 11 | defined('ABSPATH') || exit; |
| 12 | |
| 13 | /** |
| 14 | * Manages Views |
| 15 | */ |
| 16 | class Views |
| 17 | { |
| 18 | |
| 19 | /** |
| 20 | * Initialize admin and frontend views |
| 21 | */ |
| 22 | public function init() |
| 23 | { |
| 24 | // To prevent conflict on we are loading autoload.php when need for now. In future we can loaded it globally. |
| 25 | require GIVE_PLUGIN_DIR . 'vendor/autoload.php'; |
| 26 | |
| 27 | // Load admin views |
| 28 | $this->load_admin_views(); |
| 29 | } |
| 30 | |
| 31 | public function __construct() |
| 32 | { |
| 33 | // Do nothing |
| 34 | } |
| 35 | |
| 36 | public function load_admin_views() |
| 37 | { |
| 38 | // Init admin views |
| 39 | $admin = new Admin(); |
| 40 | $admin->init(); |
| 41 | } |
| 42 | |
| 43 | } |
| 44 | |
| 45 | $views = new Views(); |
| 46 | $views->init(); |
| 47 |