Sample PHP Mail Script with SMTP Authentication

The below email script is for PHP emailing with SMTP authentication. //new function $to = “you@your-domainname.com”; $nameto = “Who To”; $from = “script@your-domainname.com”; $namefrom = “Who From”; $subject = “Hello World Again!”; $message = “World, Hello!”; authSendEmail($from, $namefrom, $to, $nameto, $subject, $message); ?> /* * * * * * * * * * * * […]

PHP+Mysql DB connection script

<?php $link = mysql_connect(‘localhost’, ‘mysql_user’, ‘mysql_password’); if (!$link) { die(‘Could not connect: ‘ . mysql_error()); } echo ‘Connected successfully’; mysql_close($link); ?>