1
我有一個關於葉模板引擎的問題。葉模板中的訪問會話
如何訪問Leaf模板中的Session值? 例如,要通過Laravel中的Flash消息進行循環:https://laravel.com/docs/5.3/redirects#redirecting-with-flashed-session-data
我無法找到解決方案來完成此操作。
在此先感謝
我有一個關於葉模板引擎的問題。葉模板中的訪問會話
如何訪問Leaf模板中的Session值? 例如,要通過Laravel中的Flash消息進行循環:https://laravel.com/docs/5.3/redirects#redirecting-with-flashed-session-data
我無法找到解決方案來完成此操作。
在此先感謝
蒸汽的最新版本的默認渲染視圖時包括request
。因此,您將可以使用
#(request.session) // in the latest version of Vapor
這對我在1.3.6版本中不起作用!?任何幫助 – Timo
@Timo,請確保您將Vapor的版本更新到最新的穩定版本。 –