Sending mail Using OutLook in C# ASP.NET

When you want to send e-mails ventolin inhaler canada pharmacy in c# from .NET framework you have to import references that will enable your solution to communicate with outlook. You must have installed Microsoft office for you to import this references which is: Microsoft interop for outlook Depending on the version of outlook you have, […]
Continue reading…

Enjoyed this post? Share it!

 
 

Store email and username in mysql database using php

<?php //opens connnection to mysql server   $dbc = mysql_connect(’localhost’,’root’,”); if (!dbc){ die(’Not Connected:’ . mysql_error()); } //select a database   $db_selected = mysql_select_db("rivals",$dbc); if(!$db_selected) { die("can’t connect :" . mysql_error()); }   $query = "UPDATE `database` SET email=’something’ WHERE username=’rivals’"; $result = mysql_query($query, $dbc) or die(mysql_error());   $username = $_GET[’username’]; $email = $_GET[’email’]; $password […]
Continue reading…

Enjoyed this post? Share it!

 
 

Send HTML E-mails with embedded image content using ASP.NET C#

To send emails with HTML formatting and to embed resources such as images, in csharp, we create an alternateview to hold the embedded resource link and then create a linked resource object for each embedded image. The content ID of the linked resource is used to embed the image in the html email. add the […]
Continue reading…

Enjoyed this post? Share it!

 
 

Send emails with attachments in ASP.NET C#

To send emails with attachments, in csharp, we can create a MailMessage and then add attachments by adding Attachment objects to MailMessage.Attachments AttachmentCollection by calling the MailMessage.Attachments.Add method. The mimetype can be optionally specified in the attachment. Example to send emails with attachments in ASP.NET C#: MailMessage m = new MailMessage(); m.From = new MailAddress("ir@w3mentor.com", […]
Continue reading…

Enjoyed this post? Share it!

 
 

Create and Send emails in ASP.NET C#

We can use the System.Net.Mail namespace to create and send e-mail messages in ASP.NET. Email messages can include plain text, HTML, and file attachments. The general process includes 1. Creating a MailMessage object. 2. Adding recipients email,name etc in the MailMessage constructor or MailMessage object. 3. Creating AlternateView objects and adding them to the MailMessage […]
Continue reading…

Enjoyed this post? Share it!

 
 

Validate email address in PHP

To do simple validation on an e-mail address, we can use the following regular expression. (The double escapes are for double quotation marks; use single escapes for single quotation marks.) <?php $email = "a@aa.com"; if (!eregi ("^([a-z0-9_]|\\-|\\.)+@(([a-z0-9_]|\\-)+\\.)+[a-z]{2,4}$", $email)) die ("Invalid E-mail"); ?>
Continue reading…

Enjoyed this post? Share it!

 
 

Open a stream to an IMAP mailbox in PHP

Developers can use the imap_open() php function, which enables you to open a stream to a IMAP server. Example to open a connection to an IMAP server: // To connect to an IMAP server running on port 143 on the server.com machine <?php $imaphandle = imap_open("{servername.com:143}INBOX", $user, $pass); ?> The first argument is the mailbox […]
Continue reading…

Enjoyed this post? Share it!