Yes you can
"laravel/framework": "5.0#commit-hash-here"
Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.
Yes you can
"laravel/framework": "5.0#commit-hash-here"
@Killswitch this is extremely useful if one want's to develop app on L5 right now!
Let me think... I am using the latest version, it's not hard to handle, just add protected $userResolver; to Illuminate\Http\Request. And format your errors something like:
@if(Session::has('errors'))
<div class="alert alert-danger">
<ul>
@foreach(Session::get('errors')->all() as $error)
<li>{{ $error }}</li>
@endforeach
</ul>
</div>
@endif
Also I was reading something about annotations, I don't use it at the moment just write my routers like this:
<?php
# REGISTRATION
get('register', ['middleware' => 'guest', 'as' => 'register', 'uses' => 'RegistrationsController@create']);
post('register', ['middleware' => 'guest', 'as' => 'register.store', 'uses' => 'RegistrationsController@store']);
# LOGIN
get('login', ['middleware' => 'guest', 'as' => 'login', 'uses' => 'SessionsController@create']);
post('login', ['middleware' => 'guest', 'as' => 'login.store', 'uses' => 'SessionsController@store']);
get('logout', ['as' => 'logout', 'uses' => 'SessionsController@destroy']);
# RESET PASSWORD
get('login/reset', ['as' => 'reminder.create', 'uses' => 'RemindersController@create']);
post('login/reset', ['as' => 'reminder.store', 'uses' => 'RemindersController@store']);
get('password/reset/{token}', ['as' => 'password.show', 'uses' => 'RemindersController@show']);
put('password/reset', ['as' => 'password.update', 'uses' => 'RemindersController@update']);
Hope this will help someone :-)
i give up l5 until offically release.
Yes, I'm coming to the same conclusion. Nice as all these L5 goodies are, you end up spending more time debugging each update than you do writing your app. Wish I could afford the time, but I need to resist and go back to L4.
These latest changes with middleware etc, while interesting are just creating a mess in terms of code as I try and get round the 'not so finished' sate L5 is in. Guess I'll have to wait.
@keevitaja indeed, it's what I use. Then I take my time and update instead of composer update breaking everything when I add a new package to my project.
@Killswitch and @keevitaja, problem with the approach that @Killswitch is referring to you come stuck in the middle, I tried that also, biggest problem was, when I installed a new project thinks didn't work (examples: filters => middleware, controller), and in my opinion if something doesn't work, you want to try to get it working, it's time consuming I know that, but it is also giving me the time to learn a lot about what @TaylorOtwell is developing.
Don't think about problems, but think about (mind breaking) challenges. :-)
@Raymond such is the life when you're using bleeding edge. ;)
Curious... Where are you guys putting your global View::share functions? I'm having to put them in my controllers for them to work correctly at the moment. What is a better solution?
@mrlilley how about in a ServiceProvider? :-) I did put this in my RouteServiceProvider $this->app['view']->share('abc','def');
I think you guys all try hard to be on top on what is actually changing in L5, and I respect that. But please do try to not criticize too much the fundamental changes arising at the very minute they pop out.
Being writing in this forum means that you care in some way about Laravel, and I really think we shouldn't impact too much Taylor's decisions at this point. Saying some really bad stuff against one or another feature while the project is not even in some kind of Beta is not the way you are gonna make things change. We'll have plenty of time to discuss those features when everyone uses them in good conditions.
When I first discovered Laravel I was amazed by they way you could easily handle a lot of stuff that were a pain in the *** to work with in other frameworks. I think that Taylor still considers Laravel has it's baby, and in that regard, he will keep focusing on what he does the best: coding a nice, clean and usable framework, and surely this involves changes.
I myself have had some bad experiences with annotations, but I am far from being reluctant to use them tomorrow if they find themselves a nice and clean way into the framework.
@RayRutjes Totally agree with you and thanks for stating it!
I opened the topic just to get more insight in why Taylor removed Controller Class, nothing more nothing less. Others kinda have hijacked my topic and started a discussion on several of the Laravel changes and started to express what they did and did not like.
Folks, remember, Taylor did us a favor by developing L5 in public, he could have chosen to do it in private and only let a few others pre-alpha test L5. So don't start commenting on features if you like or do not like.
Use this and other forums as spot to help you or figure out what and why something changed (just like I intended with this topic).
Let Taylor do his magic and don't limit him by commenting on his choices until he releases an RC.
Add this comment before a function in your controller
/**
* @Get("/login")
* @Middleware("guest")
*/
public function getLogin()
{
return view('auth.login');
}
or
/**
* @Get("/login", as="login", middleware="guest")
*/
Run this command
php artisan route:scan
Output : storage/framework/routes.scanned.php
If anyone else is having problems with route:scan on windows, it doesn't work! It just produces an empty routes.scanned.php file. See https://github.com/laravel/framework/issues/5997.
To bypass this, you can run route:scan through your VM.
Please or to participate in this conversation.