I am rewriting a plain php site to use Lumen for a customer to allow a simple knowledgebase with no outside access to posting, 5 pages of HTML and a contact form. So instead of hosting full Laravel, I wanted to use Lumen.
I ran into a few issues. I enabled Facades and Eloquent, it looked like it was going to be okay. However a few problems came up.
I cannot seem to use the old() function in views.
I cannot seem to use the session() function in views.
I cannot seem to use the CSRF function in views either (for contact form).
I am probably also going to have problems sending e-mail to a predefined [email protected] email.
What steps should I take to make this work? I feel its a bit over the top to go full out Laravel with this tiny project.
the old() function isn't even in the documentation and with your 2. and 4. point I'm not sure on how to. Anyway, even Laravel seems a bit over the top for your project, I would use it in your case. It would be finished just so much quicker. (I'm more familiar with Laravel then with Lumen).
I ended up coding alternatives for this mostly. I didn't really need the old function. Instead of sessions I use ajax for requests and display errors using javascript on the page so Lumens Json output wasn't a problem.
CSRF token wasn't really a requirement either, I added rechapta to sort any cross site scripting and bots.
Emails was sorted using various methods. But mainly require the mailer package, create a service for it in the AppServiceProvider (enable in app.php), create a mail.php and service.php file using laravel's as templates.