Created
April 15, 2015 15:58
-
-
Save jchamb/933dc7572e9e87aad450 to your computer and use it in GitHub Desktop.
Fix for CF7 add_uploaded_file
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public function add_uploaded_file( $name, $file_path ) { | |
$mail = $this->contact_form->prop('mail'); | |
$this->uploaded_files[$name] = $file_path; | |
if ( empty( $this->posted_data[$name] ) ) { | |
$this->posted_data[$name] = basename( $file_path ); | |
$mail['attachments'] .= "[$name]\n"; | |
$this->form->set_properties( array('mail' => $mail) ); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment