SitePoint Sponsor

User Tag List

Results 1 to 2 of 2
  1. #1
    SitePoint Member
    Join Date
    Jan 2009
    Posts
    1
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Email Uploaded File From Server

    I need to be able to email a file that is loaded to a server via a form in Flash.

    I'm using this php code to transfer the file to the server. Just need to know how to get the file from the server, attach it to an emailed and send it.

    Also I need to mention that I dont know that much about PHP. So if someone can break it down so I can understand it that would be helpful.

    <?php

    if (is_uploaded_file($_FILES['Filedata']['tmp_name'])) {

    $uploadDirectory = "uploads/";
    $uploadFile = $uploadDirectory . basename($_FILES['Filedata']['name']);

    copy($_FILES['Filedata']['tmp_name'], $uploadFile);

    }
    ?>
    Last edited by jonnie_danger; Jan 1, 2009 at 13:32.

  2. #2
    SitePoint Wizard
    Join Date
    Mar 2008
    Posts
    1,149
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    http://php.net/mail

    See references of attachments in the actual doc. and in the comments.


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •