Like every framework site laravel have helper to get different type of URL.
You can get details of the URL from following link of Laravel :
https://laravel.com/docs/5.0/helpers#urls
In my case i use laravel 5.0 that why the URL is like this, for your case just change the bold portion version to get your. if you version is 5.7 then the link will be
https://laravel.com/docs/5.7/helpers#urls
Here is some Sample :
Home URL :
In blade template :
{{ url('/') }}
in PHP file :url('/');
Leave A Comment?
You must be logged in to post a comment.