Suggestion for the FAQ
-
Hi Ewout,
Great plugin!
A suggestion for your FAQ, so that other people don’t have to research this….
Here’s the snippet to add a downloadable link to your “Thank you” page when someone orders:
add_action('woocommerce_thankyou', 'my_woocommerce_thankyou'); function my_woocommerce_thankyou($order_id) { $pdf_url = wp_nonce_url( admin_url( 'admin-ajax.php?action=generate_wpo_wcpdf&template_type=invoice&order_ids=' . $order_id . '&my-account'), 'generate_wpo_wcpdf' ); echo '<p><a href="'.esc_attr($pdf_url).'">Download a printable invoice / payment confirmation (PDF format)</a></p>'; }
Best wishes,
Davidhttps://wordpress.org/plugins/woocommerce-pdf-invoices-packing-slips/
Viewing 4 replies - 1 through 4 (of 4 total)
Viewing 4 replies - 1 through 4 (of 4 total)
- The topic ‘Suggestion for the FAQ’ is closed to new replies.