public function __construct() { parent::__construct(); ssl::force_ssl(); meta::set_keywords('Daily Journal, Free Journal, Private Diary, Private Journal, Free Online Journal, Online Journaling, Write Messages, My Diary, Secure Diary, Secure Journal, Journal, Diary'); meta::set_description('Keep a free online journal or diary to remember events in your life. Secure, simple and free. Access from anywhere.'); // Add Analytics to the page, except on journal pages if ($this->model_name != 'journal') { layout::add(View::factory('shared/analytics'), 'footer'); } }
/** * Require administrator login * @Developer brandon * @Date Oct 11, 2010 */ public function __construct() { parent::__construct(); $this->template = View::factory('layouts/admin'); meta::set_title(store::name() . ' | Admin | ' . ucwords(Router::$controller)); // Set the route for updating and creating files Kohana::config_set('routes.base_crud_route', 'admin/'); // Require an admin login if we are in production. if (IN_PRODUCTION) { customer::require_admin_login(); } ORM::factory('audit_trail')->create(array('user_id' => customer::current(), 'store_id' => store::get(), 'controller' => Router::$controller, 'method' => Router::$method, 'object_id' => $this->input->post('id'))); }
/** * Set the view to use * @developer Brandon Hansen * @date Oct 13, 2010 */ public function __construct() { parent::__construct(); $this->template = View::factory('themes/' . theme::get() . '/theme'); }