lundi 6 février 2017

How does URL::to work in laravel 5?

I have made an installation of laravel in a subfolder.

e.g.

foo.com/laravel/

now all calls to

foo.com/ are directed to a different application.

All calls to for example

foo.com/laravel/baz are directed to laravel

the routes still look like this

Route::get('/baz', function(){...});

and it works

The sublinks, when using URL::to in these routes in blades, works too.

URL::to does not work in e-mails though

for example when doing this in an e-mail:

<a href="">bippo</a>

the resulting url is to

foo.com/baz and not to foo.com/laravel/baz

this leads to my question, how does URL::to work, and how can I make it work the way I want? e.g. to always return the URL to the root of the installation.



from Newest questions tagged laravel-5 - Stack Overflow http://ift.tt/2kgkWlj
via IFTTT

Aucun commentaire:

Enregistrer un commentaire