@@ -96,11 +96,11 @@ |
||
| 96 | 96 | |
| 97 | 97 | |
| 98 | 98 | |
| 99 | - /** |
|
| 99 | + /** |
|
| 100 | 100 | * Callback to create the url, if needed, else comment out. |
| 101 | 101 | * |
| 102 | 102 | */ |
| 103 | - /* |
|
| 103 | + /* |
|
| 104 | 104 | 'create_url' => function ($url) { |
| 105 | 105 | return $this->di->get('url')->create($url); |
| 106 | 106 | }, |
@@ -76,7 +76,7 @@ discard block |
||
| 76 | 76 | * Callback tracing the current selected menu item base on scriptname |
| 77 | 77 | * |
| 78 | 78 | */ |
| 79 | - 'callback' => function ($url) { |
|
| 79 | + 'callback' => function($url) { |
|
| 80 | 80 | if ($url == $this->di->get('request')->getCurrentUrl(false)) { |
| 81 | 81 | return true; |
| 82 | 82 | } |
@@ -89,7 +89,7 @@ discard block |
||
| 89 | 89 | * menuitems that has the setting 'mark-if-parent' set to true. |
| 90 | 90 | * |
| 91 | 91 | */ |
| 92 | - 'is_parent' => function ($parent) { |
|
| 92 | + 'is_parent' => function($parent) { |
|
| 93 | 93 | $route = $this->di->get('request')->getRoute(); |
| 94 | 94 | return !substr_compare($parent, $route, 0, strlen($parent)); |
| 95 | 95 | }, |
@@ -3,11 +3,11 @@ discard block |
||
| 3 | 3 | <head> |
| 4 | 4 | <meta charset='utf-8'/> |
| 5 | 5 | <title><?=$title . $title_append?></title> |
| 6 | -<?php if(isset($favicon)): ?><link rel='icon' href='<?=$this->url->asset($favicon)?>'/><?php endif; ?> |
|
| 7 | -<?php foreach($stylesheets as $stylesheet): ?> |
|
| 6 | +<?php if (isset($favicon)): ?><link rel='icon' href='<?=$this->url->asset($favicon)?>'/><?php endif; ?> |
|
| 7 | +<?php foreach ($stylesheets as $stylesheet): ?> |
|
| 8 | 8 | <link rel='stylesheet' type='text/css' href='<?=$this->url->asset($stylesheet)?>'/> |
| 9 | 9 | <?php endforeach; ?> |
| 10 | -<?php if(isset($style)): ?><style><?=$style?></style><?php endif; ?> |
|
| 10 | +<?php if (isset($style)): ?><style><?=$style?></style><?php endif; ?> |
|
| 11 | 11 | <script src='<?=$this->url->asset($modernizr)?>'></script> |
| 12 | 12 | </head> |
| 13 | 13 | |
@@ -16,7 +16,7 @@ discard block |
||
| 16 | 16 | <div id='wrapper'> |
| 17 | 17 | |
| 18 | 18 | <div id='header'> |
| 19 | -<?php if(isset($header)) echo $header?> |
|
| 19 | +<?php if (isset($header)) echo $header?> |
|
| 20 | 20 | <?php $this->views->render('header')?> |
| 21 | 21 | </div> |
| 22 | 22 | |
@@ -27,24 +27,24 @@ discard block |
||
| 27 | 27 | <?php endif; ?> |
| 28 | 28 | |
| 29 | 29 | <div id='main'> |
| 30 | -<?php if(isset($main)) echo $main?> |
|
| 30 | +<?php if (isset($main)) echo $main?> |
|
| 31 | 31 | <?php $this->views->render('main')?> |
| 32 | 32 | </div> |
| 33 | 33 | |
| 34 | 34 | <div id='footer'> |
| 35 | -<?php if(isset($footer)) echo $footer?> |
|
| 35 | +<?php if (isset($footer)) echo $footer?> |
|
| 36 | 36 | <?php $this->views->render('footer')?> |
| 37 | 37 | </div> |
| 38 | 38 | |
| 39 | 39 | </div> |
| 40 | 40 | |
| 41 | -<?php if(isset($jquery)):?><script src='<?=$this->url->asset($jquery)?>'></script><?php endif; ?> |
|
| 41 | +<?php if (isset($jquery)):?><script src='<?=$this->url->asset($jquery)?>'></script><?php endif; ?> |
|
| 42 | 42 | |
| 43 | -<?php if(isset($javascript_include)): foreach($javascript_include as $val): ?> |
|
| 43 | +<?php if (isset($javascript_include)): foreach ($javascript_include as $val): ?> |
|
| 44 | 44 | <script src='<?=$this->url->asset($val)?>'></script> |
| 45 | 45 | <?php endforeach; endif; ?> |
| 46 | 46 | |
| 47 | -<?php if(isset($google_analytics)): ?> |
|
| 47 | +<?php if (isset($google_analytics)): ?> |
|
| 48 | 48 | <script> |
| 49 | 49 | var _gaq=[['_setAccount','<?=$google_analytics?>'],['_trackPageview']]; |
| 50 | 50 | (function(d,t){var g=d.createElement(t),s=d.getElementsByTagName(t)[0]; |
@@ -16,7 +16,8 @@ discard block |
||
| 16 | 16 | <div id='wrapper'> |
| 17 | 17 | |
| 18 | 18 | <div id='header'> |
| 19 | -<?php if(isset($header)) echo $header?> |
|
| 19 | +<?php if(isset($header)) { |
|
| 20 | + echo $header?> |
|
| 20 | 21 | <?php $this->views->render('header')?> |
| 21 | 22 | </div> |
| 22 | 23 | |
@@ -24,10 +25,13 @@ discard block |
||
| 24 | 25 | <div id='navbar'> |
| 25 | 26 | <?php $this->views->render('navbar')?> |
| 26 | 27 | </div> |
| 27 | -<?php endif; ?> |
|
| 28 | +<?php endif; |
|
| 29 | +} |
|
| 30 | +?> |
|
| 28 | 31 | |
| 29 | 32 | <div id='main'> |
| 30 | -<?php if(isset($main)) echo $main?> |
|
| 33 | +<?php if(isset($main)) { |
|
| 34 | + echo $main?> |
|
| 31 | 35 | <?php $this->views->render('main')?> |
| 32 | 36 | </div> |
| 33 | 37 | |
@@ -38,7 +42,9 @@ discard block |
||
| 38 | 42 | |
| 39 | 43 | </div> |
| 40 | 44 | |
| 41 | -<?php if(isset($jquery)):?><script src='<?=$this->url->asset($jquery)?>'></script><?php endif; ?> |
|
| 45 | +<?php if(isset($jquery)):?><script src='<?=$this->url->asset($jquery)?>'></script><?php endif; |
|
| 46 | +} |
|
| 47 | +?> |
|
| 42 | 48 | |
| 43 | 49 | <?php if(isset($javascript_include)): foreach($javascript_include as $val): ?> |
| 44 | 50 | <script src='<?=$this->url->asset($val)?>'></script> |
@@ -20,7 +20,7 @@ discard block |
||
| 20 | 20 | $di = new \Anax\DI\CDI(); |
| 21 | 21 | $service = 'failsWithException'; |
| 22 | 22 | |
| 23 | - $di->set($service, function () { |
|
| 23 | + $di->set($service, function() { |
|
| 24 | 24 | throw new \Exception("Failed creating service."); |
| 25 | 25 | }); |
| 26 | 26 | |
@@ -40,7 +40,7 @@ discard block |
||
| 40 | 40 | $di = new \Anax\DI\CDIFactoryDefault(); |
| 41 | 41 | $service = 'session'; |
| 42 | 42 | |
| 43 | - $di->set($service, function () { |
|
| 43 | + $di->set($service, function() { |
|
| 44 | 44 | $session = new \Anax\Session\CSession(); |
| 45 | 45 | $session->configure(ANAX_APP_PATH . 'config/session.php'); |
| 46 | 46 | $session->name(); |
@@ -11,7 +11,7 @@ |
||
| 11 | 11 | * |
| 12 | 12 | */ |
| 13 | 13 | define('ANAX_INSTALL_PATH', realpath(__DIR__ . '/../') . '/'); |
| 14 | -define('ANAX_APP_PATH', ANAX_INSTALL_PATH . 'app/'); |
|
| 14 | +define('ANAX_APP_PATH', ANAX_INSTALL_PATH . 'app/'); |
|
| 15 | 15 | |
| 16 | 16 | |
| 17 | 17 | |
@@ -16,10 +16,10 @@ discard block |
||
| 16 | 16 | public function providerCheck() |
| 17 | 17 | { |
| 18 | 18 | return [ |
| 19 | - [ null, ['pass'] ], |
|
| 20 | - [ 0, ['int'] ], |
|
| 21 | - [ 1, ['range' => [1, 100]] ], |
|
| 22 | - [ 100, ['range' => [1, 100]] ], |
|
| 19 | + [null, ['pass']], |
|
| 20 | + [0, ['int']], |
|
| 21 | + [1, ['range' => [1, 100]]], |
|
| 22 | + [100, ['range' => [1, 100]]], |
|
| 23 | 23 | ]; |
| 24 | 24 | } |
| 25 | 25 | |
@@ -69,10 +69,10 @@ discard block |
||
| 69 | 69 | public function providerCheckFail() |
| 70 | 70 | { |
| 71 | 71 | return [ |
| 72 | - [ null, ['fail'] ], |
|
| 73 | - [ "moped", ['int'] ], |
|
| 74 | - [ 0, ['range' => [1, 100]] ], |
|
| 75 | - [ 101, ['range' => [1, 100]] ], |
|
| 72 | + [null, ['fail']], |
|
| 73 | + ["moped", ['int']], |
|
| 74 | + [0, ['range' => [1, 100]]], |
|
| 75 | + [101, ['range' => [1, 100]]], |
|
| 76 | 76 | ]; |
| 77 | 77 | } |
| 78 | 78 | |
@@ -29,10 +29,10 @@ |
||
| 29 | 29 | |
| 30 | 30 | class MarkdownExtra extends \Michelf\_MarkdownExtra_TmpImpl { |
| 31 | 31 | |
| 32 | - ### Parser Implementation ### |
|
| 32 | + ### Parser Implementation ### |
|
| 33 | 33 | |
| 34 | - # Temporarily, the implemenation is in the _MarkdownExtra_TmpImpl class. |
|
| 35 | - # See note above. |
|
| 34 | + # Temporarily, the implemenation is in the _MarkdownExtra_TmpImpl class. |
|
| 35 | + # See note above. |
|
| 36 | 36 | |
| 37 | 37 | } |
| 38 | 38 | |
@@ -6,7 +6,7 @@ discard block |
||
| 6 | 6 | |
| 7 | 7 | # Install PSR-0-compatible class autoloader |
| 8 | 8 | spl_autoload_register(function($class){ |
| 9 | - require preg_replace('{\\\\|_(?!.*\\\\)}', DIRECTORY_SEPARATOR, ltrim($class, '\\')).'.php'; |
|
| 9 | + require preg_replace('{\\\\|_(?!.*\\\\)}', DIRECTORY_SEPARATOR, ltrim($class, '\\')).'.php'; |
|
| 10 | 10 | }); |
| 11 | 11 | |
| 12 | 12 | # Get Markdown class |
@@ -24,8 +24,8 @@ discard block |
||
| 24 | 24 | </head> |
| 25 | 25 | <body> |
| 26 | 26 | <?php |
| 27 | - # Put HTML content in the document |
|
| 28 | - echo $html; |
|
| 29 | - ?> |
|
| 27 | + # Put HTML content in the document |
|
| 28 | + echo $html; |
|
| 29 | + ?> |
|
| 30 | 30 | </body> |
| 31 | 31 | </html> |
@@ -5,8 +5,8 @@ |
||
| 5 | 5 | # you like. |
| 6 | 6 | |
| 7 | 7 | # Install PSR-0-compatible class autoloader |
| 8 | -spl_autoload_register(function($class){ |
|
| 9 | - require preg_replace('{\\\\|_(?!.*\\\\)}', DIRECTORY_SEPARATOR, ltrim($class, '\\')).'.php'; |
|
| 8 | +spl_autoload_register(function($class) { |
|
| 9 | + require preg_replace('{\\\\|_(?!.*\\\\)}', DIRECTORY_SEPARATOR, ltrim($class, '\\')) . '.php'; |
|
| 10 | 10 | }); |
| 11 | 11 | |
| 12 | 12 | # Get Markdown class |
@@ -13,9 +13,9 @@ |
||
| 13 | 13 | |
| 14 | 14 | |
| 15 | 15 | /** |
| 16 | - * Properties |
|
| 17 | - * |
|
| 18 | - */ |
|
| 16 | + * Properties |
|
| 17 | + * |
|
| 18 | + */ |
|
| 19 | 19 | private $template; // Template file or array |
| 20 | 20 | private $templateData = []; // Data to send to template file |
| 21 | 21 | private $sortOrder; // For sorting views |
@@ -16,10 +16,10 @@ |
||
| 16 | 16 | * Properties |
| 17 | 17 | * |
| 18 | 18 | */ |
| 19 | - private $template; // Template file or array |
|
| 19 | + private $template; // Template file or array |
|
| 20 | 20 | private $templateData = []; // Data to send to template file |
| 21 | - private $sortOrder; // For sorting views |
|
| 22 | - private $type; // Type of view |
|
| 21 | + private $sortOrder; // For sorting views |
|
| 22 | + private $type; // Type of view |
|
| 23 | 23 | |
| 24 | 24 | |
| 25 | 25 | |
@@ -66,7 +66,7 @@ |
||
| 66 | 66 | |
| 67 | 67 | |
| 68 | 68 | |
| 69 | - /** |
|
| 69 | + /** |
|
| 70 | 70 | * Magic method to get and create services as a method call. |
| 71 | 71 | * When created it is also stored as a parameter of this object. |
| 72 | 72 | * |