|
@@ -161,4 +161,40 @@ $bundles = require path('app').'bundles'.EXT;
|
|
|
foreach ($bundles as $bundle => $config)
|
|
|
{
|
|
|
Bundle::register($bundle, $config);
|
|
|
-}
|
|
|
+}
|
|
|
+
|
|
|
+/*
|
|
|
+|--------------------------------------------------------------------------
|
|
|
+| Magic Quotes Strip Slashes
|
|
|
+|--------------------------------------------------------------------------
|
|
|
+|
|
|
|
+| Even though "Magic Quotes" are deprecated in PHP 5.3.x, they may still
|
|
|
+| be enabled on the server. To account for this, we will strip slashes
|
|
|
+| on all input arrays if magic quotes are enabled for the server.
|
|
|
+|
|
|
|
+*/
|
|
|
+
|
|
|
+if (magic_quotes())
|
|
|
+{
|
|
|
+ $magics = array(&$_GET, &$_POST, &$_COOKIE, &$_REQUEST);
|
|
|
+
|
|
|
+ foreach ($magics as &$magic)
|
|
|
+ {
|
|
|
+ $magic = array_strip_slashes($magic);
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+/*
|
|
|
+|--------------------------------------------------------------------------
|
|
|
+| Create The HttpFoundation Request
|
|
|
+|--------------------------------------------------------------------------
|
|
|
+|
|
|
|
+| Laravel uses the HttpFoundation Symfony component to handle the request
|
|
|
+| and response functionality for the framework. This allows us to not
|
|
|
+| worry about that boilerplate code and focus on what matters.
|
|
|
+|
|
|
|
+*/
|
|
|
+
|
|
|
+use Symfony\Component\HttpFoundation\LaravelRequest as RequestFoundation;
|
|
|
+
|
|
|
+Request::$foundation = RequestFoundation::createFromGlobals();
|