Jump to content

Send mail with attachment


Darkness Soul

Recommended Posts

Hi guys,

I've performed a search but, unhappy, don't find topics with this problem.

I need to send a mail.. like newsletter, but with attachment!

I read somewhere about use mimetype to send images, but long time ago.. to send files, any kind of files.. what I suppose to do?

Thank you.

D.Soul
Link to comment
Share on other sites

I've built a code, and its apper work fine.. dont clue here because it have 215 lines (with coments), so i can write a tutorial if someone need..

but i still have a problem..

I need to know what kind of file the mail is attaching.. my code to do this:

[code]    if ( strtoupper ( $arq_extensao ) == 'PDF' )
    {
        $arq_aplicacao = 'pdf';
    }
    elseif ( strtoupper ( $arq_extensao ) == 'DOC' )
    {
        $arq_aplicacao = 'msword';
    }[/code]
But, i need a function to take the file extension ($arq_extensao).. this if will filter the mime "application/[type]".

Have some function to retrieve these extension?

Thanks, D.Soul
Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.