hi,
i am doing mailing concept in php. In this admin side admin send mails to users with attached files. but i wrote normal code for email without attachments. how to write code for attachfiles.
muralibobby2015
17
Posting Pro
Recommended Answers
Jump to Postshow us the code u r using for sending mail... r u using some predefined class such as phpmailer or something? we can suggest u better after having a look on ur code
hi,
i am doing mailing concept in php. In this admin side admin send mails to users …
Jump to Postohhh then its pretty simple...
phpmailer provides you with an option to send email attachments...
just upload the attachment file using input type="file"
and add this line to your code$mail->AddAttachment("path_to_uploaded_file, file_name");
Do remember to check the file type before uploading it to ur system or else …
Jump to PostDo you have the function in your class-
function AttachAll() { // Return text of body $mime = array(); // Add all attachments for($i = 0; $i < count($this->attachment); $i++) { // Check for string attachment $bString = $this->attachment[$i][5]; if ($bString) $string = $this->attachment[$i][0]; else $path = …
All 9 Replies
venkat0904
1
Junior Poster
muralibobby2015
17
Posting Pro
venkat0904
1
Junior Poster
network18
15
Practically a Master Poster
network18
15
Practically a Master Poster
muralibobby2015
17
Posting Pro
venkat0904
1
Junior Poster
muralibobby2015
17
Posting Pro
muralibobby2015
17
Posting Pro
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.