のCodeIgniterを使ってTCPDFで画像を表示しようとしたとき、私は問題を抱えている、これは私のPDF図である画像のサイズ(CodeIgniterの、TCPDF、PHP)
を取得することができません:
$base_url=base_url();
// NON-BREAKING ROWS (nobr="true")
$tbleauproduct = <<<EOD
<br /><br /><br />
<table border="1" align="center">
<tr>
<th>picture</th>
<th>Product name</th>
<th>Price</th>
<th>Quantity</th>
</tr>
<tr>
<td><img src="$base_url/assets/$picture" /></td>
<td>$name</td>
<td>$price</td>
<td>$qty</td>
</tr>
</table>
EOD;
$pdf->writeHTML($tbleauproduct, true, false, true, false, '');
とこれが結果です:
TCPDF ERROR: [Image] Unable to get the size of the image: http://localhost:8888/open_bay//assets/130501153059-htc-one-1024x576.jpeg
PDF画像ではありません。 – Narf
[TCPDFエラー:画像のサイズを取得できません]の複製があります。(http://stackoverflow.com/questions/27060947/tcpdf-error-unable-to-get-the-size-of-the-image) –
コードの画像を投稿しないようにしてください。常にテキストとしてコードを投稿してください。私はあなたのためにあなたのイメージを置き換えました。 – mickmackusa