I am upgrading from 4.2 directly to 5.1 and run into problems with the Html and Form classes.
I followed the upgrade notes, and did
My problem is solved, but the actual cause is still unknown. I have created a completely new laravel install and copied my source (all of it). The new application worked right away (after installing illuminate/html).
So you think I did something wrong with packages? That's what I thought, and then I did a diff on the two directories, only to find out they were identical. So it's a real mystery.
So, now everything is working, I simply renamed my new application and can continue.
I do know at some point I probably had both the collective and the illuminate versions of the HTML package installed. That's what most likely corrupted everything.
edit config/app.php
add this into providers
Collective\Html\HtmlServiceProvider::class,
and this into aliases
'Form' => Collective\Html\FormFacade::class,
'Html' => Collective\Html\HtmlFacade::class,
My solution in my case it was problem with CASE-Sensitive class name.
In my config/app.php (in aliases)
'Form' => Collective\Html\FormFacade::class,
'Html' => Collective\Html\HtmlFacade::class,
I am tried to use in view this code:
{!! HTML::mailto('mailto:example@example.com', 'example@example.com'); !!}
and that was an error:
"FatalErrorException in ccf70b1d0b9930d6c4e8f3859fff448f line 11: Class 'HTML' not found"
Name of class 'HTML' is CASE-Sensitive. You should use 'Html' as in your config (config/app.php) file.
Hope this help for some people.