我的代码正在生成条形码。但它不能保存。请帮助我保存它们。
private function set_barcode($code)
{
//load library
$this->load->library('zend');
//load in folder Zend
$this->zend->load('Zend/Barcode');
//generate barcode
$bar_code = Zend_Barcode::render('code128', 'image', array('text'=>$code), array('imageType' => 'jpg'))->draw();
$code = time().$code;
$store_image = imagepng($bar_code,"../barcode/{$code}.png");
return $code.'.png';
}