Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- /**
- * PDF Invoices & Packing Slips for WooCommerce:
- * Incluye el NIF en los documentos PDF (dentro de los datos de facturación)
- */
- add_filter( 'wpo_wcpdf_billing_address', function( $address, $document ) {
- if ( ! empty( $document ) && is_callable( array( $document, 'get_custom_field' ) ) && ( $nif = $document->get_custom_field( 'NIF' ) ) ) {
- $address .= sprintf( '<p>CIF/DNI/NIE: %s</p>', $nif );
- }
- return $address;
- }, 10, 2 );
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement