1

Is there any built-in method in Laravel to get the path of the previous URL?

I know about url()->previous(); but i only want to get previous path. Also, I can extract previous path from the previous URL. But I would like to know if there is any built-in method in Laravel.

mega6382
  • 9,211
  • 17
  • 48
  • 69
Amarjit Singh
  • 2,068
  • 19
  • 52
  • But that is the built in method, there is no other! – lewis4u Nov 04 '17 at 12:46
  • Possible duplicate of [Previous route name in Laravel 5.1](https://stackoverflow.com/questions/40690202/previous-route-name-in-laravel-5-1) – Camilo Nov 04 '17 at 18:51

1 Answers1

0

For Laravel 5.3

I've gone through same problem and I had searched for the same thing but i end up writing a code to manually extract path from previous URL. Therefore I think there is no such method provided by Laravel(till 5.3) to get only path of previous URL.