Support the ongoing development of Laravel.io →
posted 9 years ago
Session
Last updated 1 year ago.
0

Ok, I got it fixed. I forgot the namespace...

Last updated 1 year ago.
0

Hey nicholascc, what do you mean you forgot the namespace? I'm getting the same error when trying to use Session::flash from a controller (also L5). Any help?

0

thetimmyc said:

Hey nicholascc, what do you mean you forgot the namespace? I'm getting the same error when trying to use Session::flash from a controller (also L5). Any help?

add use Session; line below the opening php tag in your controller to use Session class in laravel 5.

Last updated 9 years ago.
0

Sign in to participate in this thread!

Eventy

Your banner here too?

nicholascc nicholascc Joined 14 Nov 2014

Moderators

We'd like to thank these amazing companies for supporting us

Your logo here?

Laravel.io

The Laravel portal for problem solving, knowledge sharing and community building.

© 2024 Laravel.io - All rights reserved.