merge framework ?NRE?

This commit is contained in:
oliver 2016-05-28 12:35:45 +02:00
commit 8353cfc7d9
5 changed files with 19 additions and 8 deletions

View file

@ -4,6 +4,8 @@ ErrorDocument 403 /www/error403.html
ErrorDocument 404 /www/error404.html ErrorDocument 404 /www/error404.html
ErrorDocument 500 /www/error500.html ErrorDocument 500 /www/error500.html
AddOutputFilterByType DEFLATE text/html text/plain text/xml text/css application/javascript text/javascript
<IfModule mod_authz_core.c> <IfModule mod_authz_core.c>

View file

@ -107,7 +107,7 @@
* @throws \nre\exceptions\ControllerNotFoundException * @throws \nre\exceptions\ControllerNotFoundException
* @param string $agentName Name of the Agent to instantiate * @param string $agentName Name of the Agent to instantiate
* @param Request $request Current request * @param Request $request Current request
* @param Response $respone Current respone * @param Response $response Current respone
* @param Logger $log Log-system * @param Logger $log Log-system
*/ */
public static function factory($agentName, Request $request, Response $response, Logger $log=null) public static function factory($agentName, Request $request, Response $response, Logger $log=null)
@ -165,7 +165,7 @@
* @throws \nre\exceptions\ControllerNotValidException * @throws \nre\exceptions\ControllerNotValidException
* @throws \nre\exceptions\ControllerNotFoundException * @throws \nre\exceptions\ControllerNotFoundException
* @param Request $request Current request * @param Request $request Current request
* @param Response $respone Current response * @param Response $response Current response
* @param Logger $log Log-system * @param Logger $log Log-system
*/ */
protected function __construct(Request $request, Response $response, Logger $log=null) protected function __construct(Request $request, Response $response, Logger $log=null)
@ -502,7 +502,7 @@
* *
* @param array $subAgent Original (Sub-) Agent * @param array $subAgent Original (Sub-) Agent
* @param Request $request Current request * @param Request $request Current request
* @param Excepiton $exception Occurred exception * @param Exception $exception Occurred exception
* @return array InlineError-SubAgent * @return array InlineError-SubAgent
*/ */
private function errorInline($subAgent, $request, $exception) private function errorInline($subAgent, $request, $exception)

View file

@ -27,7 +27,7 @@
* Load a class. * Load a class.
* *
* @throws \nre\exceptions\ClassNotFoundException * @throws \nre\exceptions\ClassNotFoundException
* @param string $className Name of the class to load * @param string $fullClassName Name of the class to load
*/ */
public static function load($fullClassName) public static function load($fullClassName)
{ {

View file

@ -275,21 +275,21 @@
*/ */
private function detectRequest() private function detectRequest()
{ {
// URL ermitteln // Get URL
$url = isset($_GET) && array_key_exists('url', $_GET) ? $_GET['url'] : ''; $url = isset($_GET) && array_key_exists('url', $_GET) ? $_GET['url'] : '';
$url = trim($url, '/'); $url = trim($url, '/');
// Routes anwenden // Apply routes
$url = $this->applyRoutes($url, $this->routes); $url = $this->applyRoutes($url, $this->routes);
// URL splitten // Split URL
$params = explode('/', $url); $params = explode('/', $url);
if(empty($params[0])) { if(empty($params[0])) {
$params = array(); $params = array();
} }
// Parameter speichern // Save parameters
$this->params = $params; $this->params = $params;
} }

View file

@ -1,3 +1,12 @@
<IfModule mod_expires.c>
AddType text/javascript .js
ExpiresActive on
ExpiresByType image/png "access plus 1 week"
ExpiresByType image/jpeg "access plus 1 week"
ExpiresByType text/javascript "access plus 1 week"
</IfModule>
<IfModule mod_rewrite.c> <IfModule mod_rewrite.c>
RewriteEngine On RewriteEngine On