我需要顯示(以及稍後打印)帶有包含條形碼和每行描述的表格的頁面。使用zend獲取帶有條形碼的表格
我有我的包含正確的數據
$result = $mySql->query->fetchAll();
。
起初我用壞的結果做出了
$rendererOptions = array();
foreach($result as &$res){
$barcodeOptions = array(
'text' => $res['myParam'],
'rendererParams' => array('imageType' => 'gif'),);
$res['barcode'] = Zend_Barcode::factory('CODE39', 'image', $barcodeOptions, $rendererOptions)->draw();
}
$this->view->data = $result;
。然後我試着用:
Zend_Barcode::render(....);
有許多組合,甚至
$.post('/mycontroller/myactionthatrendersthebarcode',{code : this.id}, function(data){
$(this).html(data); });
我一個.phtml頁
(幾乎查殺網絡:d)
繼文檔(http://framework.zend.com/manual/1.12/en/zend.barcode.creation.html) 我只有一個,但正確的,條形碼或一堆資源我不知道如何管理。
有什麼建議嗎? 謝謝
什麼意思是壞結果?你會得到一個異常/錯誤? – bitWorking 2013-03-18 13:49:08
沒有簡單的一個損壞的圖像標誌或根本沒有結果。 我理解的唯一事情是我錯過了「邏輯方法」來做到這一點...... – mauoftheclouds 2013-03-18 14:03:11