Support the ongoing development of Laravel.io →
Configuration Requests
Last updated 2 years ago.
0

The default laravel htaccess is fully compatible with friendly urls. restore it

Last updated 2 years ago.
0

After I restored laravel .htaccess I still can't open Route example.com/wniosek.html still have the same exception!

Last updated 2 years ago.
0

Get rid of the .html at the end of the url.

Last updated 2 years ago.
0

But I need urls with .html at the end this is why I asked for help. I am migrating one site to laravel and this .html urls are required.

Last updated 2 years ago.
0

With the default .htaccess, whenever a real html file is there, RewriteCond %{REQUEST_FILENAME} !-f won't match and no rewrite will occur (the html file will be served).
Are those "wniosek.html" and "index.html" real files inside the correct directory?

Last updated 2 years ago.
0

You shouldn't use Route::resource like that. You should use Route::get() (or post/any)

Route::get('wniosek', 'HomeController@showTest');

And if you need the .html extension:

Route::get('index.html', 'HomeController@showIndex');
Route::get('wniosek.html', 'HomeController@showTest');
Last updated 2 years ago.
0

Are those "wniosek.html" and "index.html" real files inside the correct directory?

No those files don't exist. I have only index.php in public directory

Last updated 2 years ago.
0

Sign in to participate in this thread!

Eventy

Your banner here too?

Moderators

We'd like to thank these amazing companies for supporting us

Your logo here?

Laravel.io

The Laravel portal for problem solving, knowledge sharing and community building.

© 2024 Laravel.io - All rights reserved.