-1
我在我的控制器(我用的Symfony2)生成圖像,當我跟我的形象回到我的迴應,我得到這個:顯示圖像
HTTP/1.0 200 OK
Cache-Control: no-cache
Content-Disposition: inline; filename=""
Content-Type: image/jpeg
我需要顯示在圖像我的觀點,但如果我把:
<img src="<?= $response ?>" />
瀏覽器顯示404錯誤,如果我用
<?php echo $response; ?>
我只得到
HTTP/1.0 200 OK
Cache-Control: no-cache
Content-Disposition: inline; filename="example.jpg"
Content-Type: image/jpeg
Date: Wed, 08 Oct 2014 14:55:24 GMT
X-Sendfile: 67902
我想顯示圖像,任何想法?
謝謝!
' 2014-10-08 15:17:27
謝謝Marc,但是我怎樣才能將這個射線二進制數據轉換爲數據 - uri? – user3396420 2014-10-08 15:21:32
http://en.wikipedia.org/wiki/Data_URI_scheme#Format – 2014-10-08 16:25:42