问题
- In laravel blade view i am doing
{{session_start()}}
and it is echoing out a why is that and how i fix it? i heard that laravel has session management already built in and you dont need session_start(). is this true? because when i remove session_start() and try to return a session value it gives me error of undefined value. if it is true. how can i achieve this without a session start. source for this information.
blade.php method outputting it's result to the form
回答1:
No need to write {{session_start()}}
From doc:
There are two primary ways of working with session data in Laravel: the global session helper and via a Request instance
https://laravel.com/docs/5.1/session
来源:https://stackoverflow.com/questions/39960209/laravel-session-start-returning-a-1