Laravel - How to get current URL in controller or view?By Hardik Savani | July 20, 2016 | | 11740 Viewer | Category : Laravel
We always require to get current URL path when work on ajax pagination or something, at that we require to get current page URL on Controller or blade file. So, you can get current url easily.
Laravel provide URL facade that way we can get current URL anywhere, as bellow you can see i use current() of URL facade. URL facade through you can get your current page url from every where. So you can check your current url this way:
$currentURL = URL::current();
- Laravel 5 Google OAuth authentication using Socialite Package
- How to create responsive menu in html/PHP ?
- Laravel 5 - Create modular structure application example using L5Modular package
- How to generate route with query string parameter in Laravel 5?
- Laravel Jquery Ajax Pagination Example From Scratch
- How to get current url path example in Jquery?
- Mediafire PHP file uploading and get link example
- How to get product using rakuten marketing api in PHP?