Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- In routes:
- Route::group(array('before' => 'auth', 'after' => 'no-cache'), function()
- {
- Route::get('dashboard', array('as' => 'getDashboard', 'uses' => 'DashboardController@getIndex'));
- Route::get('logout', array('as' => 'getLogout', 'uses' => 'LoginController@getLogout'));
- Route::group(array('prefix' => 'users'), function()
- {
- Route::get('users', array('as' => 'getUsers', 'uses' => 'UsersController@getIndex', 'before' => 'hasAccess:users.index'));
- });
- });
- In filters:
- Route::filter('no-cache',function($route, $request, $response){
- $response->headers->set('Cache-Control','nocache, no-store, max-age=0, must-revalidate');
- $response->headers->set('Pragma','no-cache');
- $response->headers->set('Expires','Fri, 01 Jan 1990 00:00:00 GMT');
- });
- another way:
- http://stackoverflow.com/questions/49547/making-sure-a-web-page-is-not-cached-across-all-browsers
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement