• Resolved hipoglucido

    (@hipoglucido)


    Hello,

    Is it possible to add a custom field to the right of the “Invoice” text? I would need to add “Simplified Invoice”

    Thank you,

    Borja

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Contributor kluver

    (@kluver)

    Hi @hipoglucido,

    The easiest way to change your document title would be with our Professional extension. This will let you change the title right in the plugin settings.

    This can however also be achieved with a small code snippet:

    add_filter( 'wpo_wcpdf_invoice_title', 'wpo_wcpdf_simplified_invoice_title', 10, 2 );
    function wpo_wcpdf_simplified_invoice_title ( $title, $document = null ) { 
    	$title .= ' - Simplified Invoice';
    	return $title;    
    }

    This code snippet should be placed in the functions.php of your child theme. If you have never worked with functions.php or code snippets before please read this: How to use filters

    Please note that most changes made to the invoice only appear on invoices created after the changes were made. This is because the invoice should be immutable in most countries. You can however overwrite this by enabling the ‘Always use most current settings option (WooCommerce > PDF Invoices > Documents > Invoice).

    • This reply was modified 5 years, 7 months ago by kluver.
    Thread Starter hipoglucido

    (@hipoglucido)

    Thanks a lot for your support, really greatful

    I will try it.

    Hipoglucido

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Custom Text’ is closed to new replies.