Change the name to pdf quote in YITH WooCommerce Request a Quote

Plugin info: YITH WooCommerce Request a Quote Premium

With this code you can customize the name of the pdf quote document generated when an administrator send the quote to the customer.

Add this code in the file functions.php of your theme or child-theme, change the string ‘custom_name_’ with the string that you prefer.

The variable $quote_id is necessary to make the document unique inside the folder.

 

If you want mask the number of quote, you can use php functions like uniqid changing the line 7 with

return uniqid('custom_name_').'.pdf';

Leave a comment

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