Can’t add Local Pickup Plus custom field to wpo_wcpdf_after_shipping_address
-
I’ve added the following code to the template-functions.php as per documentation for my invoice:
add_action( 'wpo_wcpdf_after_shipping_address', 'wpo_wcpdf_location_name', 10, 2 ); function wpo_wcpdf_location_name ($template_type, $order) { ?> <tr class="location-name"> <th>Pickup Location:</th> <td><?php echo $order->get_meta('_pickup_location_name'); ?></td> </tr> <?php }And I’ve got my invoice set to HTML to view the render faster. But nothing is displayed – not even the ‘Pickup Location’ text.
But if I changed the hook to ‘wpo_wcpdf_before_customer_notes’ I can see the text at least. While custom field value is still not loading.
Is there something else I’m missing?
Viewing 5 replies - 1 through 5 (of 5 total)
Viewing 5 replies - 1 through 5 (of 5 total)
The topic ‘Can’t add Local Pickup Plus custom field to wpo_wcpdf_after_shipping_address’ is closed to new replies.