#include <SendMail.h>
List of all members.
Constructor & Destructor Documentation
QGpGuiTools::SendMail::SendMail |
( |
const QString & |
smtp, |
|
|
const QString & |
from, |
|
|
const QString & |
to, |
|
|
const QString & |
subject, |
|
|
const QString & |
body, |
|
|
const QStringList * |
files = 0 |
|
) |
| |
References TRACE.
{
TRACE;
_socket=new QTcpSocket(this);
connect(_socket, SIGNAL(readyRead()), this, SLOT(readyRead()));
connect(_socket, SIGNAL(connected()), this, SLOT(connected()));
connect(_socket, SIGNAL(bytesWritten(qint64)), this, SLOT(dataWritten(qint64)));
_message="MIME-Version: 1.0\nFrom: "+from
+"\nTo: "+to+"\nSubject: "+subject+"\n";
if(files) {
_message+="Content-Type: multipart/mixed; "
"boundary=\"----------Part879845462132654653138\"\n"
"This is a multi-part message in MIME format.\n"
"------------Part879845462132654653138\n"
"Content-Type: text/plain; charset=us-ascii; format=flowed\n"
"Content-Transfer-Encoding: 7bit\n";
_files=*files;
}
_smtp=smtp;
_message+="\n"+body+"\n";
_from=from;
_to=to;
_state=Init;
}
Member Function Documentation
The documentation for this class was generated from the following files: