0% found this document useful (0 votes)
15 views14 pages

Micro Project WBP Reaming Index

The document is a micro project report on 'Sending Email With Attachment' submitted by Neha Nitin More at D.Y. Patil Technical Campus. It outlines the process of sending emails with attachments using PHP, discussing advantages, disadvantages, and the SMTP protocol involved in email transmission. The project concludes with a summary of the learning outcomes and references used in the research.

Uploaded by

Neha More
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
15 views14 pages

Micro Project WBP Reaming Index

The document is a micro project report on 'Sending Email With Attachment' submitted by Neha Nitin More at D.Y. Patil Technical Campus. It outlines the process of sending emails with attachments using PHP, discussing advantages, disadvantages, and the SMTP protocol involved in email transmission. The project concludes with a summary of the learning outcomes and references used in the research.

Uploaded by

Neha More
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 14

D.Y.

PATIL TECHNICAL CAMPUS, TALSANDE


FACULTY OF ENGINEERING & FACULTY
OF MANAGEMENT
(Polytechnic)

A Micro project Report On


“Sending Email With Attachment”
Submitted by
Entrollment no Name
2112200056 Neha Nitin More
Guided By
Ms.Mrunal.U. Desai
D.Y.PATIL TECHNICAL CAMPUS, TALSANDE FACULTY OF
ENGINEERING & FACULTY OF MANAGEMENT
(Polytechnic)
DEPARTMENT OF COMPUTER ENGINEERING
SEMESTER VI
CERTIFICATE
This is Certify that student of Computer Engineering has successfully
completed the project term work “Sending Email With Attachment.”
in partial fulfillment of the Diploma of Engineering in Computer as laid
down during academic year 2024-25.

Roll no Name of Student Exam Seat no

Ms.Mrunal.U.Desai Miss.Gurav.J.N
Project Guide HOD

Dr.S.R.Pawaskar
Principal

Date- / /2025
Place- Talsande
Introduction

PHP | Send Attachment With Email. Sending an email is a very common activity
in a web browser. For example, sending an email when a new user joins to a
network, sending a newsletter, sending greeting mail, sending an invoice. We can
use the built-in mail() function to send an email programmatically.

To send an email with mixed content requires to set Content-type header to


multipart/mixed. Then text and attachment sections can be specified within
boundaries. To send an email with mixed content requires to set Content-type
header to multipart/mixed. Then text and attachment sections can be specified
within boundaries. A boundary is started with two hyphens followed by a unique
number which can not appear in the message part of the email.

A PHP function md5() is used to create a 32 digit hexadecimal number to create


unique number. A final boundary denoting the email's final section must also end
with two hyphens.
What is sending emails with attachment?

Sending an email is a very common activity in a web browser. For example,


sending an email when a new user joins to a network, sending a newsletter,
sending greeting mail, sending an invoice. We can use the built-in mail() function
to send an email programmatically.

This function needs three required arguments that hold the information about the
recipient, subject of the message and message body.
Along with this three required arguments, there are two more arguments which are
optional. One of them is the header and the other one is parameters.
We have already discussed sending text-based emails in PHP in our previous
article. In this article, we will see how we can send an email with attachments
using mail() function. When the mail() function is called PHP will attempt to send
the mail immediately to the recipient then it will return true upon successful
delivery of the mail and false if an error occurs.
Advantages:-

1 Email attachments is easy way to send small files.


2 Powerpoint presentation, Word File, Pdf files, Picture, Video etc can be sent
easily by email.
3. Files can be transferred from one computer to another using email attachments.
4. No geographical barrier, files can be transferred from one country to another
country instantly.
5. For printing and scanning purpose files can be shared by email attachment.

Disadvantages:-
1. Takes time to upload and download files or other attachments.
2. Large files cannot be sent by free email service
3. Additional software is required to open specific file format
4. Sometimes attachments and files sent by email contains virus which may
affect your computer.
5. Files may not be uploaded or downloaded properly from email if internet
speed is slow
Features of emails:-

1. In order to attach file(s) to an email, click the attach button. As a result, a


dialog box appears asking for specifying the name and location of the file you
want to attach.

2. Once you have selected the appropriate file, it is attached to the mail.

3. Usually a paper clip icon appears in the email which indicates that it has an
attachment.

4. When adding an attachment it is better to compress the attached files so as to


reduce the file size and save transmission time as sending and downloading
large files consumes a lot of space and time
Simple Mail Transfer Protocol (SMTP)

Email is emerging as one of the most valuable services on the internet today.
Most of the internet systems use SMTP as a method to transfer mail from one
user to another. SMTP is a push protocol and is used to send the mail whereas
POP (post office protocol) or IMAP (internet message access protocol) are used
to retrieve those mails at the receiver’s side.

SMTP Fundamentals:-

SMTP is an application layer protocol. The client who wants to send the mail
opens a TCP connection to the SMTP server and then sends the mail across the
connection. The SMTP server is always on listening mode. As soon as it listens
for a TCP connection from any client, the SMTP process initiates a connection
on that port (25). After successfully establishing the TCP connection the client
process sends the mail instanty
SMTP Protocol

The SMTP model is of two type :


1. End-to- end method
2. Store-and- forward method

The end to end model is used to communicate between different organizations


whereas the store and forward method are used within an organization. A
SMTP client who wants to send the mail will contact the destination’s host
SMTP directly in order to send the mail to the destination. The SMTP server
will keep the mail to itself until it is successfully copied to the receiver’s
SMTP. The client SMTP is the one which initiates the session let us call it as
the clientSMTP and the server SMTP is the one which responds to the session
request and let us call it as receiver-SMTP. The client- SMTP will start the
session and the receiverSMTP will respond to the request.
Model of SMTP system

In the SMTP model user deals with the user agent (UA) for example Microsoft
Outlook, Netscape, Mozilla, etc. In order to exchange the mail using TCP,
MTA is used. The users sending the mail do not have to deal with the MTA it
is the responsibility of the system admin to set up the local MTA. The MTA
maintains a small queue of mails so that it can schedule repeat delivery of mail
in case the receiver is not available. The MTA delivers the mail to the
mailboxes and the information can later be downloaded by the user agents.
Components of SMTP

First, we will break the SMTP client and SMTP server into two components such
as user agent (UA) and mail transfer agent (MTA). The user agent (UA) prepares
the message, creates the envelope and then puts the message in the envelope. The
mail transfer agent (MTA) transfers this mail across the internet.
SMTP allows a more complex system by adding a relaying system. Instead of just
having one MTA at sending side and one at receiving side, more MTAs can be
added, acting either as a client or server to relay the email.

The relaying system without TCP/IP protocol can also be used to send the emails
to users, and this is achieved by the use of the mail gateway. The mail gateway is a
relay MTA that can be used to receive an email.
Use case diagram
Conclusion

In this project we collect the different information related to Sending emails with
attachments and develop our project. In this project we learn about Sending emails
with attachments and their features, advantages and disadvantages. In this way we
done our project successfully with the help of project and coordination of team
members.
References

1. www.w3schools.com
2. www.phptpoint.com
3. www.geeksforgeeks.org
4. www.tutorialspoint.com

You might also like