2015-01-21 114 views
1

這裏是我想在laravel方式產生laravel動態圖像路徑

<img src="public/assets/uploads/driver/<?php echo $DriverDetail['DriverPhoto'];?>"> 

我試着用

{{ HTML::image('public/assets/uploads/driver/', 'Driver Photo', array('class' => 'student-listing-photo')) }} 

但我怎麼可以給HTML::image內價值$DriverDetail['DriverPhoto'];轉換我的圖片標籤標籤。

+0

你的意思'{{HTML ::圖像( '公共/資產/上傳/司機/' $ DriverDetail [ 'DriverPhoto'],「驅動器照片',數組('class'=>'student-listing-photo'))}}'? – Mohebifar 2015-01-21 07:00:59

回答

1

就這麼簡單,連接兩個字符串:

{{ HTML::image('public/assets/uploads/driver/' . $DriverDetail['DriverPhoto'], 'Driver Photo', array('class' => 'student-listing-photo')) }}