How to : Send e-mail using php com functions
Send e-mail using php com functions
COM is a technology which allows the reuse of code written in any language (by any language) using a standard calling convention ...
How to send E-mail using PHP COM functions
What is COM
COM is a technology which allows the reuse of
code written in any language (by any language) using a standard calling convention
and hiding behind APIs the implementation details such as what machine the Component
is stored on and the executable which houses it. It can be thought of as a super
Remote Procedure Call (RPC) mechanism with some basic object roots. It separates
implementation from interface (' PHP Manual ')
The Script
Open you favorite text editor and put the following lines:
$objApp = new COM("Outlook.Application");
$myItem = $objApp- ﹥ CreateItem(olMailItem);
$a=$myItem- ﹥ Recipients- ﹥ Add("[email protected]");
$myItem- ﹥ Subject="This is a test";
$myItem- ﹥ Body="This is a Body Section now.....!";
$myItem- ﹥ Display();
$myItem- ﹥ Send();
? ﹥
The explanation
$objApp = new COM("Outlook.Application");
In the first line we create a instance of the COM object (in this case your
Outlook Application )
If you have installed MS Outlook, in your Windows registry exists a key named
Outlook.Application
Start Regedit.exe and explore the HKEY_CLASSES_ROOT . There is your Com objects.
$myItem = $objApp- ﹥ CreateItem(olMailItem);
Creates new MailItem (new Mail)
$a=$myItem- ﹥ Recipients- ﹥ Add("[email protected]");
Adding the Recipient element of MailItem
This will be your recipient
$myItem- ﹥ Subject="This
is a test";
Adding Subject element
This will be your subject
$myItem- ﹥ Body="This is
a Body Section now.....!";
Adding the Body element of MailItem
This will be your message
$myItem- ﹥ Display();
If you want see your Outlook Mail dialog add this line in the script ,else just
comment it!
$myItem- ﹥ Send();
Send the message using your DEFAULT Outlook account.
Что делает видео по-настоящему запоминающимся? Наверное, та самая атмосфера, которая заставляет забыть о времени. Когда вы заходите на RUVIDEO, чтобы посмотреть онлайн «How to : Send e-mail using php com functions», вы рассчитываете на нечто большее, чем просто загрузку плеера. И мы это понимаем. Контент такого уровня заслуживает того, чтобы его смотрели в HD 1080, без дрожания картинки и бесконечного буферизации.
Честно говоря, Rutube сегодня — это кладезь уникальных находок, которые часто теряются в общем шуме. Мы же вытаскиваем на поверхность самое интересное. Будь то динамичный экшн, глубокий разбор темы от любимого автора или просто уютное видео для настроения — всё это доступно здесь бесплатно и без лишних формальностей. Никаких «заполните анкету, чтобы продолжить». Только вы, ваш экран и качественный поток.
Если вас зацепило это видео, не забудьте взглянуть на похожие материалы в блоке справа. Мы откалибровали наши алгоритмы так, чтобы они подбирали контент не просто «по тегам», а по настроению и смыслу. Ведь в конечном итоге, онлайн-кинотеатр — это не склад файлов, а место, где каждый вечер можно найти свою историю. Приятного вам отдыха на RUVIDEO!
Видео взято из открытых источников Rutube. Если вы правообладатель, обратитесь к первоисточнику.