本文整理汇总了PHP中MYPDF::write2DBarcode方法的典型用法代码示例。如果您正苦于以下问题:PHP MYPDF::write2DBarcode方法的具体用法?PHP MYPDF::write2DBarcode怎么用?PHP MYPDF::write2DBarcode使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类MYPDF
的用法示例。
在下文中一共展示了MYPDF::write2DBarcode方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1:
<tr>
<td>
</td>
</tr>
<tr><td></td></tr>
<tr>
<td width="520" align="center" style="font-size:8px"><b>"ESTA FACTURA CONTRIBUYE AL DESARROLLO DEL PAIS, EL USO ILICITO DE ESTA SERA SANCIONADO DE ACUERDO A LEY"</b></td>
</tr>
<tr><td></td></tr>
<tr>
<td width="460" align="center" style="font-size:10px">"Ley Nº 453: Está prohibido importar, distribuir o comercializar productos expirados o prontos a expirar"</td>
</tr>
</table>
';
if ($i == 17 || $i == 18 || $i == 19 || $i == 20) {
$pdf->writeHTMLCell($w = 0, $h = 0, '', $pdf->GetY() + 25, $final, $border = 0, $ln = 1, $fill = 0, $reseth = true, $align = 'left', $autopadding = true);
} else {
$pdf->writeHTMLCell($w = 0, $h = 0, '', '', $final, $border = 0, $ln = 1, $fill = 0, $reseth = true, $align = 'left', $autopadding = true);
}
//$left_column = $pdf->write2DBarcode('7024736019|3|2104002021751|2015-10-02|30.50|30.50|15451254|0|0|0|0', 'QRCODE,L', '175', '', 30, 30, '', 'N');
//$pdf->writeHTMLCell(80, '', '', '', $left_column, 0, 0, 0, true, 'J', true);
//qr roy
$pdf->write2DBarcode('7024736019|3|2104002021751|2015-10-02|30.50|30.50|15451254|0|0|0|0', 'QRCODE,L', '175', $pdf->GetY() - 40, 20, 20, '', 'N');
// ---------------------------------------------------------
//Close and output PDF document
$pdf->Output('example_003.pdf', 'I');
//============================================================+
// END OF FILE
//============================================================+
示例2: date
</tr>
<tr>
<td width="440" align="center" style="font-size:7px">"' . $law . '"</td>
</tr>
</table>
';
if ($pdf->GetY() >= '226.6375') {
$pdf->AddPage('P', 'LETTER');
if (!empty($nota) && !empty($terminos)) {
$restoQr = $restoQr - 18;
}
}
$subtotal = number_format((double) $invoice->importe_total, 2, '.', '');
$descuento = number_format((double) ($invoice->importe_total - $invoice->importe_neto), 2, '.', '');
$total = number_format((double) $invoice->importe_neto, 2, '.', '');
$pdf->writeHTMLCell($w = 0, $h = 0, '', '', $datosFactura, $border = 0, $ln = 1, $fill = 0, $reseth = true, $align = 'left', $autopadding = true);
$date_qr = date("d/m/Y", strtotime($invoice->invoice_date));
$date_qr = \DateTime::createFromFormat('Y-m-d', $invoice->invoice_date);
if ($date_qr == null) {
$date_qr = $invoice->invoice_date;
} else {
$date_qr = $date_qr->format('d/m/Y');
}
if ($descuento == '0.00') {
$descuento = 0;
}
$datosqr = $invoice->account_nit . '|' . $invoice->invoice_number . '|' . $invoice->number_autho . '|' . $date_qr . '|' . $total . '|' . $fiscal . '|' . $invoice->control_code . '|' . $invoice->client_nit . '|' . $ice . '|0|0|' . $descuento;
$pdf->write2DBarcode($datosqr, 'QRCODE,M', '175', $pdf->GetY() - $restoQr, 25, 25, '', 'N');
//Close and output PDF document
$pdf->Output('factura.pdf', 'I');
die;
示例3: date
</tr>
<tr>
<td width="460" align="left" style="line-height: 300%"><b>Fecha Límite de Emisión : ' . $fecha_limite . ' </b></td>
</tr>
<tr>
<td width="440" align="center" style="font-size:8px"><b>"' . $law_gen . '"</b></td>
</tr>
<tr><td></td></tr>
<tr>
<td width="440" align="center" style="font-size:7px">"' . $law . '"</td>
</tr>
</table>
';
if ($pdf->GetY() >= '210.6375') {
$pdf->AddPage();
}
$pdf->writeHTMLCell($w = 0, $h = 0, '', '', $datosFactura, $border = 0, $ln = 1, $fill = 0, $reseth = true, $align = 'left', $autopadding = true);
//qr roy
$date_qr = date("d/m/Y", strtotime($invoice->invoice_date));
if ($descuento == "0.00") {
$descuento = 0;
}
$datosqr = $invoice->account_nit . '|' . $invoice->invoice_number . '|' . $invoice->number_autho . '|' . $date_qr . '|' . $total . '|' . $fiscal . '|' . $invoice->control_code . '|' . $invoice->client_nit . '|' . $ice . '|0|0|' . $descuento;
$pdf->write2DBarcode($datosqr, 'QRCODE,L', '175', $pdf->GetY() - 33, 25, 25, '', 'N');
//Close and output PDF document
$pdf->Output('factura.pdf', 'I');
//============================================================+
// END OF FILE (^_^)
//============================================================+
die;