PHP Classes

File: src/start.php

Recommend this page to a friend!
  Classes of Thierry Feuzeu   Polr Admin Dashboard   src/start.php   Download  
File: src/start.php
Role: Example script
Content type: text/plain
Description: Example script
Class: Polr Admin Dashboard
Another admin dashboard for the Polr URL shortener
Author: By
Last change:
Date: 5 years ago
Size: 1,330 bytes


Class file image Download

 * start.php -
 * This file is automatically loaded by the Composer autoloader
 * The package is initialized here.

function polr_admin_init()
// Read config file
$jaxon = jaxon();
$sentry = $jaxon->sentry();
$sConfigFile = __DIR__ . '/../config/jaxon.php';
$xAppConfig = $jaxon->readConfigFile($sConfigFile, 'lib', 'app');

// Set the class initializer
$sentry->addClassInitializer('Lagdo\Polr\Admin\App', function($instance) {
$polr = jaxon()->sentry()->getPackage('polr.admin');
// Init the Jaxon class instance

// Register the Datatables row renderer
$sentry->registerPackage('dt.renderer', function() {
        return new \
// Register the Polr Admin
$sentry->registerPackage('polr.admin', function() {
$dtRenderer = jaxon()->sentry()->getPackage('dt.renderer');
        return new \

// Register an instance of the Datatables plugin
jaxon_register_plugin(new \Lagdo\Polr\Admin\Ext\Datatables\Plugin());

// Initialize the package