If none of the built in PDF layouts are what you are looking for then there are two solutions for your own custom PDF template.

First option: code your own template in PHP.

Print products PDF

Therefore you can use one of the two filters:

  1. woocommerce_print_products_product_html
  2. woocommerce_print_products_product_final_html

Print Posts Plugin

  1. wordpress_print_posts_html

Then you need to return HTML code in your custom coded functions. An example:

add_filter('woocommerce_print_products_product_final_html', 'we_custom_pdf_template', 20, 3);
function we_custom_pdf_template($html, $productId, $data) {
	$product = wc_get_product($productId);
	if(!$product) {
		return;
	}

	$html = 'My Test';

	return $html;
}

2nd option: contact our customization service

Therefore please send us an email to [email protected] including the following information:

  • desired template (PDF mockup)
  • information where what data is coming from (best you comment that in the PDF template)
  • make sure you mark custom data fields / ACF fields correctly

Send your request to [email protected]. Then we can give you a quote.

10 thoughts on “Are custom PDF layouts possible?

  1. Yoann says:

    Hey, this hook use the example for woocommerce_print_products_product and not wordpress_print_posts, could you explain how to create a custom template and give the right hook for with wordpress_print_posts ?

    Thanks,

      • SIrvin says:

        Thanks for your reply. I don’t manage to add the hook specify above in my function.php. It creates a critical error. I can design my own HTML template but I don’t understand how to connect it with this hook. What is “My test” ? Could you do a step-by-step guide to at least use your hook ?
        Is this a special support to ask about clarifying your FAQ ? If yes well i will renew it. Thanks a lot

  2. Gardner G says:

    I would like my product display based on the SKU number order. Can pdf catalog able to do that? Or I need to write specific code to achieve that? Thank you

  3. Philip says:

    In which folder of my theme do I need to place an override template file of the woocommerce-pdf-catalog/class-woocommerce-pdf-catalog-product-templates.php?

Leave a Reply

Your email address will not be published. Required fields are marked *