B
B
BonBon Slick2017-06-26 21:36:10
Laravel
BonBon Slick, 2017-06-26 21:36:10

Laravel get url by route name?

I need to get the full URL given the route name. Since if you use other options, it will be inconvenient. At the moment I have this:

laroute.route('buy');
// /buy

It will return an error, it is necessary to get the full URL of the buy route , to send a request, it does not go to my server where Laravel routing is located, so now it returns an error to me.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
B
BonBon Slick, 2017-06-26
@BonBonSlick

URL::route('route_name', [])

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question