Support the ongoing development of Laravel.io →
posted 9 years ago
Forms
Last updated 1 year ago.
0

I've ended up getting an answer on stackOverflow, heere's the solution:

From the code source, route method generate an absolute URL by default, you may set it to false:

<a href="{{ URL::route('dashboard-get',array(),false) }}">Dashboard</a>
Update

You can also define your own custom links by

HTML::macro('Rlinks',function($routeName,$parameters = array(),$name){ 
    return "<a href=".substr(URL::route($routeName,$parameters,false), 1) .">"
       .$name.
    "</a>";
});

Then call your macro

{{ HTML::Rlinks('dashboard-get',array(),'Dashboard') }}
0

Sign in to participate in this thread!

Eventy

Your banner here too?

kitensei kitensei Joined 29 Jan 2015

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.