vendredi 11 mars 2016

How to make an image link in Laravel 5.1

How to make an image link in Laravel 5.1

<div class="first-div-inner"><img style='height: 100%; width: 100%; object-fit: contain' src="{!! asset('images/add.png') !!}"/></div>

I have a route that I want to point to when an image is clicked. Using text, it's simple, but I have not been able to find away around using image as a link

If it is text, it'll be thus

{!! Html::linkRoute('myRouteName', 'text to display') !!}

How do I substitute the 'text to display' with an image? Thanks.



via Chebli Mohamed

Aucun commentaire:

Enregistrer un commentaire