• Resolved effakt

    (@effakt)


    We have found that using this alongside WP Offload Media, the attachment of the file errors.
    This is due to the file not existing locally, and is instead offloaded to S3, or elsewhere.

    Would it be possible to have a filter added to the attachment_send function, as below.

    
    $path = str_replace( $wp_upload_dir['baseurl'], $wp_upload_dir['basedir'], $attachment );
    $path = apply_filters('gf_kgm_notification_attachment_path', $path, $attachment_id, $form, $lead);
    if ($path) {
    	$notification['attachments'][] = $path;
    }
    

    This will allow other plugins/themes to update the attachment_path as they need.

Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
  • The topic ‘Add filters to attachment send’ is closed to new replies.