• Developer New

    Friday, March 24, 2017

    how to use Sessions in laravel

    Session::get('key');
    Session::get('key', 'default');
    Session::get('key', function(){ return 'default'; });
    Session::put('key', 'value');
    // Push a value into an array in the sessionSession::push('foo.bar','value');
    Session::all();
    Session::has('key');
    Session::forget('key');
    Session::flush();
    Session::regenerate();
    Session::flash('key', 'value');
    Session::reflash();
    Session::keep(['key1', 'key2']);

    No comments:

    Post a Comment

    Fashion

    Beauty

    Travel