PHP code example of nlg / aurora

1. Go to this page and download the library: Download nlg/aurora library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

nlg / aurora example snippets




$aurora = new Nlg\Aurora\Loader([
    'root'  => getcwd() . '/../',
    'views' => '/views',
    'cache' => '/cache',
]);

$aurora->setFiles([
    '/layout.html',
]);

$aurora->setLanguageConstants([
    'hello world' => 'Hello World',
]);

$aurora->setVariables([
    'lang' => 'en',
    'title' => 'Aurora Single Page',
    'year' => date("Y")
]);

$aurora->createCache(false);

print $aurora->render("layout");

{layout}
    Hello World
{/layout}