EMAIL, CONTACT

mail.inc

drupal_mail   http://api.drupal.org/api/drupal/includes--mail.inc/function/drupal_mail/7

http://11heavens.com/theming-the-contact-form-in-Drupal-6#Using

I do not use Drupal, so am unfamiliar with its setup.

However, the e-mail setup that I am speaking about is the general e-mail setup that you configure through cPanel. Log in to cPanel and go to Mail > Email Accounts to set up the accounts.

I believe, like many other CMSes out there, Drupal uses phpmail out of the box to send e-mails. You should be able to configure it to use SMTP to send mail as an alternative (might require additional modules), but that's another story.

Once you set up your e-mail account(s) in cPanel, set up PHP Config (cPanel > Software/Services) to use PHP5 (Single php.ini) > Save changes. Generate a default php.ini file within ~/public_html ("Install php.ini master file"), rename it if necessary to php.ini and find the sendmail_path line. Modify it to look something like this:

Code:
sendmail_path = "/usr/sbin/sendmail -t -i -fmyemail@mydomain.tld"

Note that myemail@mydomain.tld is the e-mail address that you created in cPanel (modify to suit your scenario). There is no space between the -f flag and the e-mail address. Save the modified php.ini file and try sending mail through Drupal.

http://falcon1986.wordpress.com/