1111|
1212*/
1313
14- $ app ['debug ' ] = false ;
14+ $ app ['debug ' ] = false ;
15+
16+ /*
17+ |--------------------------------------------------------------------------
18+ | Register The Illuminate Filesystem Manager
19+ |--------------------------------------------------------------------------
20+ |
21+ | The Illuminate file system provides a nice abstraction over the file
22+ | system, which makes testing code that gets or puts files on disk
23+ | much easier, since the file systems can easily be mocked out.
24+ |
25+ */
26+
27+ $ app ['files ' ] = $ app ->share (function ()
28+ {
29+ return new Illuminate \Filesystem ;
30+ });
31+
32+ /*
33+ |--------------------------------------------------------------------------
34+ | Register The Illuminate Event Dispatcher
35+ |--------------------------------------------------------------------------
36+ |
37+ | The Illuminate event dispatcher provides a simpler, yet powerful way
38+ | to build de-coupled systems using events, including queueing and
39+ | flushing events. We'll go ahead and register a shared object.
40+ |
41+ */
42+
43+ $ app ['events ' ] = $ app ->share (function ()
44+ {
45+ return new Illuminate \Events \Dispatcher ;
46+ });
47+
48+ /*
49+ |--------------------------------------------------------------------------
50+ | Register The Illuminate Encrypter
51+ |--------------------------------------------------------------------------
52+ |
53+ | The Illuminate encrypter service provides a nice, convenient wrapper
54+ | around the mcrypt encryption library. By default, strong AES-256
55+ | encryption is provided out of the box. Just be sure to change
56+ | your application key, as strong encryption depends on it!
57+ |
58+ */
59+
60+ $ app ['encrypter.key ' ] = 'YourSecretKey ' ;
61+
62+ $ app ['encrypter ' ] = $ app ->share (function () use ($ app )
63+ {
64+ $ key = $ app ['encrypter.key ' ];
65+
66+ return new Illuminate \Encrypter (MCRYPT_RIJNDAEL_256 , MCRYPT_MODE_CBC , $ key );
67+ });
68+
69+ /*
70+ |--------------------------------------------------------------------------
71+ | Register The Illuminate Session
72+ |--------------------------------------------------------------------------
73+ |
74+ | The Illuminate session library provides a variety of simple, clean
75+ | session drivers for use by your application. By default, we'll
76+ | use the light Cookie driver for convenience and simplicity.
77+ |
78+ */
79+
80+ $ app ['session ' ] = $ app ->share (function () use ($ app )
81+ {
82+ return new Illuminate \Session \CookieStore ($ app ['encrypter ' ]);
83+ });
0 commit comments