• How to add a PDF file with a watermark as an attachement to an email?

    I tried this:

    add_filter( 'woocommerce_email_attachments', 'dcwd_conditionally_attach_order_files_to_order_email', 10, 4 );
    function dcwd_conditionally_attach_order_files_to_order_email( $attachments, $email_id, $object, $email_obj ) {
    
    	if ( 'customer_completed_order' != $email_id ) {
    		return $attachments;
    	}
        
        $upload_dir = 
        $attachments[] =
    
    	return $attachments;
    }

    but I don’t know what is supposed to be a directory path or a filename

Viewing 1 replies (of 1 total)
  • Plugin Author Little Package

    (@littlepackage)

    Hi @issirunning,

    Thanks for your question. Frankly, I don’t know. That’s well beyond the scope of this free plugin, and would be beyond the stated functions of the paid version as well. In cases like this where you are unfamiliar with PHP and WordPress, I recommend hiring a developer. Folks like me always need paying work; I can’t do it all for free! ??

    Take care

    • This reply was modified 3 years, 4 months ago by Little Package. Reason: Fix username
Viewing 1 replies (of 1 total)
  • The topic ‘Email attachment’ is closed to new replies.