Support the ongoing development of Laravel.io →
posted 10 years ago
Views Blade
Last updated 2 years ago.
0

You can get all routes with

$routes = Route::getRoutes();

And then you can just loop through them. If that is sufficient?

Last updated 2 years ago.
0

thanks alot, that definitely helped, it put me in the right direction... to loop through the routes i called the getPath() function and just prepended the base url, something like this

$routes = Route::getRoutes();
foreach($routes as $route)
{
    echo($base_url.$route->getPath());
}
Last updated 2 years ago.
0

Instead of $base_url, you could probably better do URL::to($route->getPath());

Last updated 2 years ago.
0

Sign in to participate in this thread!

Eventy

Your banner here too?

tharoldD tharoldd Joined 6 Feb 2014

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.