blue-genie Posted December 22, 2010 Share Posted December 22, 2010 i'm using a flash frontend, and i need help with a script that will take all the files in a folder (up to 6) and mail it to someone. i can do it as a zip or not. can anyone help please. Link to comment https://forums.phpfreaks.com/topic/222377-send-all-files-in-folder-as-attachment/ Share on other sites More sharing options...
litebearer Posted December 22, 2010 Share Posted December 22, 2010 create zip file - http://davidwalsh.name/create-zip-php attach file to email - http://www.webcheatsheet.com/PHP/send_email_text_html_attachment.php Link to comment https://forums.phpfreaks.com/topic/222377-send-all-files-in-folder-as-attachment/#findComment-1150273 Share on other sites More sharing options...
blue-genie Posted December 22, 2010 Author Share Posted December 22, 2010 i can get the create attachment part to work but sending it.. this is not familiar to me --PHP-alt-<?php echo $random_hash; ?> Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit all these -PHP-alt- are they supposed to be there? if i leave them there it complains, if i take it out no syntax errors but it says mail failed. Link to comment https://forums.phpfreaks.com/topic/222377-send-all-files-in-folder-as-attachment/#findComment-1150308 Share on other sites More sharing options...
BlueSkyIS Posted December 22, 2010 Share Posted December 22, 2010 you might find things much simpler using an existing email class instead of writing your own code. i use this class for many of my projects http://www.phpguru.org/downloads/Rmail/Rmail%20for%20PHP/ Link to comment https://forums.phpfreaks.com/topic/222377-send-all-files-in-folder-as-attachment/#findComment-1150334 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.